Skip to content

Commit eff2354

Browse files
committed
Fix Nix bug in MacOS with conditional patch
Signed-off-by: jose.vazquez <[email protected]>
1 parent abbedf8 commit eff2354

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

devbox.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,5 +28,16 @@
2828
"gh@latest",
2929
"addlicense@latest",
3030
"fd@latest"
31-
]
31+
],
32+
"shell": {
33+
"init_hook": [
34+
"if test \"$(uname -s)\" = \"Darwin\"; then",
35+
" echo 'Shell Hook: Applying macOS + Nix + Go 1.25 CGO fix...'",
36+
" export CGO_ENABLED=0",
37+
" export BUILD_TAGS='netgo,osusergo'",
38+
"else",
39+
" echo 'Shell Hook: Not Darwin, skipping CGO fix. Using defaults.'",
40+
"fi"
41+
]
42+
}
3243
}

0 commit comments

Comments
 (0)