File tree 9 files changed +22
-25
lines changed
9 files changed +22
-25
lines changed Original file line number Diff line number Diff line change 19
19
name : build docs
20
20
no_output_timeout : 25m
21
21
command : |
22
- pip install .[ doc]
22
+ pip install -r doc-requirements.txt
23
23
make spec
24
24
- store_artifacts :
25
25
path : _site/
Original file line number Diff line number Diff line change 76
76
# Install dependencies:
77
77
- name : ' Install dependencies'
78
78
run : |
79
- pip install .[ doc]
79
+ pip install -r doc-requirements.txt
80
80
81
81
# Generate the documentation:
82
82
- name : ' Build documentation'
Original file line number Diff line number Diff line change @@ -3,13 +3,10 @@ SPHINXOPTS ?= -W --keep-going
3
3
SOURCEDIR = spec
4
4
BUILDDIR = _site
5
5
6
- .PHONY : default install clean draft spec
6
+ .PHONY : default clean draft spec
7
7
8
8
default : clean spec
9
9
10
- install :
11
- pip install -e .[doc]
12
-
13
10
clean :
14
11
rm -rf $(BUILDDIR )
15
12
find . -type d -name generated -exec rm -rf {} +
Original file line number Diff line number Diff line change @@ -21,11 +21,11 @@ this array API standard.
21
21
### Quickstart
22
22
23
23
To install the local stubs and additional dependencies of the Sphinx docs, you
24
- can use ` make install` . Then just running ` make ` at the root of the repository
25
- should build the whole spec website.
24
+ can use ` pip install -r doc-requirements.txt ` . Then just running ` make ` at the
25
+ root of the repository should build the whole spec website.
26
26
27
27
``` sh
28
- $ make install
28
+ $ pip install -r doc-requirements.txt
29
29
$ make
30
30
$ ls _site/
31
31
2021.12/ draft/ index.html latest/ versions.json
@@ -35,11 +35,9 @@ $ ls _site/
35
35
36
36
The spec website is comprised of multiple Sphinx docs (one for each spec version),
37
37
all of which exist in ` spec/ ` and rely on the modules found in ` src/ ` (most
38
- notably ` array_api_stubs ` ). ` make install ` aliases
39
-
40
- ``` sh
41
- $ pip install -e .[doc] # ensure you install the dependencies extra "doc"
42
- ```
38
+ notably ` array_api_stubs ` ). For purposes of building the docs, these ` src/ `
39
+ modules do not need to be installed as they are added to the ` sys.path ` at
40
+ runtime.
43
41
44
42
To build specific versions of the spec, run ` sphinx-build ` on the respective
45
43
folder in ` spec/ ` , e.g.
Original file line number Diff line number Diff line change
1
+ sphinx==4.3.0
2
+ sphinx-material==0.0.30
3
+ myst-parser
4
+ sphinx_markdown_tables
5
+ sphinx_copybutton
6
+ docutils<0.18
7
+ sphinx-math-dollar
Original file line number Diff line number Diff line change @@ -14,17 +14,6 @@ Source = "https://github.com/data-apis/array-api/"
14
14
Documentation = " https://data-apis.org/array-api/"
15
15
Homepage = " https://data-apis.org/"
16
16
17
- [project .optional-dependencies ]
18
- doc = [
19
- " sphinx==4.3.0" ,
20
- " sphinx-material==0.0.30" ,
21
- " myst-parser" ,
22
- " sphinx_markdown_tables" ,
23
- " sphinx_copybutton" ,
24
- " docutils<0.18" ,
25
- " sphinx-math-dollar" ,
26
- ]
27
-
28
17
[build-system ]
29
18
requires = [" setuptools" ]
30
19
build-backend = " setuptools.build_meta"
Original file line number Diff line number Diff line change 1
1
import sys
2
+ from pathlib import Path
3
+ sys .path .insert (0 , str (Path (__file__ ).parents [2 ] / "src" ))
2
4
3
5
from array_api_stubs import _2021_12 as stubs_mod
4
6
from _array_api_conf import *
Original file line number Diff line number Diff line change 1
1
import sys
2
+ from pathlib import Path
3
+ sys .path .insert (0 , str (Path (__file__ ).parents [2 ] / "src" ))
2
4
3
5
from array_api_stubs import _2022_12 as stubs_mod
4
6
from _array_api_conf import *
Original file line number Diff line number Diff line change 1
1
import sys
2
+ from pathlib import Path
3
+ sys .path .insert (0 , str (Path (__file__ ).parents [2 ] / "src" ))
2
4
3
5
from array_api_stubs import _draft as stubs_mod
4
6
from _array_api_conf import *
You can’t perform that action at this time.
0 commit comments