refactor(nixos): inline module enable conditions
This commit was merged in pull request #134.
This commit is contained in:
@@ -6,7 +6,6 @@
|
||||
}:
|
||||
# Rust tools for the primary user's shell environment.
|
||||
let
|
||||
cfg = config.modules.shell.rust; # NOLINT(let_order)
|
||||
toolchain = pkgs.symlinkJoin {
|
||||
name = "rust-toolchain";
|
||||
paths = with pkgs; [
|
||||
@@ -23,7 +22,7 @@ in
|
||||
options.modules.shell.rust.enable =
|
||||
lib.mkEnableOption "Rust tools for the primary user's shell environment";
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
config = lib.mkIf config.modules.shell.rust.enable {
|
||||
home-manager.users.${user} = {
|
||||
home.sessionVariables.RUST_TOOLCHAIN_ROOT = "${toolchain}";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user