Files
nixos-setup/modules/skyg-utils.nix
T
2025-07-28 09:57:20 -04:00

17 lines
337 B
Nix

{
makeHyperlinkScriptToConfigs =
{ filePath
, configSource
}:
let
homePath = "$HOME/.config/${filePath}";
sourcePath = "${configSource}/${filePath}";
in
''
rm -f "${homePath}"
if [[ ! -h "$HOME/.config/${filePath}" ]]; then
ln -s "${sourcePath}" "${homePath}"
fi
'';
}