We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
wc -l
1 parent 0fc3804 commit b3d5d0cCopy full SHA for b3d5d0c
command-not-found.sh
@@ -17,7 +17,7 @@ command_not_found_handle () {
17
toplevel=nixpkgs # nixpkgs should always be available even in NixOS
18
cmd=$1
19
attrs=$(@out@/bin/nix-locate --minimal --no-group --type x --type s --whole-name --at-root "/bin/$cmd")
20
- len=$(echo -n "$attrs" | grep -c "^")
+ test "${attrs}" && len=$(echo "$attrs" | wc -l) || len=0
21
22
case $len in
23
0)
0 commit comments