make shellcheck happy

This commit is contained in:
Jörg Thalheim 2021-09-12 06:29:45 +02:00
parent ceb91896cd
commit 77418af186

View file

@ -98,7 +98,7 @@ _nix_argsum_suffix() {
# degrate gracefully both tools are not present # degrate gracefully both tools are not present
return return
fi fi
read checksum _ <<< "$out" read -r checksum _ <<< "$out"
echo "-$checksum" echo "-$checksum"
fi fi
} }
@ -109,9 +109,9 @@ use_flake() {
watch_file "$flake_dir/"flake.nix watch_file "$flake_dir/"flake.nix
watch_file "$flake_dir/"flake.lock watch_file "$flake_dir/"flake.lock
local layout_dir local layout_dir profile
layout_dir=$(direnv_layout_dir) layout_dir=$(direnv_layout_dir)
local profile="${layout_dir}/flake-profile$(_nix_argsum_suffix "$flake_expr")" profile="${layout_dir}/flake-profile$(_nix_argsum_suffix "$flake_expr")"
local flake_inputs="${layout_dir}/flake-inputs/" local flake_inputs="${layout_dir}/flake-inputs/"
local profile_rc="${profile}.rc" local profile_rc="${profile}.rc"
@ -226,7 +226,8 @@ use_nix() {
version="${version_prefix}-${path:11:16}" version="${version_prefix}-${path:11:16}"
fi fi
local cache="${layout_dir}/cache-${version:-unknown}$(_nix_argsum_suffix "$*")" local cache
cache="${layout_dir}/cache-${version:-unknown}$(_nix_argsum_suffix "$*")"
local update_drv=0 local update_drv=0
if [[ ! -e "$cache" if [[ ! -e "$cache"