Skip to content

Commit

Permalink
Add caching to CI
Browse files Browse the repository at this point in the history
  • Loading branch information
hynek committed Sep 5, 2023
1 parent 02575ea commit 10c4748
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@ env:
sdist-artifact: python-package-distributions
sdist-name: environ_config-1.0.tar.gz

# N.B. default Python version for setup-python comes from the .python-version
# file at the root of the project.


permissions:
contents: read

Expand All @@ -32,6 +28,8 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
cache: pip

- run: python -Im pip install --upgrade wheel nox

Expand All @@ -44,6 +42,8 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
cache: pip
- run: python -Im pip install build

- run: python -Im build --sdist
Expand Down Expand Up @@ -88,6 +88,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
cache: pip

- run: python -Im pip install --upgrade wheel nox

Expand All @@ -112,6 +113,8 @@ jobs:
source-tarball-name: ${{ env.sdist-name }}
workflow-artifact-name: ${{ env.sdist-artifact }}
- uses: actions/setup-python@v4
with:
cache: pip

- run: python -Im pip install --upgrade coverage[toml]

Expand Down Expand Up @@ -167,6 +170,8 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
cache: pip

- run: python -Im pip install --upgrade wheel nox

- run: python -Im nox -e mypy
Expand All @@ -183,6 +188,7 @@ jobs:
workflow-artifact-name: ${{ env.sdist-artifact }}
- uses: actions/setup-python@v4
with:
cache: pip
# [[[cog
# import yaml
# with open(".readthedocs.yaml") as f:
Expand All @@ -205,6 +211,8 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
cache: pip

- run: python -Im pip install -e .[dev]
- run: python -c 'import environ; print(environ.__version__)'
Expand Down

0 comments on commit 10c4748

Please sign in to comment.