48 lines
904 B
Markdown
48 lines
904 B
Markdown
# advanced-python-homework-2023
|
|
## 1. The sequence of commands to create the virtual enviroment:
|
|
```sh
|
|
sudo apt install python3.10-venv
|
|
cd advanced-python-homework-2023
|
|
python3 -m vemv devenv
|
|
source devenv/bin/activate
|
|
python3 -m pip install sphinx
|
|
python3 -m pip install Pylint
|
|
python3 -m pip install MyPy
|
|
deactivate
|
|
```
|
|
|
|
## 2. The sequence of commands to create the automated sphinx documentation:
|
|
```sh
|
|
cd advanced-python-homework-2023
|
|
mkdir doc
|
|
cd doc
|
|
sphinx-quickstart
|
|
cd ..
|
|
sphinx-apidoc -o doc .
|
|
cd doc
|
|
rm modules.rst
|
|
rm setup.rst
|
|
```
|
|
Move controls.rst to the source.
|
|
```
|
|
cd source
|
|
vim conf.py
|
|
```
|
|
import os
|
|
import sys
|
|
|
|
sys.path.insert(0, os.path.abspath(os.path.join("..", "..")))
|
|
|
|
extensions = ['sphinx.ext.autodoc']
|
|
```
|
|
vim index.rst
|
|
```
|
|
./controls.rst
|
|
```
|
|
cd ..
|
|
make html
|
|
```
|
|
Open file://wsl.localhost/Ubuntu/home/zefirka/advanced-python-homework-2023/doc/build/html/index.html
|
|
|
|
***Tadam***
|