Update build.yml #85
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 | |
on: push | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Install Build Tools | |
run: | | |
curl -sSL https://install.python-poetry.org | python | |
echo $HOME/.poetry/bin >> $GITHUB_PATH | |
- uses: actions/[email protected] | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.7" | |
- name: Install Python Requirements | |
run: | | |
poetry install | |
- name: Build Package | |
run: | | |
poetry run pytest --cov=recline --cov-report=xml tests | |
poetry build | |
- name: Publish Package | |
if: startsWith(github.event.ref, 'refs/tags') | |
uses: pypa/gh-action-pypi-publish@release/v1.9 | |
with: | |
user: __token__ | |
password: ${{ secrets.pypi_password }} |