Skip to content

Commit

Permalink
Corrects docs/ publish instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
prasadtalasila committed Sep 27, 2023
1 parent 3be8da0 commit 088669a
Showing 1 changed file with 33 additions and 7 deletions.
40 changes: 33 additions & 7 deletions docs/PUBLISH.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@

# Project Documentation

This file contains instructions for creation, compilation and publication of project documentation.
This file contains instructions for creation, compilation and publication of
project documentation.

The documentation system is based on [Material for Mkdocs](https://squidfunk.github.io/mkdocs-material/). The documentation is generated based on the configuration files:
The documentation system is based on
[Material for Mkdocs](https://squidfunk.github.io/mkdocs-material/).
The documentation is generated based on the configuration files:

* **mkdocs.yml**: used for generating online documentation which is hosted on the web
* **mkdocs_offline.yml**: used for generating offline documentation that can be downloaded and used on user computer.
* **mkdocs-github.yml**: used for generating documentation in github actions

Install Mkdocs using the following command.

Expand All @@ -16,24 +19,47 @@ pip install -r docs/requirements.txt

## Create documentation

You can add, and edit the markdown files in `docs/` directory to update the documentation. There is a facility to check the status of your documentation by using:
The document generation pipeline can generate both **html** and **pdf**
versions of documentation.

The generation of **pdf** version of documentation is controlled via
a shell variable.

```bash
export MKDOCS_ENABLE_PDF_EXPORT=0 #disables generation of pdf document
export MKDOCS_ENABLE_PDF_EXPORT=1 #enables generation of pdf document
```

The `mkdocs` utility allows for live editing of documentation
on the developer computer.

You can add, and edit the markdown files in `docs/` directory to update
the documentation. There is a facility to check the status of your
documentation by using:

```bash
mkdocs serve --config-file mkdocs.yml
```

## Publish documentation

You can compile and place the html version of documentation on the `webpage-docs` branch of the codebase.
You can compile and place the html version of documentation on
the `webpage-docs` branch of the codebase.

```bash
export MKDOCS_ENABLE_PDF_EXPORT=1 #enable generation of pdf document
source script/docs.sh [version]
```

The command takes an optional version parameter. This version parameter is needed for making a release. Otherwise, the documentation gets published with the latest version tag. This command makes a new commit on `webpage-docs` branch. You need to push the branch to upstream.
The command takes an optional version parameter. This version parameter is needed
for making a release. Otherwise, the documentation gets published with
the latest version tag. This command makes a new commit on `webpage-docs` branch.
You need to push the branch to upstream.

```bash
git push webpage-docs
```

The github pages system serves the [project documentation](https://into-cps-association.github.io/DTaaS/) from this branch.
The github pages system serves the
[project documentation](https://into-cps-association.github.io/DTaaS/) from
this branch.

0 comments on commit 088669a

Please sign in to comment.