-
Notifications
You must be signed in to change notification settings - Fork 136
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use ramber-build for building conda packages
- Loading branch information
1 parent
1c6186a
commit adaec33
Showing
4 changed files
with
55 additions
and
46 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,9 +13,9 @@ jobs: | |
python-version: [3.8, 3.9, '3.10', '3.11'] | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install dependencies and kraken | ||
|
@@ -39,11 +39,11 @@ jobs: | |
if: startsWith(github.ref, 'refs/tags/') | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Set up Python 3.9 | ||
uses: actions/setup-python@v4 | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.9 | ||
- name: Build a binary wheel and a source tarball | ||
|
@@ -68,55 +68,55 @@ jobs: | |
if: startsWith(github.ref, 'refs/tags/') | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- uses: conda-incubator/setup-miniconda@v2 | ||
- uses: conda-incubator/setup-miniconda@v3 | ||
with: | ||
python-version: 3.9 | ||
miniforge-variant: Mambaforge | ||
- name: install dependencies build | ||
shell: bash -l {0} | ||
run: mamba install "conda-build>=3.20" colorama pip ruamel ruamel.yaml rich jsonschema conda-verify anaconda-client mamba | ||
run: mamba install colorama pip ruamel ruamel.yaml rich jsonschema conda-verify anaconda-client | ||
# Runs the action with the following inputs or defaults if not specified. | ||
- name: install boa | ||
shell: bash -l {0} | ||
run: pip install https://github.com/mamba-org/boa/archive/refs/tags/0.14.0.zip | ||
- name: validate recipe | ||
shell: bash -l {0} | ||
id: conda_validation | ||
run: | | ||
PACKAGE_PATHS=$(conda mambabuild . --output --check -c conda-forge | tail -n 1) | ||
echo "package_paths=$PACKAGE_PATHS" >> $GITHUB_OUTPUT | ||
- name: run build | ||
shell: bash -l {0} | ||
run: conda mambabuild . -c conda-forge | ||
- name: convert packages | ||
shell: bash -l {0} | ||
run: | | ||
conda convert -p osx-arm64 -p osx-64 -o conda_convert ${{ steps.conda_validation.outputs.package_paths }} | ||
mkdir conda_convert/linux-64 | ||
cp -f ${{ steps.conda_validation.outputs.package_paths }} conda_convert/linux-64 | ||
- name: upload to anaconda | ||
shell: bash -l {0} | ||
run: anaconda -t ${{ secrets.ANACONDA_TOKEN }} upload --no-progress --force conda_convert/*/* | ||
- name: Build linux-64 conda package | ||
uses: prefix-dev/[email protected] | ||
with: | ||
recipe-path: "conda/recipe.yaml" | ||
build-args: "--experimental --target-platform linux-64" | ||
- name: Build osx-64 conda package | ||
uses: prefix-dev/[email protected] | ||
with: | ||
recipe-path: "conda/recipe.yaml" | ||
build-args: "--experimental --target-platform osx-64" | ||
- name: Build osx-arm64 conda package | ||
uses: prefix-dev/[email protected] | ||
with: | ||
recipe-path: "conda/recipe.yaml" | ||
build-args: "--experimental --target-platform osx-arm64" | ||
- name: Upload conda package | ||
- run: | | ||
for pkg in $(find output -type f \( -name "*.conda" -o -name "*.tar.bz2" \) ); do | ||
echo "Uploading ${pkg}" | ||
rattler-build upload anaconda -o mittagessen -a ${{ secrets.ANACONDA_TOKEN }} "${pkg}" | ||
done | ||
- name: Upload conda artifacts to GH storage | ||
uses: actions/upload-artifact@v3 | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: conda_packages | ||
path: conda_convert/*/*.tar.bz2 | ||
path: output/*/*.conda | ||
|
||
autodraft-gh-release: | ||
name: Create github release | ||
needs: [build-n-publish-anaconda, build-n-publish-pypi] | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/download-artifact@v3 | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
name: conda_packages | ||
path: conda | ||
- uses: actions/download-artifact@v3 | ||
- uses: actions/download-artifact@v4 | ||
with: | ||
name: pypi_packages | ||
path: pypi | ||
|
@@ -138,11 +138,11 @@ jobs: | |
startsWith(github.ref, 'refs/tags/') | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Set up Python 3.9 | ||
uses: actions/setup-python@v4 | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.9 | ||
- name: Install sphinx-multiversion | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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