kamilchm / go2nix

Reproducible builds and development environment for Go
MIT License
94 stars 17 forks source link

Error building #27

Closed nhooyr closed 7 years ago

nhooyr commented 7 years ago

go get github.com/kamilchm/go2nix gives:

$GOPATH/src/github.com/kamilchm/go2nix/nix.go:109: undefined: Asset

edit: seems to build fine with nix though. as in I add pkgs.go2nix to environment.systemPackages

kamilchm commented 7 years ago

Unfortunately programs that use go-bindata to embed assets can't be build with go get :/ What you can do is:

$ go get -d github.com/kamilchm/go2nix
$ pushd $GOPATH/src/github.com/kamilchm/go2nix
$ go generate
$ go build
$ cp $GOPATH/src/github.com/kamilchm/go2nix/go2nix $GOPATH/bin
$ popd

This should work the same as go get for regular packages.

kamilchm commented 7 years ago

After some thoughts, I think I can check in generated assets.go to make installation easier.