zsh:funcs:spellcheck: Fix indentation

I forgot to reindent part of the function after moving the

    if (( $+commands[shellcheck] ))

check into the function. Before it was wrapping the function definition.
This commit is contained in:
2022-05-22 14:51:25 +02:00
parent b61429a176
commit fd575d3784

View File

@@ -519,15 +519,15 @@ shellcheck() {
"Using www.shellcheck.net. You might want to install shellcheck.\n\n" "Using www.shellcheck.net. You might want to install shellcheck.\n\n"
local url json_parser arg local url json_parser arg
url='https://www.shellcheck.net/shellcheck.php' url='https://www.shellcheck.net/shellcheck.php'
json_parser="${${commands[jq]:-cat}:c}" json_parser="${${commands[jq]:-cat}:c}"
for arg; do for arg; do
if [[ ! -r $arg ]]; then if [[ ! -r $arg ]]; then
printf "%s\n" "$arg: File does not exist or is non-readable" >&2 printf "%s\n" "$arg: File does not exist or is non-readable" >&2
continue continue
fi fi
curl -sS "$url" -X POST --data-urlencode script@"$arg" \ curl -sS "$url" -X POST --data-urlencode script@"$arg" \
| "$json_parser" | "$json_parser"
done done
} }