Skip to content

Added mkdocs workflow #48

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 16, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 45 additions & 0 deletions .github/workflows/validate-docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: validate-docs

on:
pull_request:
push:

jobs:
validate:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2

- name: Install Taskfile
uses: arduino/setup-task@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
version: 3.x

- name: Setup Go
uses: actions/setup-go@v2

- name: Setup Python
uses: actions/setup-python@v1
with:
python-version: "3.8"
architecture: "x64"

- name: Cache dependencies
uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements_docs.txt') }}
restore-keys: |
${{ runner.os }}-pip-

- name: Install Python dependencies
run: |
python3 -m pip install --upgrade pip
python3 -m pip install -r ./requirements_docs.txt

- name: Build docs website
# Ensure the docs build is sane, these docs won't be published
run: task docs:build
5 changes: 5 additions & 0 deletions Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@ tasks:
cmds:
- npx {{ .PRETTIER }} --write "**/*.md"

docs:build:
desc: Build documentation website contents
cmds:
- mkdocs build -s

build:
desc: Build the project
cmds:
Expand Down
1 change: 1 addition & 0 deletions docs/README.md
Binary file added docs/img/icon_mac_light.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
59 changes: 59 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# Project information
site_name: Arduino Firmware Uploader
site_description: A firmware uploader/updater for Arduino Boards.
site_url: https://arduino.github.io/FirmwareUploader/

# Repository
repo_name: arduino/FirmwareUploader
repo_url: https://github.com/arduino/FirmwareUploader
edit_uri: ""

# Copyright
copyright: Copyright 2021 ARDUINO SA (http://www.arduino.cc/)

# Theme
theme:
name: material
logo: img/icon_mac_light.png
palette:
primary: teal
accent: orange

# Extensions
markdown_extensions:
- markdown.extensions.admonition
- markdown.extensions.codehilite:
guess_lang: false
- markdown.extensions.def_list
- markdown.extensions.footnotes
- markdown.extensions.meta
- markdown.extensions.toc:
permalink: true
- pymdownx.arithmatex
- pymdownx.betterem:
smart_enable: all
- pymdownx.caret
- pymdownx.critic
- pymdownx.details
- pymdownx.emoji:
emoji_index: !!python/name:pymdownx.emoji.twemoji
emoji_generator: !!python/name:pymdownx.emoji.to_svg
- pymdownx.inlinehilite
- pymdownx.keys
- pymdownx.magiclink:
repo_url_shorthand: true
user: arduino
repo: FirmwareUploader
- pymdownx.mark
- pymdownx.smartsymbols
- pymdownx.superfences
- pymdownx.tasklist:
custom_checkbox: true
- pymdownx.tilde
- mdx_truly_sane_lists:
nested_indent: 2
truly_sane: true

# Navigation
nav:
- Documentation Home: README.md
6 changes: 6 additions & 0 deletions requirements_docs.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
mkdocs<1.2
mkdocs-material<5
mike==0.5.1
gitpython
click<7.2
mdx_truly_sane_lists==1.2