docs: Document translation building

Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
Joas Schilling
2025-07-15 15:38:33 +02:00
parent afd0077a25
commit 68760c04a0

View File

@ -143,6 +143,17 @@ Using venv
5. Now you can use ``make ...`` to build all the stuff - for example ``make html`` to build the HTML flavor of all manuals
The build assets will be put into the individual documentation subdirectories like ``developer_manual/_build/html/com``
Building translated versions
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Only available in user_manual:
1. Build the english version as described above before
2. Create translation files: ``../build/change_file_extension.sh``
3. Create German (``de``) version: ``make html-lang-de``
4. Find the HTML files in ``_build/html/de/index.html``
5. Before building another language you have to delete the complete ``_build`` directory
Autobuilding
^^^^^^^^^^^^
@ -157,6 +168,27 @@ When editing the documentation installing ``sphinx-autobuild`` though pip can be
Building PDF
============
Building inside docker
^^^^^^^^^^^^^^^^^^^^^^
1. Create a docker:: ``docker run --platform linux/amd64 --volume .:/docs --interactive --tty --name nextcloud-docs ghcr.io/nextcloud/continuous-integration-documentation:documentation-15 bash``
2. Change into the documentation directory: ``cd /docs``
3. Only once: Create a venv: ``python -m venv venv``
4. Activate the environment: ``source venv/bin/activate``
5. Install the dependencies ``pip install -r requirements.txt``
6. Change into the documentation of choice (admin, developer, user): ``cd /docs/user_manual``
7. To build the English version: ``make latexpdf``
8. To build the translated version (only available in user_manual):
1. Create translation files: ``../build/change_file_extension.sh``
2. Create German (``de``) version: ``make latexpdf-lang-de``
3. Find the file in ``_build/latex/Nextcloud_User_Manual.pdf``
4. Before building another language you have to delete the complete ``_build`` directory
Building locally
^^^^^^^^^^^^^^^^
.. note:: Because of the many dependencies LaTeX and the other tools bring in, it is not recommended to install the tools locally.
1. Follow instructions for "Building HTML" above
2. Install ``latexmk`` and ``texlive-latex-extra`` - https://pipenv.readthedocs.io/en/latest/
3. Create a Python environment (typically inside this repository): ``pipenv --python 3.9``