From 248b6269aa1642dad1f02c413f0e909c3a6c0c8c Mon Sep 17 00:00:00 2001 From: Daylin Morgan Date: Mon, 6 Jan 2025 15:14:23 -0600 Subject: [PATCH] add language module for typst --- hosts/othalan/default.nix | 2 +- hosts/othalan/pkgs.nix | 1 - modules/languages/typst.nix | 18 ++++++++++++++++++ 3 files changed, 19 insertions(+), 2 deletions(-) create mode 100644 modules/languages/typst.nix diff --git a/hosts/othalan/default.nix b/hosts/othalan/default.nix index d66928c..a856010 100644 --- a/hosts/othalan/default.nix +++ b/hosts/othalan/default.nix @@ -12,7 +12,7 @@ nix-ld = enabled // { overkill = enabled; }; - languages = "misc|nim|node|nushell|python|tex" |> listify; + languages = "misc|nim|node|nushell|python|tex|typst" |> listify; } // ( '' diff --git a/hosts/othalan/pkgs.nix b/hosts/othalan/pkgs.nix index 42c7351..34da100 100644 --- a/hosts/othalan/pkgs.nix +++ b/hosts/othalan/pkgs.nix @@ -18,7 +18,6 @@ charm-freeze quarto - typst calibre ]); diff --git a/modules/languages/typst.nix b/modules/languages/typst.nix new file mode 100644 index 0000000..82186d2 --- /dev/null +++ b/modules/languages/typst.nix @@ -0,0 +1,18 @@ +{ + config, + lib, + pkgs, + ... +}: +let + inherit (lib) mkIfIn; + cfg = config.oizys.languages; +in +{ + config = mkIfIn "typst" cfg { + environment.systemPackages = with pkgs; [ + typst + tinymist + ]; + }; +}