Skip to content

Commit

Permalink
Add conda build / upload via gh action
Browse files Browse the repository at this point in the history
  • Loading branch information
k-dominik committed Nov 17, 2023
1 parent ee7e0cd commit 045ba09
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: deploy

on:
push:
tags:
- '1.*'

jobs:
package:
strategy:
matrix:
os: [macos-latest, windows-latest, ubuntu-latest]
runs-on: ${{ matrix.os }}
env:
ANACONDA_API_TOKEN: ${{ secrets.ANACONDA_API_TOKEN }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
auto-activate-base: true
activate-environment: bld-env
environment-file: .github/workflows/etc/bld-environment.yml
condarc-file: .github/workflows/etc/.condarc
miniforge-variant: Miniforge3
use-mamba: true
- name: linux conda build
if: matrix.os == 'ubuntu-latest'
shell: bash -l {0}
run: conda mambabuild -c conda-forge conda-recipe
- name: osx conda build
if: matrix.os == 'macos-latest'
shell: bash -l {0}
run: conda mambabuild -c conda-forge conda-recipe
- name: windows conda build
if: matrix.os == 'windows-latest'
shell: cmd /C CALL {0}
run: conda mambabuild -c conda-forge conda-recipe
1 change: 1 addition & 0 deletions .github/workflows/etc/.condarc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
anaconda_upload: True
9 changes: 9 additions & 0 deletions .github/workflows/etc/bld-environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: bld-env
channels:
- conda-forge
- nodefaults
dependencies:
- anaconda-client
- conda-build
- setuptools_scm
- boa

0 comments on commit 045ba09

Please sign in to comment.