I realized that I had still set
GOPATH to a folder in my home directory. Upon removing it my development workflow for go with nix breaks, for obvious reasons, since commands like
go mod download can’t write to the nix store.
Does everyone just keep a permanent
GOPATH in their shell config? Do you set a
GOPATH on a per project basis? Do you handle this completely differently? Note that I’m explicitly not talking about how to build the package for production. It’s just about the development workflow for go.