Merge remote-tracking branch 'origin/master' #33
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
# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created | |
# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages | |
name: build | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
bump-version: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- run: pip3 install bump | |
- run: git config --global user.email "[email protected]" | |
- run: git config --global user.name "Danny Veldhoen" | |
# This will also trigger the bump action at the same time | |
- run: | | |
export VERSION=`bump` | |
git commit -m "Bumped version to $VERSION" -a | |
# Push back to repo | |
- run: git push https://${{secrets.GPR_TOKEN}}@github.com/dveldhoen/easyinvoice-pip | |
publish-to-pypi: | |
needs: bump-version | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
ref: 'master' | |
# Install build dependencies | |
- run: npm run install-dependencies | |
# Install npm dependecies | |
- run: npm i | |
# Build the package | |
- run: npm run build | |
# Publish the package | |
- run: python3 -m twine upload -u ${{secrets.PYPI_USERNAME}} -p ${{secrets.PYPI_PASSWORD}} dist/* | |