Skip to content

Commit

Permalink
Init docs
Browse files Browse the repository at this point in the history
  • Loading branch information
bleudev committed Jun 30, 2024
1 parent 1e4725a commit 0e18458
Show file tree
Hide file tree
Showing 4 changed files with 116 additions and 1 deletion.
29 changes: 29 additions & 0 deletions .github/workflows/deploy_mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: deploy_mkdocs
on:
push:
branches:
- master
- main
permissions:
contents: write
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Configure Git Credentials
run: |
git config user.name github-actions[bot]
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
- uses: actions/setup-python@v5
with:
python-version: 3.x
- run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
- uses: actions/cache@v4
with:
key: mkdocs-material-${{ env.cache_id }}
path: .cache
restore-keys: |
mkdocs-material-
- run: pip install mkdocs-material
- run: mkdocs gh-deploy --force
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -159,4 +159,4 @@ cython_debug/
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/
.idea/
17 changes: 17 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Welcome to MkDocs

For full documentation visit [mkdocs.org](https://www.mkdocs.org).

## Commands

* `mkdocs new [dir-name]` - Create a new project.
* `mkdocs serve` - Start the live-reloading docs server.
* `mkdocs build` - Build the documentation site.
* `mkdocs -h` - Print help message and exit.

## Project layout

mkdocs.yml # The configuration file.
docs/
index.md # The documentation homepage.
... # Other markdown pages, images and other files.
69 changes: 69 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
site_name: Useful python (ufpy)
site_url: https://honey-team.github.io/ufpy/

repo_url: https://github.com/honey-team/ufpy
repo_name: honey-team/ufpy
edit_uri: edit/main/docs/

theme:
name: material
features:
- content.action.edit
- content.code.copy
- content.tooltips
- header.autohide
- search.suggest
icon:
repo: fontawesome/brands/github
edit: material/pencil
tag:
typec: material/code-braces
info: octicons/info-16
useful: simple/python
palette:
# Palette toggle for light mode
- media: "(prefers-color-scheme: light)"
scheme: default
toggle:
icon: material/brightness-7
name: Switch to dark mode

- media: "(prefers-color-scheme: dark)"
scheme: slate
toggle:
icon: material/brightness-4
name: Switch to system preference

extra:
tags:
type check: typec
information: info
useful class: useful
useful feature: useful

plugins:
- search
- tags

markdown_extensions:
- abbr
- attr_list
- md_in_html
- pymdownx.highlight:
anchor_linenums: true
line_spans: __span
use_pygments: true
pygments_lang_class: true
- pymdownx.details
- pymdownx.inlinehilite
- pymdownx.snippets
- pymdownx.superfences
- pymdownx.keys
- pymdownx.tabbed:
alternate_style: true
- markdown_include.include:
base_path: .
- admonition
- pymdownx.emoji:
emoji_index: !!python/name:material.extensions.emoji.twemoji
emoji_generator: !!python/name:material.extensions.emoji.to_svg

0 comments on commit 0e18458

Please sign in to comment.