diff --git a/cells/repo/docs.nix b/cells/repo/docs.nix new file mode 100644 index 0000000..ab349eb --- /dev/null +++ b/cells/repo/docs.nix @@ -0,0 +1,45 @@ +{inputs, ...}: let + inherit (inputs) doclib; +in + (doclib.mkDocs { + docs."default" = { + base = "${inputs.self}"; + path = "${inputs.self}/docs"; + material = { + enable = true; + colors = { + primary = "deep purple"; + accent = "purple"; + }; + umami = { + enable = true; + src = "https://analytics.tf/umami"; + siteId = "219a2bbe-e421-420c-a25c-e168b16d8b61"; + domains = ["rensa.projects.tf"]; + }; + }; + config = { + site_name = "Rensa Core"; + repo_name = "rensa-nix/core"; + repo_url = "https://gitlab.com/rensa-nix/core"; + theme = { + logo = "images/logo.png"; + icon.repo = "simple/gitlab"; + favicon = "images/favicon.png"; + }; + nav = [ + {"Introduction" = "index.md";} + ]; + markdown_extensions = [ + { + "pymdownx.highlight".pygments_lang_class = true; + } + "pymdownx.inlinehilite" + "pymdownx.snippets" + "pymdownx.superfences" + "pymdownx.escapeall" + "fenced_code" + ]; + }; + }; + }).packages diff --git a/cells/repo/flake.lock b/cells/repo/flake.lock index 3917fbc..2ea763a 100644 --- a/cells/repo/flake.lock +++ b/cells/repo/flake.lock @@ -3,11 +3,11 @@ "devshell": { "locked": { "dir": "lib", - "lastModified": 1753958239, - "narHash": "sha256-J0B5rfQAza9UKSqnKINn++AsrMWxG3/oTqVUt3QRlWk=", + "lastModified": 1755673398, + "narHash": "sha256-51MmR+Eo1+bKDd/Ss77wwTqi4yAR2xgmyCSEbKWSpj0=", "owner": "rensa-nix", "repo": "devshell", - "rev": "fbacfc149b59acf68efa97951418a9a7a7022707", + "rev": "e76bef387e8a4574f9b6d37b1a424e706491af08", "type": "gitlab" }, "original": { @@ -17,9 +17,27 @@ "type": "gitlab" } }, + "nixmkdocs": { + "locked": { + "dir": "lib", + "lastModified": 1755785622, + "narHash": "sha256-xBb9PCkszmrWSEqUiPC7oBJABm1thF572S5QHtloZ+M=", + "owner": "TECHNOFAB", + "repo": "nixmkdocs", + "rev": "61da605a9bff12f66c4b743f43aea59ca200f533", + "type": "gitlab" + }, + "original": { + "dir": "lib", + "owner": "TECHNOFAB", + "repo": "nixmkdocs", + "type": "gitlab" + } + }, "root": { "inputs": { - "devshell": "devshell" + "devshell": "devshell", + "nixmkdocs": "nixmkdocs" } } }, diff --git a/cells/repo/flake.nix b/cells/repo/flake.nix index a958cee..6daf61c 100644 --- a/cells/repo/flake.nix +++ b/cells/repo/flake.nix @@ -1,11 +1,13 @@ { inputs = { devshell.url = "gitlab:rensa-nix/devshell?dir=lib"; + nixmkdocs.url = "gitlab:TECHNOFAB/nixmkdocs?dir=lib"; }; outputs = i: i // { dslib = i.devshell.lib {inherit (i.parent) pkgs;}; + doclib = i.nixmkdocs.lib {inherit (i.parent) pkgs;}; }; } diff --git a/docs/index.md b/docs/index.md new file mode 100644 index 0000000..fc63877 --- /dev/null +++ b/docs/index.md @@ -0,0 +1 @@ +# Rensa Core diff --git a/flake.nix b/flake.nix index 1c28da0..a99e209 100644 --- a/flake.nix +++ b/flake.nix @@ -20,6 +20,9 @@ cellBlocks = with rensa.blocks; [ (simple "test") (simple "devShells") + (simple "docs") ]; - } {}; + } { + packages = rensa.select inputs.self ["repo" "docs"]; + }; }