p12 2 #35
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: deploy-conda | |
on: | |
push: | |
branches: | |
- main | |
release: | |
types: | |
- published | |
jobs: | |
# publish: | |
# runs-on: ubuntu-latest | |
# name: Publish to Conda | |
# steps: | |
# - name: Checkout | |
# uses: actions/checkout@v2 | |
# | |
# - name: publish-to-conda | |
# uses: fcakyon/[email protected] | |
# with: | |
# subdir: 'conda-recipe' | |
# anacondatoken: ${{ secrets.ANACONDA_TOKEN }} | |
# platforms: 'win osx linux' | |
build_conda: | |
runs-on: ubuntu-latest | |
name: Publish to Conda | |
strategy: | |
fail-fast: false | |
# To upload to PyPI on every tag starting with 'v', use the following: | |
# if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v') | |
# To publish to pypi on each GitHub Release, use the following: | |
# if: github.event_name == 'release' && github.event.action == 'published' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup Miniconda | |
uses: conda-incubator/setup-miniconda@v2 | |
with: | |
miniconda-version: "latest" | |
auto-update-conda: true | |
- name: Build and upload package | |
shell: bash -el {0} | |
run: | | |
conda install -y conda-build anaconda-client | |
conda config --set anaconda_upload yes | |
export PATH=$(conda info --root):$PATH | |
export PATH=$(conda info --root)/bin:$PATH | |
conda-build --output-folder . . | |
env: | |
ANACONDA_API_TOKEN: ${{ secrets.ANACONDA_TOKEN }} |