Closed qknight closed 7 years ago
You don't need to add vendor
to GOPATH
. This would be included automatically.
I ran https://github.com/kamilchm/go2nix/blob/master/test/test_leaps.sh with current go2nix
1.1.1 and it produces deps.nix
like:
# This file was generated by go2nix.
[
{
goPackagePath = "golang.org/x/net";
fetch = {
type = "git";
url = "https://go.googlesource.com/net";
rev = "5d997795f7bb1d2de5edc1f5d64af2562401c82d";
sha256 = "1kcqn4lninavavlspcn6gn621cvn2skyc9jwfwy8052ys8p1r2kg";
};
}
]
I also did:
nix-shell -p go2nix git go
cd `mktemp -d`
export GOPATH=`pwd`
go get github.com/jeffail/leaps/cmd/...
cd src/github.com/jeffail/leaps/cmd/leaps
go2nix save
and I got deps.nix
:
# This file was generated by go2nix.
[
{
goPackagePath = "golang.org/x/net";
fetch = {
type = "git";
url = "https://go.googlesource.com/net";
rev = "5d997795f7bb1d2de5edc1f5d64af2562401c82d";
sha256 = "1kcqn4lninavavlspcn6gn621cvn2skyc9jwfwy8052ys8p1r2kg";
};
}
]
Could you try it exactly like that?
yeah, that works! i want to add this example to the README.md soon.
thanks!
i've tried multipe hours to get a
deps.nix
from leaps which i once even got working.can you please advice how to approach the problem?
https://github.com/Jeffail/leaps
concept
deps.nix