File tree Expand file tree Collapse file tree 1 file changed +17
-6
lines changed Expand file tree Collapse file tree 1 file changed +17
-6
lines changed Original file line number Diff line number Diff line change @@ -20,18 +20,29 @@ set -o pipefail
2020SCRIPT_DIR=" $( dirname " ${BASH_SOURCE[0]} " ) "
2121ROOT_PATH=" $( cd " ${SCRIPT_DIR} " /.. && pwd) "
2222
23- VERSION=" 0.29.0 "
23+ VERSION=" v8.0.3 "
2424
2525MODE=" check"
2626
2727if [[ " $* " == " fix" ]]; then
2828 MODE=" fix"
2929fi
3030
31- if [[ " ${OSTYPE} " == " linux" * ]]; then
32- BINARY=" buildifier"
33- elif [[ " ${OSTYPE} " == " darwin" * ]]; then
34- BINARY=" buildifier.mac"
31+ OS=" $( uname -s) "
32+ ARCH=" $( uname -m) "
33+
34+ # Determine OS-specific binary name
35+ if [[ " ${OS} " == " Linux" ]]; then
36+ BINARY=" buildifier-linux"
37+ elif [[ " ${OS} " == " Darwin" ]]; then
38+ BINARY=" buildifier-darwin"
39+ fi
40+
41+ # Append architecture suffix for the appropriate binary
42+ if [[ " ${ARCH} " == " x86_64" ]] || [[ " ${ARCH} " == " amd64" ]]; then
43+ BINARY=" ${BINARY} -amd64" # No change needed, this is the default
44+ elif [[ " ${ARCH} " == " arm64" ]] || [[ " ${ARCH} " == " aarch64" ]]; then
45+ BINARY=" ${BINARY} -arm64"
3546fi
3647
3748# create a temporary directory
6879
6980echo " Running buildifier..."
7081cd " ${ROOT_PATH} " || exit
71- " ${BUILDIFIER} " -mode=${MODE} Tiltfile >> " ${OUT} " 2>&1
82+ " ${BUILDIFIER} " -mode=${MODE} -v Tiltfile >> " ${OUT} " 2>&1
You can’t perform that action at this time.
0 commit comments