From e47eaa32a3ca9152118b5365d3f8681c3e2d3135 Mon Sep 17 00:00:00 2001 From: Maciej Jur Date: Sat, 27 Jul 2024 14:03:17 +0200 Subject: [PATCH] nixos: clean up cache in home --- nixos/msi/configuration.nix | 3 ++- nixos/msi/modules/lean.nix | 8 ++++---- nixos/msi/modules/ocaml.nix | 6 +++++- nixos/msi/modules/rust.nix | 12 ++++++++++++ 4 files changed, 23 insertions(+), 6 deletions(-) create mode 100644 nixos/msi/modules/rust.nix diff --git a/nixos/msi/configuration.nix b/nixos/msi/configuration.nix index 4ede3d5..a883ef9 100644 --- a/nixos/msi/configuration.nix +++ b/nixos/msi/configuration.nix @@ -55,7 +55,8 @@ in i18n = { defaultLocale = "en_US.UTF-8"; inputMethod = { - enabled = "fcitx5"; + enable = true; + type = "fcitx5"; fcitx5 = { waylandFrontend = true; plasma6Support = true; diff --git a/nixos/msi/modules/lean.nix b/nixos/msi/modules/lean.nix index 1e6ff7b..dfb6437 100644 --- a/nixos/msi/modules/lean.nix +++ b/nixos/msi/modules/lean.nix @@ -1,11 +1,11 @@ { pkgs, config, ... }: { + home.sessionVariables = { + ELAN_HOME = "${config.xdg.cacheHome}/elan"; + }; + home.packages = with pkgs; [ elan ]; - - # home.sessionVariables = { - # ELAN_HOME = "${config.xdg.cacheHome}/elan"; - # }; } diff --git a/nixos/msi/modules/ocaml.nix b/nixos/msi/modules/ocaml.nix index fefa6bd..a997186 100644 --- a/nixos/msi/modules/ocaml.nix +++ b/nixos/msi/modules/ocaml.nix @@ -1,6 +1,10 @@ -{ pkgs, ... }: +{ pkgs, config, ... }: { + home.sessionVariables = { + OPAMROOT = "${config.xdg.cacheHome}/opam"; + }; + home.packages = with pkgs; [ ocaml ocamlformat diff --git a/nixos/msi/modules/rust.nix b/nixos/msi/modules/rust.nix new file mode 100644 index 0000000..2dc95db --- /dev/null +++ b/nixos/msi/modules/rust.nix @@ -0,0 +1,12 @@ +{ pkgs, config, ... }: + +{ + home.sessionVariables = { + CARGO_HOME = "${config.xdg.cacheHome}/cargo"; + RUSTUP_HOME = "${config.xdg.cacheHome}/rustup"; + }; + + home.packages = with pkgs; [ + rust-analyzer + ]; +}