-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- poetry instead of pipenv - github actions over circleci - updates
- Loading branch information
Showing
12 changed files
with
691 additions
and
767 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
name: CI | ||
on: push | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Set up poetry | ||
uses: abatilo/actions-poetry@v2 | ||
with: | ||
poetry-version: "1.2.2" | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
cache: "poetry" | ||
- name: Check poetry file itself | ||
run: poetry check | ||
- name: Install package | ||
run: poetry install | ||
- name: Lint | ||
run: poetry run flake8 . | ||
- name: Autoformat check | ||
run: poetry run black . | ||
- name: Isort import order check | ||
run: poetry run isort -c . | ||
- name: Unit tests | ||
run: poetry run pytest | ||
- name: Coveralls | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: poetry run coveralls --service=github | ||
package: | ||
runs-on: ubuntu-latest | ||
if: startsWith(github.ref, 'refs/tags') | ||
needs: test | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Set up poetry | ||
uses: abatilo/actions-poetry@v2 | ||
with: | ||
poetry-version: "1.2.2" | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
cache: "poetry" | ||
- name: Install package | ||
run: poetry install | ||
- name: Create packages | ||
run: | | ||
poetry run python setup.py sdist | ||
poetry run python setup.py bdist_wheel | ||
- name: Publish to test PyPi | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
password: ${{ secrets.TEST_PYPI_API_TOKEN }} | ||
repository_url: https://test.pypi.org/legacy/ | ||
- name: Publish to PyPi | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
password: ${{ secrets.PYPI_API_TOKEN }} |
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.