mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 06:53:01 +00:00
stdenv: Make condition clearer
-z checks for a empty string -n checks for a not empty string It makes more sense to run the chmod if the string is not empty
This commit is contained in:
parent
1fb560746e
commit
9816ca55c2
@ -1594,7 +1594,7 @@ genericBuild() {
|
||||
|
||||
if [ "$curPhase" = unpackPhase ]; then
|
||||
# make sure we can cd into the directory
|
||||
[ -z "${sourceRoot}" ] || chmod +x "${sourceRoot}"
|
||||
[ -n "${sourceRoot:-}" ] && chmod +x "${sourceRoot}"
|
||||
|
||||
cd "${sourceRoot:-.}"
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user