diff --git a/.github/workflows/conda-build.yml b/.github/workflows/conda-build.yml index ac77cbf9..2a80c306 100644 --- a/.github/workflows/conda-build.yml +++ b/.github/workflows/conda-build.yml @@ -68,3 +68,33 @@ jobs: PYTHON_VERSION=${{ matrix.python-version }} ANACONDA_API_TOKEN=${{ secrets.CONDA_TOKEN }} + conda-build-osx: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: ['3.8', '3.9', '3.10', '3.11'] + os: ["macos-14", "macos-13"] + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - uses: conda-incubator/setup-miniconda@v3 + with: + python-version: ${{ matrix.python-version }} + auto-update-conda: true + channels: conda-forge,defaults + activate-environment: anaconda-client-env + - shell: bash -el {0} + run: | + export PYTHON_VERSION=${{ matrix.python-version }} + conda install -y conda-build anaconda-client + conda config --set anaconda_upload no + export ANACONDA_API_TOKEN=${{ secrets.CONDA_TOKEN }} + PACKAGE_PATH=$(conda build . --python ${{ matrix.python-version }} --output) + conda build . --python ${{ matrix.python-version }} + if [ "${{ matrix.python-version }}" == "3.11" ]; then + anaconda -t $ANACONDA_API_TOKEN upload $PACKAGE_PATH --label main --label py3.11 --force + else + anaconda -t $ANACONDA_API_TOKEN upload $PACKAGE_PATH --label py${{ matrix.python-version }} --force + fi +