nixos/guix: fix conditional linking of profiles

This commit is contained in:
Gabriel Arazas 2023-12-20 22:04:01 +08:00
parent a73ae4bf9f
commit b7ece537bb
No known key found for this signature in database
GPG key ID: ADE0C41DAB221FCC

View file

@ -274,7 +274,7 @@ in
linkProfile = profile: location: let
userProfile = guixProfile profile;
in ''
[ -d "${userProfile}" ] && [ -L "${location}" ] || ln -sf "${userProfile}" "${location}"
[ -d "${userProfile}" ] && ln -sfn "${userProfile}" "${location}"
'';
linkProfileToPath = acc: profile: location: let
in acc + (linkProfile profile location);