Restore basedir format.sh behavior
Summary: Ensure that `format.sh` can be run from anywhere with the same results. Reviewed By: emilsjolander Differential Revision: D4494367 fbshipit-source-id: cbd2cc36476a0a54a77a732cbe1b79388f7e0c46
This commit is contained in:
committed by
Facebook Github Bot
parent
326ae15532
commit
bd5d8a77c9
@@ -1,6 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
FILES=$(find . \( -path ./buck-out -o -path ./lib \) -prune -o \
|
BASEDIR="$(dirname "$0")"
|
||||||
|
FILES=$(find "$BASEDIR" \( -path "$BASEDIR/buck-out" -o -path "$BASEDIR/lib" \) -prune -o \
|
||||||
\( -name \*.h -o -name \*.c -o -name \*.cpp \) -print)
|
\( -name \*.h -o -name \*.c -o -name \*.cpp \) -print)
|
||||||
|
|
||||||
for f in $FILES "$@"; do
|
for f in $FILES "$@"; do
|
||||||
|
Reference in New Issue
Block a user