mirror of
https://github.com/pbek/QOwnNotes.git
synced 2025-06-28 12:59:52 +00:00
10 lines
313 B
Bash
Executable file
10 lines
313 B
Bash
Executable file
#!/usr/bin/env bash
|
|
# pre-commit hook script
|
|
|
|
echo "Running pre-commit hook with treefmt"
|
|
|
|
# Run treefmt to format the code and check if there are any changes after formatting
|
|
if ! just fmt --fail-on-change; then
|
|
echo -e "\nCode may have been formatted. Please review the changes and commit again."
|
|
exit 1
|
|
fi
|