Skip to content

Commit

Permalink
Merge pull request #60 from haasad/release-pipelines
Browse files Browse the repository at this point in the history
Rework release pipelines
  • Loading branch information
haasad authored Nov 18, 2023
2 parents a96f000 + 81409d6 commit badab3f
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 57 deletions.
26 changes: 11 additions & 15 deletions .github/workflows/conda-release.yaml
Original file line number Diff line number Diff line change
@@ -1,35 +1,31 @@
name: conda-release

on:
push:
branches:
- master
- conda-release
tags:
- 'v*'
release:
types: [published]

jobs:
build-and-publish:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v2
- name: Set up miniconda with python 3.9
uses: conda-incubator/setup-miniconda@v2
with:
python-version: 3.9
activate-environment: test
environment-file: environment.yml
auto-activate-base: false
activate-environment: build
- name: Install build tools
shell: bash -l {0}
run: |
conda install conda-build anaconda-client conda-verify
conda install conda-build anaconda-client conda-verify grayskull
- name: Generate conda recipe
run: |
grayskull pypi https://github.com/haasad/PyPardiso --sections {package,source,build,requirements,about}
- name: Build conda package
shell: bash -l {0}
run: |
conda build .
conda build PyPardiso
- name: Upload to haasad conda channel
if: startsWith(github.ref, 'refs/tags/v')
shell: bash -l {0}
run: |
anaconda -t ${{ secrets.CONDA_TOKEN }} upload /usr/share/miniconda/envs/test/conda-bld/noarch/*.tar.bz2
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
name: Release
name: github-release
on:
push:
branches:
- master
tags:
- v*
- 'v*'

jobs:
dist:
github-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
fetch-depth: "0"
- name: Build changelog from PRs with labels
id: build_changelog
uses: mikepenz/release-changelog-builder-action@v2
uses: mikepenz/release-changelog-builder-action@v4
with:
configuration: ".github/changelog-configuration.json"
# PreReleases still get a changelog, but the next full release gets a diff since the last full release,
Expand All @@ -29,4 +31,4 @@ jobs:
prerelease: "${{ contains(github.ref, '-rc') }}"
# Ensure target branch for release is "master"
commit: master
token: ${{ secrets.GITHUB_TOKEN }}
token: ${{ secrets.RELEASE_TOKEN }}
13 changes: 6 additions & 7 deletions .github/workflows/pypi-release.yaml
Original file line number Diff line number Diff line change
@@ -1,21 +1,20 @@
name: PyPI release

on:
push:
branches:
- master
tags:
- 'v*'
release:
types: [published]

jobs:
build-and-publish:
name: Build and publish to PyPI
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
fetch-depth: "0"
- name: Set up python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: 3.9
- name: Install dependencies
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
python-version: ["3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up miniconda with python ${{ matrix.python-version }}
uses: conda-incubator/setup-miniconda@v2
with:
Expand Down Expand Up @@ -56,7 +56,7 @@ jobs:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
Expand Down
27 changes: 0 additions & 27 deletions meta.yaml

This file was deleted.

0 comments on commit badab3f

Please sign in to comment.