Bump version: 0.2.0 → 0.2.1 #34
Workflow file for this run
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: CI | |
on: | |
push: | |
pull_request: | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: [3.7, 3.8, 3.9, '3.10', '3.11'] | |
steps: | |
- name: checkout | |
uses: actions/checkout@v3 | |
- name: install rust toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly | |
default: true | |
- name: run rust tests | |
uses: actions-rs/cargo@v1 | |
with: | |
command: test | |
args: test_ | |
- name: set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: install Python requirements | |
run: pip install tox | |
- name: test with tox | |
run: tox -e py | |
bench: | |
runs-on: ubuntu-latest | |
steps: | |
- name: checkout | |
uses: actions/checkout@v3 | |
- name: install rust toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly | |
default: true | |
- name: run rust tests | |
uses: actions-rs/cargo@v1 | |
with: | |
command: bench | |
test_rust_eip_152_vec_8: | |
runs-on: ubuntu-latest | |
steps: | |
- name: checkout | |
uses: actions/checkout@v3 | |
- name: install rust toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly | |
default: true | |
- name: run rust tests | |
uses: actions-rs/cargo@v1 | |
with: | |
command: test | |
args: --release test_f_compress_eip_152_vec_8 -- --ignored --nocapture | |
build: | |
runs-on: ${{ matrix.os }} | |
needs: | |
- test | |
- bench | |
- test_rust_eip_152_vec_8 | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: [3.7, 3.8, 3.9, '3.10', '3.11'] | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
steps: | |
- name: checkout | |
uses: actions/checkout@v3 | |
- name: install rust toolchain | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly | |
default: true | |
- name: set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: install Python requirements | |
run: pip install maturin | |
- name: build Python package | |
run: maturin build --sdist --release --strip --interpreter python | |
# We run this job until here for every build so that we notice early if there's anything | |
# that would prevent to publish a release. But the actual publishing only happens when we | |
# create an actual Github release. | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
files: | | |
target/wheels/blake2b_py*.whl | |
target/wheels/blake2b_py*.tar.gz | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: PyPi publish | |
if: startsWith(github.ref, 'refs/tags/') | |
env: | |
MATURIN_PASSWORD: ${{ secrets.PYPI }} | |
run: maturin publish --sdist --username __token__ --interpreter python |