Documentation site for [Project Name] built with MkDocs.
- Python 3.9+
- pip
# Install MkDocs and dependencies
pip install -r requirements.txt# Start the development server
mkdocs serve
# Open http://127.0.0.1:8000 in your browser# Build the static site
mkdocs build
# Output will be in the site/ directorydocs/
├── index.md # Home page
├── getting-started.md # Getting started guide
├── user-guide/ # User documentation
│ ├── installation.md
│ ├── configuration.md
│ └── usage.md
├── developer-guide/ # Developer documentation
│ ├── setup.md
│ ├── architecture.md
│ └── contributing.md
├── api/ # API reference
│ └── reference.md
└── faq.md # FAQ
- Create a new
.mdfile in thedocs/directory - Add it to
mkdocs.ymlin thenavsection - Write your content using Markdown
MkDocs supports standard Markdown plus extensions:
Code Blocks:
def hello():
print("Hello, World!")Admonitions:
!!! note
This is a note admonition.
!!! warning
This is a warning admonition.Tables:
| Header 1 | Header 2 |
|----------|----------|
| Cell 1 | Cell 2 |The theme is configured in mkdocs.yml:
theme:
name: material
palette:
primary: indigo
accent: indigoEdit the nav section in mkdocs.yml:
nav:
- Home: index.md
- Getting Started: getting-started.md
- User Guide:
- Installation: user-guide/installation.md
- Configuration: user-guide/configuration.mdAutomated deployment via GitHub Actions:
# .github/workflows/docs.yml
name: Deploy Docs
on:
push:
branches: [main]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.x
- run: pip install -r requirements.txt
- run: mkdocs gh-deploy --force# Deploy to GitHub Pages
mkdocs gh-deploy
# Deploy to custom domain
mkdocs build
# Upload site/ directory to your hostContributions to documentation are welcome!
- Fork this repository
- Create a branch for your changes
- Make your edits
- Test locally with
mkdocs serve - Submit a pull request
This documentation is licensed under the MIT License.
Built with ☕ by Coffee Code Philly