Skip to content

Commit

Permalink
Use setup-python's cache option
Browse files Browse the repository at this point in the history
  • Loading branch information
Perlence committed Dec 16, 2024
1 parent cf92ca2 commit dfec436
Showing 1 changed file with 2 additions and 16 deletions.
18 changes: 2 additions & 16 deletions .github/workflows/tests-and-codestyle.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -97,19 +97,12 @@ jobs:
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}
cache: pip
- name: update pip
run: |
pip install -U wheel
pip install -U setuptools
python -m pip install -U pip
- name: get pip cache dir
id: pip-cache
run: echo "dir=$(pip cache dir)" >> $GITHUB_OUTPUT
- name: cache pip
uses: actions/cache@v4
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: pip-tests|${{ matrix.python }}|${{ matrix.django }}
- run: pip install Django==${{ matrix.django }}
- run: pip install -e .
- run: python setup.py test
Expand All @@ -130,19 +123,12 @@ jobs:
- uses: actions/setup-python@v5
with:
python-version: 3.x
cache: pip
- name: update pip
run: |
pip install -U wheel
pip install -U setuptools
python -m pip install -U pip
- name: get pip cache dir
id: pip-cache
run: echo "dir=$(pip cache dir)" >> $GITHUB_OUTPUT
- name: cache pip
uses: actions/cache@v4
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: pip-codestyle
- run: pip install -U flake8
- run: flake8
- name: Notify slack fail
Expand Down

0 comments on commit dfec436

Please sign in to comment.