Skip to content

Commit

Permalink
doc: update on mike tool (intel-retail#489)
Browse files Browse the repository at this point in the history
Signed-off-by: Neethu Elizabeth Simon <[email protected]>
  • Loading branch information
NeethuES-intel authored Feb 7, 2024
1 parent f03289e commit b971e6e
Showing 1 changed file with 19 additions and 14 deletions.
33 changes: 19 additions & 14 deletions docs_src/dev-tools/documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,53 +8,58 @@

## Mike Tool Usage

1. Make sure [page-build-deployment](https://github.com/intel-retail/automated-self-checkout/actions/workflows/pages/pages-build-deployment) and [Update GH Pages](https://github.com/intel-retail/automated-self-checkout/actions/workflows/gh-pages.yml) are working
1. To push the version to github using mike tool, ensure that code is checked out locally using HTTP.

!!! warning
Mike tool doesn't work if code is checked out locally with SSH

2. Make sure [page-build-deployment](https://github.com/intel-retail/automated-self-checkout/actions/workflows/pages/pages-build-deployment) and [Update GH Pages](https://github.com/intel-retail/automated-self-checkout/actions/workflows/gh-pages.yml) are working

!!! note
Mike tool works with Github Pages(**gh-pages**), versioning changes will appear only after they are deployed to **gh-pages** via github actions. To run them locally, use the following command to view documentation at *http://localhost:8000/*
```bash
mike serve
```

2. Install mike tool on local development environment
3. Install mike tool on local development environment

```bash
pip install mike
```

3. Make the documentation changes and check in the code.
4. Make the documentation changes and check in the code.

4. Alias for documentation default version is set as **latest**. If required, this can be changed -
5. Alias for documentation default version is set as **latest**. If required, this can be changed -

```bash
```
mike set-default --push latest
```

4. Publish a new version of project documentation by choosing a version identifier and update the alias set as the default version with -
6. Publish a new version of project documentation by choosing a version identifier and update the alias set as the default version with -

```bash
```
mike deploy --push --update-aliases 0.1 latest
```

5. Every version will be deployed as a subdirectory of **site_url** set in mkdocs.yaml. Example the documentation will be published to URLs such as:
7. Every version will be deployed as a subdirectory of **site_url** set in mkdocs.yaml. Example the documentation will be published to URLs such as:

```bash
```
https://intel-retail.github.io/automated-self-checkout/0.1/
https://intel-retail.github.io/automated-self-checkout/0.2/
```

6. After PR is merged into the main branch, github actions will deploy the **gh-pages** and version dropdown on the documentation page will populate the new version as shown below
8. After PR is merged into the main branch, github actions will deploy the **gh-pages** and version dropdown on the documentation page will populate the new version as shown below

![Documentation Version Dropdown](../images/documentation-version-dropdown.png)

7. To delete versions, use the following commands -
9. To delete versions, use the following commands -

```bash
```
mike delete [version identifier]...
```

8. To list versions, use the following commands -
10. To list versions, use the following commands -

```bash
```
mike list
```

0 comments on commit b971e6e

Please sign in to comment.