4
4
# http://creativecommons.org/licenses/by-sa/3.0.
5
5
6
6
import shutil
7
- import nox
8
7
8
+ import nox
9
9
10
10
nox .options .sessions = []
11
11
@@ -20,7 +20,7 @@ def translation(session):
20
20
session .run (
21
21
"sphinx-build" ,
22
22
"-b" , "gettext" , # build gettext-style message catalogs (.pot file)
23
- "-d" , ".nox/ .doctrees/ " , # path to put the cache
23
+ "-d" , session . cache_dir / " .doctrees" , # path to put the cache
24
24
"source/" , # where the rst files are located
25
25
target_dir , # where to put the .pot file
26
26
)
@@ -52,6 +52,7 @@ def build(session, autobuild=False):
52
52
command , * extra_args ,
53
53
"-j" , "auto" , # parallelize the build
54
54
"-b" , "html" , # use HTML builder
55
+ "-d" , session .cache_dir / ".doctrees" , # path to put the cache
55
56
"-n" , # nitpicky warn about all missing references
56
57
"-W" , # Treat warnings as errors.
57
58
* session .posargs ,
@@ -78,6 +79,7 @@ def linkcheck(session):
78
79
session .run (
79
80
"sphinx-build" ,
80
81
"-b" , "linkcheck" , # use linkcheck builder
82
+ "-d" , session .cache_dir / ".doctrees" , # path to put the cache
81
83
"--color" ,
82
84
"-n" , "-W" , "--keep-going" , # be strict
83
85
"source" , # where the rst files are located
0 commit comments