From 41ff1c66431d9f9a68132acfc71982b38b3215bf Mon Sep 17 00:00:00 2001 From: Arya Massarat <23412689+aryarm@users.noreply.github.com> Date: Thu, 14 Nov 2024 13:56:49 -0800 Subject: [PATCH] bump build number for dscrutils recipe (#15) * bump build number for dscrutils recipe * try to upload to anaconda * use upload token in anaconda upload command * dont use token directly in command for security * only run anaconda upload on main branch --- .github/workflows/test.yml | 16 +++++++++------- recipes/r-dscrutils/meta.yaml | 2 +- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5e7b7a8..9e3f9ec 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -99,15 +99,17 @@ jobs: bioconda-utils build --packages ${{ matrix.packagename }} - name: Upload built package as GitHub artifact + id: artifact-upload uses: "actions/upload-artifact@v4" with: name: ${{ matrix.packagename }}-${{ matrix.os }} path: ${{ env.CONDA }}/envs/biobuild/conda-bld/ + if-no-files-found: 'ignore' -# - name: Upload built package to Anaconda -# shell: bash -el {0} -# env: -# ANACONDA_API_TOKEN: ${{ secrets.ANACONDA_API_TOKEN }} -# if: ${{ env.ANACONDA_API_TOKEN == '' }} -# run: | -# anaconda upload ${{ env.CONDA }}/envs/biobuild/conda-bld/linux-64/*.tar.bz2 + - name: Upload built package to Anaconda + shell: bash -el {0} + env: + ANACONDA_API_TOKEN: ${{ secrets.ANACONDA_API_TOKEN }} + if: ${{ (github.ref == 'ref/head/main') && (env.ANACONDA_API_TOKEN != '') && (steps.artifact-upload.outputs.artifact-id != '') }} + run: | + anaconda upload -m ${{ env.CONDA }}/envs/biobuild/conda-bld/*/*.tar.bz2 diff --git a/recipes/r-dscrutils/meta.yaml b/recipes/r-dscrutils/meta.yaml index 9295b10..53fe658 100644 --- a/recipes/r-dscrutils/meta.yaml +++ b/recipes/r-dscrutils/meta.yaml @@ -11,7 +11,7 @@ source: build: noarch: generic - number: 0 + number: 1 rpaths: - lib/R/lib/ - lib/