Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use setup-python for cache #7442

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
22 changes: 4 additions & 18 deletions .github/workflows/ci-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,8 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: 3.9
- name: Cache PyPI
uses: actions/cache@v3.0.4
with:
key: pip-lint-${{ hashFiles('requirements/*.txt') }}
path: ~/.cache/pip
restore-keys: |
pip-lint-
cache: 'pip'
cache-dependency-path: 'requirements/*.txt'
- name: Update pip, wheel, setuptools, build, twine
run: |
python -m pip install -U pip wheel setuptools build twine
Expand Down Expand Up @@ -187,17 +182,8 @@ jobs:
with:
allow-prereleases: true
python-version: ${{ matrix.pyver }}
- name: Get pip cache dir
id: pip-cache
run: |
echo "::set-output name=dir::$(pip cache dir)" # - name: Cache
- name: Cache PyPI
uses: actions/cache@v3.0.4
with:
key: pip-ci-${{ runner.os }}-${{ matrix.pyver }}-${{ matrix.no-extensions }}-${{ hashFiles('requirements/*.txt') }}
path: ${{ steps.pip-cache.outputs.dir }}
restore-keys: |
pip-ci-${{ runner.os }}-${{ matrix.pyver }}-${{ matrix.no-extensions }}-
cache: 'pip'
cache-dependency-path: 'requirements/*.txt'
- name: Update pip, wheel, setuptools, build, twine
run: |
python -m pip install -U pip wheel setuptools build twine
Expand Down
8 changes: 2 additions & 6 deletions .github/workflows/post-dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,9 @@ jobs:
gh pr checkout ${{ github.event.pull_request.number }}
- name: Setup Python
uses: actions/setup-python@v4
- name: Cache PyPI
uses: actions/cache@v3.0.4
with:
key: post-update
path: ~/.cache/pip
restore-keys: |
post-update-
cache: 'pip'
cache-dependency-path: 'requirements/*.txt'
- name: Update pip-tools
run: |
python -m pip install -U pip-tools
Expand Down