Commit dc729fe158f097e41c609a4bb1a5edd434d04416
1 parent
83cfb55c
Exists in
dev
Sphinx autodoc generation (v9) + pyreverse + pdf & Dockerfile install guitastro + bash aliases
Showing
5 changed files
with
32 additions
and
11 deletions
Show diff stats
Dockerfile
... | ... | @@ -74,14 +74,14 @@ RUN rm ./astap_amd64.deb |
74 | 74 | RUN echo | openssl s_client -connect gitlab.irap.omp.eu:443 -servername gitlab.irap.omp.eu 2>/dev/null | openssl x509 > /etc/ssl/certs/gitlab.irap.omp.eu.crt |
75 | 75 | |
76 | 76 | RUN echo "$uid" > test.txt |
77 | -# adding new user (pyros_user) and creating his home folder | |
77 | +# Adding new user (pyros_user) and creating his home folder | |
78 | 78 | RUN useradd --create-home --shell /bin/bash pyros_user --uid $uid |
79 | 79 | |
80 | 80 | # Create the work dir and set permissions as pyros_user |
81 | 81 | RUN mkdir -p /home/pyros_user/app/ && chown -R pyros_user:pyros_user /home/pyros_user/app |
82 | 82 | WORKDIR /home/pyros_user/app |
83 | 83 | |
84 | -# switch from root to pyros_user | |
84 | +# Switch from root to pyros_user | |
85 | 85 | USER pyros_user |
86 | 86 | |
87 | 87 | RUN pip install --user --upgrade pip |
... | ... | @@ -89,15 +89,19 @@ RUN pip install --user wheel |
89 | 89 | # TODO: pourquoi numpy ??? A virer ? |
90 | 90 | RUN pip install --user numpy |
91 | 91 | |
92 | -# copy local host machine files to image | |
92 | +# Copy local host machine files to image | |
93 | 93 | COPY --chown=pyros_user:pyros_user . . |
94 | +# Copy some aliases | |
95 | +RUN cp .bash_aliases .. | |
96 | +#RUN mv .bash_aliases .. | |
97 | +#COPY --chown=pyros_user:pyros_user .bash_aliases .. | |
94 | 98 | |
95 | -# adding local/bin to path to avoid pip warning | |
99 | +# Adding local/bin to path to avoid pip warning | |
96 | 100 | ENV PATH "$PATH:/home/pyros_user/.local/bin" |
97 | 101 | |
98 | -# installing click on the image to prevent error on the first execution of the installation script | |
102 | +# Installing click on the image to prevent error on the first execution of the installation script | |
99 | 103 | RUN pip install --user click |
100 | 104 | |
101 | -# installing packages required for PyROS | |
105 | +# Installing packages required for PyROS | |
102 | 106 | RUN pip install --user -r ./install/requirements.txt |
103 | 107 | RUN pip install --user -r ./install/requirements_dev.txt | ... | ... |
doc/doc_rst/.gitignore
doc/doc_rst/make_rst_then_html
... | ... | @@ -38,12 +38,15 @@ pwd |
38 | 38 | echo |
39 | 39 | echo "- Codestyle : generating UML class diagrams and API doc" |
40 | 40 | echo |
41 | -echo "-- generating UML class diagrams (pyreverse)" | |
41 | +echo "-- generating UML class diagrams in source/doc_images/generated/ (pyreverse)" | |
42 | +echo | |
42 | 43 | cd ../codestyle_examples/ |
43 | 44 | pyreverse -p codestyle_examples -o png codestyle_examples |
44 | 45 | cd - |
45 | 46 | mv ../codestyle_examples/*.png source/doc_images/generated/ |
47 | +echo | |
46 | 48 | echo "-- generating API doc RST files (Sphinx)" |
49 | +echo | |
47 | 50 | sphinx-apidoc -f -o source/generated_api -a --separate --module-first --tocfile codestyle_examples_package ../codestyle_examples |
48 | 51 | ##sphinx-apidoc -f -o source -a --separate --module-first --tocfile codestyle_examples_package ../codestyle_examples |
49 | 52 | #sphinx-apidoc -o source -a --separate --module-first --tocfile code_style_package ../code_style/my_package1 |
... | ... | @@ -55,6 +58,12 @@ sphinx-apidoc -f -o source/generated_api -a --separate --module-first --tocfile |
55 | 58 | # B - Generate HTML (and pdf) files (from RST) |
56 | 59 | # --------------------------------- |
57 | 60 | |
58 | -echo "-- generating API doc HTML files (from RST, with Sphinx)" | |
59 | -sphinx-build -b html source build/html/ | |
60 | -#sphinx-build -b pdf source build | |
61 | +echo | |
62 | +echo "-- generating API doc HTML files in build/html/index.html (from RST, with Sphinx)" | |
63 | +echo | |
64 | +sphinx-build -b html ./source/ build/html/ | |
65 | + | |
66 | +echo | |
67 | +echo "-- generating API doc HTML files in build/pdf/Python.pdf (from RST, with Sphinx)" | |
68 | +echo | |
69 | +sphinx-build -b pdf source build/pdf/ | ... | ... |
doc/doc_rst/source/conf.py
... | ... | @@ -214,3 +214,8 @@ html_theme = 'sphinx_rtd_theme' |
214 | 214 | html_static_path = ['_static'] |
215 | 215 | |
216 | 216 | autosummary_generate = True |
217 | + | |
218 | +# Added to avoid this error : | |
219 | +# [ERROR] createpdf.py:1134 Template 'twoColumn' is not defined | |
220 | +# => twoColumn is no longer part of the default styles in rst2pdf 0.99, so you now need to explicitly include the twoColumn style file. | |
221 | +pdf_stylesheets = ['twocolumn'] | ... | ... |