From a76f4f94d57e6eee11d579fe3a84d22419147027 Mon Sep 17 00:00:00 2001 From: "Uwe L. Korn" Date: Thu, 22 Apr 2021 11:08:33 +0200 Subject: [PATCH] Fix macOS tags .condarc and test actions on change (#71) --- .github/workflows/macos-tag.sh | 4 +++- .github/workflows/tag.sh | 4 +++- .github/workflows/tag.yml | 5 +++++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/macos-tag.sh b/.github/workflows/macos-tag.sh index 1fb2ef7d..05df8b50 100755 --- a/.github/workflows/macos-tag.sh +++ b/.github/workflows/macos-tag.sh @@ -7,4 +7,6 @@ source ${SCRIPT_DIR}/macos-conda-build.sh $* mamba install -y conda-channel-client -upload-conda-package $(conda render .ci_support/${CONDA_BUILD_YML}.yaml --output conda.recipe) +if [[ "${GITHUB_REF}" == refs/tags/* ]]; then + upload-conda-package $(conda render .ci_support/${CONDA_BUILD_YML}.yaml --output conda.recipe) +fi diff --git a/.github/workflows/tag.sh b/.github/workflows/tag.sh index 237c42a4..83f6c636 100755 --- a/.github/workflows/tag.sh +++ b/.github/workflows/tag.sh @@ -9,4 +9,6 @@ export CONDA_BUILD_YML=$1 conda activate base conda build -m .ci_support/${CONDA_BUILD_YML}.yaml conda.recipe -upload-conda-package $(conda render -m .ci_support/${CONDA_BUILD_YML}.yaml --output conda.recipe) +if [[ "${GITHUB_REF}" == refs/tags/* ]]; then + upload-conda-package $(conda render -m .ci_support/${CONDA_BUILD_YML}.yaml --output conda.recipe) +fi diff --git a/.github/workflows/tag.yml b/.github/workflows/tag.yml index e20c7b2c..79c6a0be 100644 --- a/.github/workflows/tag.yml +++ b/.github/workflows/tag.yml @@ -70,6 +70,11 @@ jobs: uses: actions/checkout@v2.1.0 with: ref: ${{ github.head_ref }} + - name: Create .condarc + shell: bash -l {0} + run: | + sed -ie "s/***REMOVED***/${***REMOVED***}/g" .github/workflows/.condarc + sed -ie "s/***REMOVED***/${***REMOVED***}/g" .github/workflows/.condarc - uses: conda-incubator/setup-miniconda@723ab12c1d66bb893c5ac701f8e387f00b24549e with: miniforge-variant: Mambaforge