verify: Fix line counting

This commit is contained in:
tschettervictor
2025-02-23 23:40:07 -07:00
committed by GitHub
parent 9a2270ce21
commit 613f19edad

View File

@@ -89,7 +89,7 @@ verify_template() {
## line count must match newline count
# shellcheck disable=SC2046
# shellcheck disable=SC3003
if [ $(wc -l "${_path}" | awk '{print $1}') -ne $(grep -c $'\n' "${_path}") ]; then
if [ $(wc -l "${_path}" | awk '{print $1}') -ne $(grep -c '\n' "${_path}") ]; then
info "[${_hook}]:"
error_notify "${BASTILLE_TEMPLATE}:${_hook} [failed]."
error_notify "Line numbers don't match line breaks."