File tree Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change 17
17
SPHINX_IMAGE=sengorius/sphinx:3
18
18
DOCKER_START=" docker run --rm -u $( id -u) :$( id -g) -v $CURRENT_DIR /docs:/var/documentation -it $SPHINX_IMAGE "
19
19
20
+ function fix_static_links() {
21
+ if [[ -d " $CURRENT_DIR /docs/build/html" ]]; then
22
+ mv ${CURRENT_DIR} /docs/build/html/_static ${CURRENT_DIR} /docs/build/html/static
23
+ find ${CURRENT_DIR} /docs/build/html -type f -exec sed -i ' s/_static/static/g' {} \;
24
+ echo " Renamed directory _static to static and fixed links within all files."
25
+ fi
26
+ }
27
+
20
28
# and run it with the given command
21
29
if [[ " init" == " $COMMAND " ]]; then
22
30
${DOCKER_START} sphinx-quickstart
23
31
elif [[ " make" == " $COMMAND " ]]; then
24
32
${DOCKER_START} make html
33
+ fix_static_links
25
34
elif [[ " release" == " $COMMAND " ]]; then
26
35
${DOCKER_START} make html
36
+ fix_static_links
27
37
28
38
if [[ -d " $CURRENT_DIR /docs/build/html" ]]; then
29
39
if [[ -d " $CURRENT_DIR /docs/docs" ]]; then
Original file line number Diff line number Diff line change 50
50
# relative to this directory. They are copied after the builtin static files,
51
51
# so a file named "default.css" will overwrite the builtin "default.css".
52
52
html_static_path = ['_static' ]
53
- html_css_files = ['additional.css' ]
53
+ html_css_files = ['additional.css' ]
54
+ html_copy_source = False
55
+ html_show_sourcelink = False
You can’t perform that action at this time.
0 commit comments