Skip to content

Commit

Permalink
bump up python action and use its pip caching (#187)
Browse files Browse the repository at this point in the history
  • Loading branch information
zingale authored Jan 21, 2024
1 parent d28ed7a commit 3edc9fe
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 70 deletions.
12 changes: 2 additions & 10 deletions .github/workflows/docs-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,18 +21,10 @@ jobs:
sudo apt install pandoc doxygen
- name: Setup Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: '3.10'

- name: Cache pip
uses: actions/cache@v3
with:
# this path is specific to Ubuntu
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: "pip"

- name: Install dependencies
run: pip install -r ./requirements.txt
Expand Down
12 changes: 2 additions & 10 deletions .github/workflows/flake8.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,10 @@ jobs:
- uses: actions/checkout@v4

- name: Install Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: '3.10'

- name: Cache pip
uses: actions/cache@v3
with:
# this path is specific to Ubuntu
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: "pip"

- name: Install dependencies
run: |
Expand Down
12 changes: 2 additions & 10 deletions .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,10 @@ jobs:
sudo apt install pandoc doxygen
- name: Setup Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: '3.10'

- name: Cache pip
uses: actions/cache@v3
with:
# this path is specific to Ubuntu
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: "pip"

- name: Install dependencies
run: pip install -r ./requirements.txt
Expand Down
12 changes: 2 additions & 10 deletions .github/workflows/isort.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,10 @@ jobs:
- uses: actions/checkout@v4

- name: Install Python 3.10
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: '3.10'

- name: Cache pip
uses: actions/cache@v3
with:
# this path is specific to Ubuntu
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: "pip"

- name: Install dependencies + isort
run: |
Expand Down
12 changes: 2 additions & 10 deletions .github/workflows/pylint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,10 @@ jobs:
- uses: actions/checkout@v4

- name: Install Python 3.10
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: '3.10'

- name: Cache pip
uses: actions/cache@v3
with:
# this path is specific to Ubuntu
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: "pip"

- name: Install dependencies + pylint
run: |
Expand Down
12 changes: 2 additions & 10 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,10 @@ jobs:
- uses: actions/checkout@v4

- name: Install Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Cache pip
uses: actions/cache@v3
with:
# this path is specific to Ubuntu
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: "pip"

- name: Install dependencies
run: |
Expand Down
12 changes: 2 additions & 10 deletions .github/workflows/regtest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,10 @@ jobs:
- uses: actions/checkout@v4

- name: Install Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Cache pip
uses: actions/cache@v3
with:
# this path is specific to Ubuntu
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: "pip"

- name: Install dependencies
run: |
Expand Down

0 comments on commit 3edc9fe

Please sign in to comment.