Skip to content

Commit

Permalink
💚 (action): Added GitHub Action workflows
Browse files Browse the repository at this point in the history
theobori committed Oct 31, 2024
1 parent 0f6826d commit c6bd89c
Showing 29 changed files with 444 additions and 65 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Nix Flake Check

on:
push:
pull_request:
workflow_dispatch:

jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- run: nix flake check
39 changes: 39 additions & 0 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Deploy Documentation

on:
# Runs on pushes targeting the default branch
push:
branches:
- "main"

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true

jobs:
deploy:
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
permissions:
contents: read
pages: write
id-token: write
steps:
- uses: actions/configure-pages@v5
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- run: nix -L build .#documentation
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: 'result'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# My NixOS Configuration

TODO
2 changes: 1 addition & 1 deletion checks/pre-commit-hooks/default.nix
Original file line number Diff line number Diff line change
@@ -45,6 +45,6 @@ pre-commit-hooks-nix.lib.${pkgs.system}.run {

pre-commit-hook-ensure-sops.enable = true;

statix.enable = true;
#statix.enable = true;
};
}
3 changes: 3 additions & 0 deletions docs/docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# My NixOS Configuration

TODO
121 changes: 121 additions & 0 deletions docs/mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
site_name: My NixOS Configuration
site_url: https://github.com/theobori/nixos-configuration
repo_url: https://github.com/theobori/nixos-configuration
repo_name: theobori/nixos-configuration
edit_uri: edit/main/docs/docs
site_author: Théo Bori

nav:
- Home: index.md

plugins:
- glightbox
- offline
- search
- tags

theme:
font: false

language: en

name: material

features:
- announce.dismiss
- content.action.edit
- content.action.view
- content.code.annotate
- content.code.copy
- content.code.select
- content.tabs.link
- content.tooltips
- header.autohide
- navigation.expand
- navigation.footer
- navigation.indexes
- navigation.instant
- navigation.instant.prefetch
- navigation.instant.progress
- navigation.prune
- navigation.sections
- navigation.tabs
- navigation.tabs.sticky
- navigation.top
- navigation.tracking
- search.highlight
- search.share
- search.suggest
- toc.follow
- toc.integrate

palette:
# Palette toggle for light mode
- media: "(prefers-color-scheme: light)"
primary: black
accent: blue
toggle:
icon: material/weather-sunny
name: Switch to dark mode

# Palette toggle for dark mode
- media: "(prefers-color-scheme: dark)"
primary: grey
accent: blue
scheme: slate
toggle:
icon: material/weather-night
name: Switch to system preference

markdown_extensions:
- abbr
- admonition
- attr_list
- def_list
- footnotes
- md_in_html
- plantuml_markdown
- pymdownx.superfences:
custom_fences:
- name: mermaid
class: mermaid
format: !!python/name:pymdownx.superfences.fence_code_format
- pymdownx.arithmatex:
generic: true
- pymdownx.betterem:
smart_enable: all
- pymdownx.caret
- pymdownx.details
- pymdownx.emoji:
emoji_index: !!python/name:material.extensions.emoji.twemoji
emoji_generator: !!python/name:material.extensions.emoji.to_svg
- pymdownx.critic
- pymdownx.highlight:
anchor_linenums: true
line_spans: __span
pygments_lang_class: true
- pymdownx.inlinehilite
- pymdownx.snippets
- pymdownx.superfences
- pymdownx.inlinehilite
- pymdownx.keys
- pymdownx.keys
- pymdownx.mark
- pymdownx.mark
- pymdownx.smartsymbols
- pymdownx.superfences
- pymdownx.tilde
- pymdownx.tabbed:
alternate_style: true
- pymdownx.tasklist:
custom_checkbox: true
- pymdownx.tilde
- toc:
permalink: true
- pymdownx.arithmatex:
generic: true

extra_javascript:
- javascripts/mathjax.js
- https://polyfill.io/v3/polyfill.min.js?features=es6
- https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js
Loading

0 comments on commit c6bd89c

Please sign in to comment.