This document explains how to set up and deploy MkDocs documentation to GitHub Pages.
✅ MkDocs Configuration (mkdocs.yml)
- Material theme with dark/light mode
- Navigation structure organized
- Search functionality enabled
- Git revision dates plugin
✅ GitHub Actions Workflow (.github/workflows/docs.yml)
- Automatic deployment on push to main
- Builds documentation site
- Deploys to GitHub Pages
✅ Documentation Structure
- Organized in
docs/directory - Organized by category (getting-started, user-guide, developer-guide, etc.)
✅ Dependencies (requirements-docs.txt)
- MkDocs and Material theme
- Required plugins
- Go to your repository on GitHub
- Navigate to Settings → Pages
- Under Source, select GitHub Actions
- Save the settings
# Install dependencies
pip install -r requirements-docs.txt
# Serve locally
mkdocs serve
# Open http://127.0.0.1:8000 in your browserThe documentation will automatically deploy when you:
- Push changes to the
mainbranch - The GitHub Actions workflow will:
- Build the documentation
- Deploy to GitHub Pages
- Make it available at
https://rennerdo30.github.io/toss-share/
If you want to deploy manually:
# Build the site
mkdocs build
# The site will be in the `site/` directory
# You can then deploy it manually to GitHub Pages- Edit files in the
docs/directory - Update
mkdocs.ymlif you need to change navigation - Commit and push to
main - GitHub Actions will automatically rebuild and deploy
docs/
├── index.md # Homepage
├── getting-started/ # Getting started guides
│ ├── quick-start.md
│ ├── installation.md
│ └── development-setup.md
├── user-guide/ # User documentation
│ ├── overview.md
│ ├── pairing.md
│ └── using-toss.md
├── developer-guide/ # Developer documentation
│ ├── architecture.md
│ ├── api-reference.md
│ ├── platform-support.md
│ └── testing.md
├── platform-specific/ # Platform guides
│ ├── overview.md
│ ├── macos.md
│ ├── windows.md
│ ├── linux.md
│ ├── ios.md
│ ├── android.md
│ └── ios-android.md
├── contributing/ # Contributing
│ ├── contributing.md
│ ├── code-of-conduct.md
│ └── security.md
└── project-status/ # Project status
├── status.md
├── implementation-summary.md
├── todo.md
└── changelog.md
Edit mkdocs.yml to customize the theme:
theme:
name: material
palette:
- scheme: default
primary: indigo # Change color
accent: indigoEdit the nav: section in mkdocs.yml to reorganize navigation.
Add plugins in mkdocs.yml:
plugins:
- search
- git-revision-date-localized-plugin
- your-pluginCheck the GitHub Actions logs for errors. Common issues:
- Missing dependencies in
requirements-docs.txt - Syntax errors in
mkdocs.yml - Missing markdown files referenced in navigation
- Check GitHub Actions workflow status
- Verify GitHub Pages is enabled
- Wait a few minutes for deployment to complete
# Clean and rebuild
rm -rf site/
mkdocs build