build: split nix dev shell into default and presets

Problem: the single dev shell mixed dev tooling (linters, test runner)
with preset compiler tools, causing heavy rebuilds (e.g. Chromium for
`mermaid-cli`) for contributors who only need the dev tools.

Solution: extract dev tooling into a shared `devTools` list and expose
two shells — `default` for development and `presets` for running all
built-in preset compilers (`typst`, `texliveMedium`, `tectonic`,
`pandoc`, `asciidoctor`, `quarto`, `plantuml`, `mermaid-cli`).
This commit is contained in:
Barrett Ruth 2026-03-05 10:55:03 -05:00
parent 23aa8acc55
commit 6f090fdcf3
No known key found for this signature in database
GPG key ID: A6C96C9349D2FC81

View file

@ -19,9 +19,9 @@
{
formatter = forEachSystem (pkgs: pkgs.nixfmt-tree);
devShells = forEachSystem (pkgs: {
default = pkgs.mkShell {
packages = [
devShells = forEachSystem (pkgs:
let
devTools = [
(pkgs.luajit.withPackages (
ps: with ps; [
busted
@ -32,9 +32,24 @@
pkgs.stylua
pkgs.selene
pkgs.lua-language-server
pkgs.plantuml
];
};
});
in
{
default = pkgs.mkShell {
packages = devTools;
};
presets = pkgs.mkShell {
packages = devTools ++ [
pkgs.typst
pkgs.texliveMedium
pkgs.tectonic
pkgs.pandoc
pkgs.asciidoctor
pkgs.quarto
pkgs.plantuml
pkgs.mermaid-cli
];
};
});
};
}