Skip to content

Commit

Permalink
ci: use pip cache dir
Browse files Browse the repository at this point in the history
  • Loading branch information
peaceiris authored Apr 30, 2020
1 parent 6fea3a9 commit 4e1362e
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,26 @@ jobs:
python-version: '3.8'
architecture: 'x64'

- name: Upgrade pip
run: |
python3 -m pip install --upgrade pip
python3 -V
python3 -m pip -V
- name: Get pip cache dir
id: pip-cache
run: echo "::set-output name=dir::$(pip cache dir)"

- name: Cache dependencies
uses: actions/cache@v1
with:
path: ~/.cache/pip
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements.txt
run: python3 -m pip install -r ./requirements.txt

- run: mkdocs build --config-file ./mkdocs-sample.yml

Expand Down

0 comments on commit 4e1362e

Please sign in to comment.