Skip to content

Commit 78ece7f

Browse files
committed
Update RC labels of Conda packages according to version number
If alpha or RC, then deduce the label RC. Otherwise, use the default (main) label. Note: in meta.yaml the RC label is hard-coded for the current alpha release, as there is no documented way of parameterizing the label without dynamically modifying the file.
1 parent ad74fa4 commit 78ece7f

3 files changed

Lines changed: 5 additions & 2 deletions

File tree

.github/workflows/conda.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,8 @@ jobs:
103103
echo "KHIOPS_CORE_VERSION=$KHIOPS_CORE_VERSION" >> "$GITHUB_ENV"
104104
- name: Install the Khiops Conda package
105105
run: |
106-
conda install khiops-core=$KHIOPS_CORE_VERSION
106+
if [[ $(echo ${KHIOPS_CORE_VERSION} | grep -E ".*-(a|rc)\.[0-9]+") ]]; then RC_LABEL="conda-forge/label/rc::"; else RC_LABEL=""; fi \
107+
conda install ${RC_LABEL}khiops-core=$KHIOPS_CORE_VERSION
107108
conda install --channel ./khiops-conda/ khiops
108109
- name: Test Khiops Installation Status
109110
run: kh-status

packaging/docker/khiopspydev/Dockerfile.rocky

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ RUN true \
7171
ARG PYTHON_VERSIONS
7272
RUN true \
7373
&& export CONDA="/root/miniforge3/bin/conda" \
74+
&& if [[ $(echo ${KHIOPS_REVISION} | grep -E ".*-(a|rc)\.[0-9]+") ]]; then export RC_LABEL="conda-forge/label/rc::"; else export RC_LABEL=""; fi \
7475
&& /bin/bash -c 'for version in ${PYTHON_VERSIONS}; \
7576
do \
7677
CONDA_ENVS="py${version} py${version}_conda"; \

packaging/docker/khiopspydev/Dockerfile.ubuntu

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ ARG KHIOPS_GCS_DRIVER_REVISION
4444
ARG KHIOPS_S3_DRIVER_REVISION
4545
RUN true \
4646
&& export CONDA="/root/miniforge3/bin/conda" \
47+
&& if [[ $(echo ${KHIOPS_REVISION} | grep -E ".*-(a|rc)\.[0-9]+") ]]; then export RC_LABEL="conda-forge/label/rc::"; else export RC_LABEL=""; fi \
4748
&& /bin/bash -c 'for version in ${PYTHON_VERSIONS}; \
4849
do \
4950
CONDA_ENVS="py${version} py${version}_conda"; \
@@ -52,7 +53,7 @@ RUN true \
5253
$CONDA create -y -n $CONDA_ENV python=${version}; \
5354
done; \
5455
# khiops core \
55-
$CONDA install -y -n py${version}_conda khiops-core=$(echo ${KHIOPS_REVISION} | tr -d "-") ; \
56+
$CONDA install -y -n py${version}_conda ${RC_LABEL}khiops-core=$(echo ${KHIOPS_REVISION} | tr -d "-") ; \
5657
# remote files drivers installed in the conda environment \
5758
$CONDA install -y -n py${version}_conda -c khiops \
5859
khiops-driver-s3=${KHIOPS_S3_DRIVER_REVISION} \

0 commit comments

Comments
 (0)