buildGo CLAUDE
Read the manpage before changing anything here or in any default.nix that
uses buildGo:
man ./nix/buildGo/buildGo.7
Two things in particular are not guessable from the call site:
//go:embedneeds staged sources. Passing path literals (srcs = [ ./main.go ]) puts every file in its own store path, so the embed scan finds nothing and the embedded variables end up silently empty — the build still succeeds. Sources and embedded assets must be staged into one directory withrunCommandLocaland passed as strings.- Tests are never run.
*_test.gofiles are left out ofsrcs; run them withgo testvia thego.workworkspace instead.