-
Notifications
You must be signed in to change notification settings - Fork 3
65 lines (58 loc) · 1.78 KB
/
deploy_gh-pages.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
name: MkDocs Deploy
on:
workflow_dispatch:
push:
branches:
- main
paths:
- 'docs/**'
- 'mkdocs.yml'
jobs:
linters:
name: Repository linters
runs-on: ubuntu-latest
steps:
- name: Check out the code
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # @v4.2.2
- name: Install NodeJs # Install Software NodeJs
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # @v4.1.0
with:
node-version: 16
- name: Install repo-linter
run: |
npm install -g repolinter
- name: Run Repo Linter
run: |
repolinter --rulesetFile cfg/repolint.json lint .
scan:
name: gitleaks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
fetch-depth: 0
- uses: gitleaks/gitleaks-action@83373cf2f8c4db6e24b41c1a9b086bb9619e9cd3
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITLEAKS_CONFIG: cfg/gitleaks.toml
build:
name: MkDocs Github Pages automatic deployment
runs-on: ubuntu-latest
needs:
- linters
- scan
steps:
- name: Checkout main
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- name: Set up Python 3.9
uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d
with:
python-version: '3.9'
- name: Install requirements
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: MkDocs gh-deploy
run: |
git pull
mkdocs gh-deploy -v