mirror of
https://github.com/kuhyx/scripts.git
synced 2026-07-04 16:23:12 +02:00
17 lines
400 B
Bash
Executable File
17 lines
400 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set -euo pipefail
|
|
|
|
repo_root=$(git rev-parse --show-toplevel)
|
|
cd "$repo_root"
|
|
|
|
printf 'Running shell_check before committing...\n'
|
|
|
|
if ! scripts/meta/shell_check.sh --skip-install; then
|
|
printf '\nCommit aborted: shell_check reported issues.\n' >&2
|
|
printf 'Fix the lint problems and retry the commit.\n' >&2
|
|
exit 1
|
|
fi
|
|
|
|
printf 'shell_check passed. Proceeding with commit.\n'
|