Skip to content

Commit 769744e

Browse files
authored
Documentation: housekeeping dependencies and CI (#175)
2 parents 7eebac0 + 626fbcb commit 769744e

File tree

4 files changed

+20
-6
lines changed

4 files changed

+20
-6
lines changed

.github/workflows/documentation.yml

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,12 @@ on:
1313
tags:
1414
- "*"
1515

16+
pull_request:
17+
branches: [main]
18+
paths:
19+
- ".github/workflows/documentation.yml"
20+
- requirements/documentation.txt
21+
1622
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
1723
permissions:
1824
contents: read
@@ -54,15 +60,26 @@ jobs:
5460
- name: Build static website
5561
run: mkdocs build --verbose
5662

63+
- name: Save build doc as artifact
64+
uses: actions/upload-artifact@v3
65+
with:
66+
name: documentation
67+
path: site/
68+
if-no-files-found: error
69+
retention-days: 30
70+
5771
- name: Setup Pages
5872
uses: actions/configure-pages@v3
73+
if: github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/main')
5974

6075
- name: Upload artifact
6176
uses: actions/upload-pages-artifact@v1
77+
if: github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/main')
6278
with:
6379
# Upload entire repository
64-
path: site
80+
path: site/
6581

6682
- name: Deploy to GitHub Pages
6783
id: deployment
84+
if: github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/main')
6885
uses: actions/deploy-pages@v1

requirements.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
setuptools
2-
wheel
3-
41
-r requirements/base.txt
52

63
-e "."

requirements/development.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@
55
black
66
feedparser>=6.0,<6.1
77
flake8>=4,<6.1
8-
pre-commit>=2.10,<3.1
8+
pre-commit>=3,<3.2
99
pytest-cov==4.0.*
1010
validator-collection>=1.5,<1.6

requirements/documentation.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Documentation
22
# -----------------------
33
mkdocs-bootswatch>=1,<2
4-
mkdocs-minify-plugin==0.5.*
4+
mkdocs-minify-plugin==0.6.*
55
pygments>=2.5,<3
66
pymdown-extensions>=7,<10

0 commit comments

Comments
 (0)