mirror of
https://github.com/fhswf/aki_prj23_transparenzregister.git
synced 2025-06-22 11:53:55 +02:00
Using the python action and the inbuild poetry cache (#261)
I have found out that the python setup action supports the use of the poetry cache which increases the build speed.
This commit is contained in:
30
.github/workflows/lint-actions.yaml
vendored
30
.github/workflows/lint-actions.yaml
vendored
@ -18,23 +18,19 @@ jobs:
|
||||
mypy:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Install poetry
|
||||
run: pipx install poetry
|
||||
- name: Set up python
|
||||
id: setup-python
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: '3.11'
|
||||
- name: Check out Git repository
|
||||
uses: actions/checkout@v4
|
||||
- name: Install and configure Poetry
|
||||
uses: snok/install-poetry@v1
|
||||
with:
|
||||
version: 1.6.1
|
||||
virtualenvs-create: false
|
||||
virtualenvs-path: ~/local/share/virtualenvs
|
||||
cache: poetry
|
||||
- run: poetry install --without develop,doc --all-extras
|
||||
- name: Run mypy
|
||||
run: |
|
||||
mypy src tests
|
||||
poetry run mypy src tests
|
||||
|
||||
ruff:
|
||||
runs-on: ubuntu-latest
|
||||
@ -48,22 +44,16 @@ jobs:
|
||||
name: Check Python Requirements
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Install poetry
|
||||
run: pipx install poetry
|
||||
- name: Set up python
|
||||
id: setup-python
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: '3.11'
|
||||
- name: Install and configure Poetry
|
||||
uses: snok/install-poetry@v1
|
||||
with:
|
||||
version: 1.6.1
|
||||
virtualenvs-create: true
|
||||
virtualenvs-path: ~/local/share/virtualenvs
|
||||
- name: Check out Git repository
|
||||
uses: actions/checkout@v4
|
||||
- name: Install root, pip-licenses & pip-audit
|
||||
run: |
|
||||
poetry run pip install pip-licenses pip-audit
|
||||
cache: poetry
|
||||
- run: poetry install --without develop,doc --all-extras
|
||||
- name: Poetry export
|
||||
run: poetry export -f requirements.txt --output requirements.txt
|
||||
- name: Check license
|
||||
|
Reference in New Issue
Block a user