nushell: expose config dir location as option
Some checks failed
/ triage (push) Has been cancelled
GitHub Pages / publish (ubuntu-latest) (push) Has been cancelled

This commit is contained in:
Joaquín Triñanes 2025-04-06 13:19:58 +02:00 committed by Austin Horstman
parent b47ea12ff4
commit 363007f129
3 changed files with 56 additions and 11 deletions

View file

@ -0,0 +1,30 @@
{ config, ... }:
{
programs.nushell = {
enable = true;
configDir = "${config.xdg.configHome}/nushell-alt-path";
extraConfig = ''
# extra config
'';
extraEnv = ''
# extra env
'';
extraLogin = ''
# extra login
'';
};
nmt.script = ''
assertDirectoryExists home-files/.config/nushell-alt-path
assertFileExists home-files/.config/nushell-alt-path/config.nu
assertFileRegex home-files/.config/nushell-alt-path/config.nu '# extra config'
assertFileExists home-files/.config/nushell-alt-path/env.nu
assertFileRegex home-files/.config/nushell-alt-path/env.nu "# extra env"
assertFileExists home-files/.config/nushell-alt-path/login.nu
assertFileRegex home-files/.config/nushell-alt-path/login.nu '# extra login'
'';
}

View file

@ -1 +1,4 @@
{ nushell-example-settings = ./example-settings.nix; }
{
nushell-example-settings = ./example-settings.nix;
nushell-config-dir = ./config-dir.nix;
}