1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-12-24 02:39:48 +01:00

files: improve keyword for inheriting executable bit

This commit is contained in:
Robert Helgesson 2017-11-12 00:13:29 +01:00
parent 145aefc9d1
commit d7537777c3
No known key found for this signature in database
GPG key ID: C3DB11069E65DC86

View file

@ -225,7 +225,7 @@ in
install -m "$mode" "$source" "$target"
else
[[ -x $source ]] && isExecutable=1 || isExecutable=""
if [[ $executable == symlink || $isExecutable == $executable ]]; then
if [[ $executable == inherit || $isExecutable == $executable ]]; then
ln -s "$source" "$target"
else
cp "$source" "$target"
@ -242,7 +242,7 @@ in
insertFile "${v.source}" \
"${v.target}" \
"${if v.executable == null
then "symlink"
then "inherit"
else builtins.toString v.executable}" \
"${builtins.toString v.mode}" \
"${builtins.toString v.recursive}"