mirror of
https://github.com/foo-dogsquared/nixos-config.git
synced 2025-04-19 00:19:11 +00:00
home-manager/programs/nushell: init extension module
This commit is contained in:
parent
c78f87edb4
commit
c744c2a2f8
@ -4,6 +4,7 @@
|
|||||||
./programs/pipewire.nix
|
./programs/pipewire.nix
|
||||||
./programs/pop-launcher.nix
|
./programs/pop-launcher.nix
|
||||||
./programs/borgmatic.nix
|
./programs/borgmatic.nix
|
||||||
|
./programs/nushell.nix
|
||||||
./programs/python.nix
|
./programs/python.nix
|
||||||
./services/archivebox.nix
|
./services/archivebox.nix
|
||||||
./services/borgbackup.nix
|
./services/borgbackup.nix
|
||||||
|
15
modules/home-manager/programs/nushell.nix
Normal file
15
modules/home-manager/programs/nushell.nix
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
# This is just an extended implementation of exporting Nushell session
|
||||||
|
# variables since the one from home-manager is only in POSIX sh script.
|
||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
cfg = config.programs.nushell;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
config.programs.nushell.extraEnv = let
|
||||||
|
exportSessionVariables = lib.mapAttrs (n: v:
|
||||||
|
"$env.${n} = ${v}") config.home.sessionVariables;
|
||||||
|
in lib.mkBefore ''
|
||||||
|
${exportSessionVariables}
|
||||||
|
'';
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user