Open nathani-axis opened 2 years ago
I believe that if you do a go install
with an explicit version tag that it won't add it to your containing project. This StackOverflow solution indicates that could be a solution for you.
Could you try it and let me know if that works? I can update the installation instructions if you'd find them more clear.
I had the same issue and I fixed it by installing the tool via:
go install github.com/derision-test/go-mockgen/...@v1.3.1
Hello,
I'm using go-mockgen in one of my projects, where I have it run in a bash script. I see in the README that the installation instructions are:
but as that's the old way of installing tools, go complains, and asks me to use
go install
instead.So my bash script includes:
When I run by bash script though, I get this output:
These missing entries are not actually missing entries, as I don't want them in my go project. go-mockgen is a tool I want to run on the project, but I don't necessarily want to add it as dependencies for my project.
Moreover, if I do run all the
go get
commands that are listed, whenever I will rungo mod tidy
, they will be removed, as they are not actually dependencies in my code.Thanks