diff options
| author | Alexander Kassouni <alex@kassouni.net> | 2026-09-29 23:29:28 -0700 |
|---|---|---|
| committer | Alexander Kassouni <alex@kassouni.net> | 2026-09-29 23:29:28 -0700 |
| commit | 52cdeaf4cc9da9d32926821c78fd331bc8d2f14a (patch) | |
| tree | 1b57b1c4d7c4e70202d9f07bab8a8e1a477078b9 /git/theme.nix | |
| parent | a570da443586fa3b3490b5add88ea5932456a5b3 (diff) | |
restructure for cgit css
Diffstat (limited to 'git/theme.nix')
| -rw-r--r-- | git/theme.nix | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/git/theme.nix b/git/theme.nix new file mode 100644 index 0000000..4d4a395 --- /dev/null +++ b/git/theme.nix @@ -0,0 +1,20 @@ +{ pkgs }: + +# The extra stylesheet for cgit, served next to cgit's stock cgit.css, plus the +# webfont it references. Fonts ship here rather than being pulled from +# kassouni.net so they stay same-origin and need no CORS headers. +pkgs.runCommand "cgit-theme" + { + nativeBuildInputs = [ pkgs.dart-sass ]; + + meta = { + description = "cgit stylesheet matching kassouni.net"; + license = pkgs.lib.licenses.mit; + platforms = pkgs.lib.platforms.all; + }; + } + '' + mkdir -p $out + sass --no-source-map --load-path=${../style} ${./cgit.scss} $out/theme.css + cp -r ${../site/static/fonts} $out/fonts + '' |