nixos-config/config/env.nix

13 lines
309 B
Nix

{ config, pkgs, lib, ... }: {
config.environment.extraInit =
let
systemdBin = lib.getBin config.systemd.package;
in
''
set -a
. /dev/fd/0 <<EOF
$(${systemdBin}/lib/systemd/user-environment-generators/30-systemd-environment-d-generator)
EOF
set +a
'';
}