treewide: add 'shellcheck shell' directives

I used 'bash' for zsh files, since that's the closest and `shell=zsh` is
not supported [1].

[1]: https://github.com/koalaman/shellcheck/issues/809
This commit is contained in:
Bruno BELANYI 2023-08-31 10:41:17 +00:00
parent 13769429f6
commit 861136c475
4 changed files with 6 additions and 0 deletions

View file

@ -1,5 +1,6 @@
#!/usr/bin/env nix-shell #!/usr/bin/env nix-shell
#! nix-shell -i bash -p bitwarden-cli git gnupg jq nix #! nix-shell -i bash -p bitwarden-cli git gnupg jq nix
# shellcheck shell=bash
# Command failure is script failure # Command failure is script failure
set -e set -e

View file

@ -1,3 +1,5 @@
# shellcheck shell=bash
# Style the completion a bit # Style the completion a bit
zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS} zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS}
# Show a prompt on selection # Show a prompt on selection

View file

@ -1,3 +1,4 @@
# shellcheck shell=bash
# shellcheck disable=2154 # shellcheck disable=2154
# Fix Ctrl+u killing from the cursor instead of the whole line # Fix Ctrl+u killing from the cursor instead of the whole line

View file

@ -1,3 +1,5 @@
# shellcheck shell=bash
# Show an error when a globbing expansion doesn't find any match # Show an error when a globbing expansion doesn't find any match
setopt nomatch setopt nomatch
# List on ambiguous completion and Insert first match immediately # List on ambiguous completion and Insert first match immediately