mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-06-14 11:52:32 +03:00
Improve GitHub Actions workflows
This commit is contained in:
parent
433c137bc1
commit
c23fbdfc84
1
.github/workflows/build.yml
vendored
1
.github/workflows/build.yml
vendored
@ -78,6 +78,7 @@ jobs:
|
|||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: ${{ env.PYTHON_VERSION }}
|
python-version: ${{ env.PYTHON_VERSION }}
|
||||||
|
cache: pip
|
||||||
|
|
||||||
- name: Set up Python dependencies
|
- name: Set up Python dependencies
|
||||||
run: pip install --upgrade build twine
|
run: pip install --upgrade build twine
|
||||||
|
26
.github/workflows/documentation.yml
vendored
26
.github/workflows/documentation.yml
vendored
@ -45,15 +45,12 @@ jobs:
|
|||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v4
|
||||||
with:
|
with:
|
||||||
python-version: ${{ env.PYTHON_VERSION }}
|
python-version: ${{ env.PYTHON_VERSION }}
|
||||||
|
cache: pip
|
||||||
- name: Set the date environmental variable
|
|
||||||
run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
|
|
||||||
|
|
||||||
- name: Set up build cache
|
- name: Set up build cache
|
||||||
uses: actions/cache@v3
|
uses: actions/cache/restore@v3
|
||||||
id: cache
|
|
||||||
with:
|
with:
|
||||||
key: mkdocs-material-${{ env.cache_id }}
|
key: mkdocs-material-
|
||||||
path: .cache
|
path: .cache
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
mkdocs-material-
|
mkdocs-material-
|
||||||
@ -63,15 +60,8 @@ jobs:
|
|||||||
|
|
||||||
- name: Install Python dependencies
|
- name: Install Python dependencies
|
||||||
run: |
|
run: |
|
||||||
pip install \
|
pip install mkdocs-material
|
||||||
"cairosvg>=2.5" \
|
pip install mkdocs-material[recommended,git,imaging]
|
||||||
"mkdocs-git-committers-plugin-2>=1.1.1" \
|
|
||||||
"mkdocs-git-revision-date-localized-plugin>=1.0" \
|
|
||||||
"mkdocs-minify-plugin>=0.3" \
|
|
||||||
"mkdocs-rss-plugin>=1.2" \
|
|
||||||
"mkdocs-redirects>=1.0" \
|
|
||||||
"lxml" \
|
|
||||||
"pillow<10"
|
|
||||||
|
|
||||||
- name: Install Insiders build
|
- name: Install Insiders build
|
||||||
if: github.event.repository.fork == false
|
if: github.event.repository.fork == false
|
||||||
@ -95,3 +85,9 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
mkdocs gh-deploy --force
|
mkdocs gh-deploy --force
|
||||||
mkdocs --version
|
mkdocs --version
|
||||||
|
|
||||||
|
- name: Save build cache
|
||||||
|
uses: actions/cache/save@v3
|
||||||
|
with:
|
||||||
|
key: mkdocs-material-${{ hashfiles('.cache/**') }}
|
||||||
|
path: .cache
|
||||||
|
Loading…
Reference in New Issue
Block a user