Skip to content

Commit

Permalink
Add pip caches to CI
Browse files Browse the repository at this point in the history
  • Loading branch information
ml-evs committed Dec 20, 2022
1 parent 0d4b678 commit 26fb17f
Showing 1 changed file with 16 additions and 23 deletions.
39 changes: 16 additions & 23 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,29 +17,6 @@ concurrency:
cancel-in-progress: true

jobs:
lint:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: '3.10'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -U setuptools wheel
pip install flake8
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --statistics

pre-commit:
runs-on: ubuntu-latest
Expand All @@ -53,6 +30,10 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: '3.8'
cache: 'pip'
cache-dependency-path: |
requirements*.txt
- name: Install dependencies
run: |
Expand All @@ -79,6 +60,9 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip'
cache-dependency-path: |
requirements*.txt
- name: Install tools
run: |
Expand Down Expand Up @@ -186,6 +170,9 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
cache-dependency-path: |
requirements*.txt
- name: Install latest compatible versions of immediate dependencies
run: |
Expand Down Expand Up @@ -304,6 +291,9 @@ jobs:
- uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip'
cache-dependency-path: |
requirements*.txt
- name: Install dependencies
run: |
Expand Down Expand Up @@ -334,6 +324,9 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: '3.10'
cache: 'pip'
cache-dependency-path: |
requirements*.txt
- name: Install Python dependencies
run: |
Expand Down

0 comments on commit 26fb17f

Please sign in to comment.