mirror of
https://github.com/NixOS/nix.git
synced 2025-11-09 12:06:01 +01:00
shellcheck fix: tests/functional/path-from-hash-part.sh
This commit is contained in:
parent
32cbf5f55a
commit
112c9d8f54
2 changed files with 3 additions and 4 deletions
|
|
@ -106,7 +106,6 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
excludes = [
|
excludes = [
|
||||||
# We haven't linted these files yet
|
# We haven't linted these files yet
|
||||||
''^tests/functional/path-from-hash-part\.sh$''
|
|
||||||
''^tests/functional/path-info\.sh$''
|
''^tests/functional/path-info\.sh$''
|
||||||
''^tests/functional/placeholders\.sh$''
|
''^tests/functional/placeholders\.sh$''
|
||||||
''^tests/functional/post-hook\.sh$''
|
''^tests/functional/post-hook\.sh$''
|
||||||
|
|
|
||||||
|
|
@ -4,9 +4,9 @@ source common.sh
|
||||||
|
|
||||||
path=$(nix build --no-link --print-out-paths -f simple.nix)
|
path=$(nix build --no-link --print-out-paths -f simple.nix)
|
||||||
|
|
||||||
hash_part=$(basename $path)
|
hash_part=$(basename "$path")
|
||||||
hash_part=${hash_part:0:32}
|
hash_part=${hash_part:0:32}
|
||||||
|
|
||||||
path2=$(nix store path-from-hash-part $hash_part)
|
path2=$(nix store path-from-hash-part "$hash_part")
|
||||||
|
|
||||||
[[ $path = $path2 ]]
|
[[ $path = "$path2" ]]
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue