This tool is based on mkdocs-material and inspired by HPCMonitoring/docs.
- Support Commit Convention Message when working in groups with commitlint and husky.
- Support Docker Compose.
- Follow git-workflow with 2 main branches:
main
andstaging
, with specific documents attached at here. - Auto-generate web document when creating pull request to branch
staging
and auto-release new version when pushing to branchmain
.
-
Clone the repository:
git clone [email protected]:ngyngcphu/mkdocs-tool.git
or you haven't set up SSH on github:
git clone https://github.com/ngyngcphu/mkdocs-tool.git
-
Setup commit convention message (optional):
yarn install
-
Run tool:
pip install mkdocs-material mkdocs serve --dev-addr=0.0.0.0:8000
or if you have
docker compose
, only run:docker compose up -d
Point your browser to localhost:8000
to see result.
You have to create a new branch staging
and follow git-workflow in here.
Note: Branch gh-pages
is only created when you create a pull request to staging
.
You can use feature Use this template on github. Then, click Include all branches
.
- In
Settings->Pages->Branch
, select branchgh-pages
and folder/root
to enable github page. - In
Settings->Actions->General->Workflow permissions
, select Allow Github Action to create and approve pull requests to enable permission.