Skip to content

Commit 68ca474

Browse files
committed
Clean up pre-commit.sh
1 parent f53d436 commit 68ca474

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/etc/pre-commit.sh

+4-5
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
1-
#!/bin/env bash
1+
#!/usr/bin/env bash
22
#
33
# Call `tidy --bless` before each commit
44
# Copy this scripts to .git/hooks to activate,
55
# and remove it from .git/hooks to deactivate.
66
#
7-
# For help running bash scripts on Windows,
8-
# see https://stackoverflow.com/a/6413405/6894799
9-
#
107

118
set -Eeuo pipefail
129

@@ -17,6 +14,8 @@ if [[ "$OSTYPE" == "msys" || "$OSTYPE" == "win32" ]]; then
1714
COMMAND="python $COMMAND"
1815
fi
1916

20-
echo "Running pre-commit script $COMMAND";
17+
echo "Running pre-commit script '$COMMAND'";
18+
19+
cd "$ROOT_DIR"
2120

2221
$COMMAND;

0 commit comments

Comments
 (0)