1
+ name : " Docs: Check and Deploy"
2
+
3
+ on :
4
+ push :
5
+ branches : [main, github-actions-test]
6
+ pull_request :
7
+ branches : [main]
8
+ permissions :
9
+ contents : write
10
+
11
+ jobs :
12
+ build :
13
+ runs-on : ${{matrix.os}}
14
+ strategy :
15
+ matrix :
16
+ os : [ubuntu-latest]
17
+ python-version : [3.11.3]
18
+
19
+ steps :
20
+ - uses : actions/checkout@v3
21
+ - name : Build using Python ${{matrix.python-version}}
22
+ uses : actions/setup-python@v4
23
+ with :
24
+ python-version : ${{matrix.python-version}}
25
+ cache : " pip"
26
+ cache-dependency-path : " pyproject.toml"
27
+ - name : Install dependencies [pip]
28
+ run : |
29
+ pip install --upgrade pip setuptools wheel
30
+ pip install -e .[doc]
31
+ - name : Install Pandoc [apt-get]
32
+ run : |
33
+ sudo apt-get -y install pandoc
34
+ - name : Generate Docs [Sphinx]
35
+ run : |
36
+ sphinx-build -b html -D version=latest -D release=latest docs docs/_build
37
+ - name : Deploy Docs
38
+ uses : JamesIves/github-pages-deploy-action@v4
39
+ if : ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' && github.repository == 'geometric-intelligence/neurometry' }}
40
+ with :
41
+ branch : main
42
+ folder : docs/_build
43
+ token : ${{ secrets.DOCUMENTATION_KEY }}
44
+ repository-name : geometric-intelligence/geometric-intelligence.github.io
45
+ target-folder : neurometry
46
+ clean : true
47
+ numpydoc-validation :
48
+ runs-on : ${{matrix.os}}
49
+ strategy :
50
+ matrix :
51
+ os : [ubuntu-latest]
52
+ python-version : [3.11.3]
53
+
54
+ steps :
55
+ - uses : actions/checkout@v3
56
+ - name : Build using Python ${{matrix.python-version}}
57
+ uses : actions/setup-python@v4
58
+ with :
59
+ python-version : ${{matrix.python-version}}
60
+ cache : " pip"
61
+ cache-dependency-path : " pyproject.toml"
62
+ - name : Install dependencies [pip]
63
+ run : |
64
+ pip install --upgrade pip setuptools wheel
65
+ pip install -e .[doc]
66
+ - name : Checking NumpyDoc Validation for files
67
+ run : |
68
+ pip install pre-commit
69
+ pre-commit install
70
+ pre-commit run --all-files numpydoc-validation
0 commit comments