Skip to content

Commit 86ad372

Browse files
committed
fixup! chore: embed static files in debug builds
1 parent b997563 commit 86ad372

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

scripts/build_go.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,10 +107,12 @@ if [[ "$sign_darwin" == 1 ]]; then
107107
fi
108108

109109
ldflags=(
110-
-s
111-
-w
112110
-X "'github.com/coder/coder/v2/buildinfo.tag=$version'"
113111
)
112+
# Disable deubgger information if not building a binary for debuggers.
113+
if [[ "$debug" == 0 ]]; then
114+
ldflags+=(-s -w)
115+
fi
114116

115117
# We use ts_omit_aws here because on Linux it prevents Tailscale from importing
116118
# github.com/aws/aws-sdk-go-v2/aws, which adds 7 MB to the binary.

0 commit comments

Comments
 (0)