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
20
20
SCRIPT_DIR=" $( dirname " ${BASH_SOURCE[0]} " ) "
21
21
ROOT_PATH=" $( cd " ${SCRIPT_DIR} " /.. && pwd) "
22
22
23
- VERSION=" 0.29.0 "
23
+ VERSION=" v8.0.3 "
24
24
25
25
MODE=" check"
26
26
27
27
if [[ " $* " == " fix" ]]; then
28
28
MODE=" fix"
29
29
fi
30
30
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"
35
46
fi
36
47
37
48
# create a temporary directory
68
79
69
80
echo " Running buildifier..."
70
81
cd " ${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