go get github.com/hmarui66/go-watchcd [project root]
go-watchYou can use go build flags with -build-flags flag.
These flags are set in the form of go build -o {binfile} [build flags].
For example, this command
go-watch -build-flags '-ldflags "-X configs.someValue=100 -X configs.anotherValue=300"'will trigger the following build command.
go build -o {binfile} -ldflags "-X configs.someValue=100 -X configs.anotherValue=300"