Fix test to run with Brian 2.6.0 #122
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: Build and publish to TestPyPI or PyPI | |
on: [push, pull_request] | |
jobs: | |
build-n-publish: | |
name: Build package and publish to (Test)PyPI | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python 3.x | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.x' | |
- name: Build source tarballs and wheels | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install build | |
python -m build | |
- name: Publish distribution 📦 to Test PyPI | |
if: github.ref == 'refs/heads/master' && github.repository == 'brian-team/brian2cuda' | |
run: | | |
python -m pip install twine | |
twine upload -r testpypi dist/* | |
env: | |
TWINE_USERNAME: __token__ | |
TWINE_PASSWORD: ${{ secrets.TEST_PYPI_API_TOKEN }} | |
- name: Publish distribution release 📦 to PyPI | |
if: ${{ startsWith(github.ref, 'refs/tags/v') && github.repository == 'brian-team/brian2cuda' }} | |
run: | | |
python -m pip install twine | |
twine upload dist/* | |
env: | |
TWINE_USERNAME: __token__ | |
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} |