Skip to content

Commit a8ac476

Browse files
committed
chore(runformat): Ensure script can be executed from any location
This change updates the runformat script to set the working directory to the script's directory, ensuring consistent behavior regardless of the initial execution location.
1 parent a22781e commit a8ac476

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

runformat

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@
1111
# - you can put uncrustify in your PATH
1212
# - you can create an environment variable UNCRUSTIFY that has the full path of the binary
1313

14+
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
15+
cd "$SCRIPT_DIR"
16+
1417
UNCRUSTIFY_VERSION="0.72.0"
1518
UNCRUSTIFY="${UNCRUSTIFY-uncrustify}"
1619

0 commit comments

Comments
 (0)