If I understand correctly, go install
puts binaries in $GOBIN
directory.
I tend to forget which packages provide which binaries in $GOBIN
and which packages I go install
-ed.
Is there a way to list packages that are currently go install
-ed?
I could, obviously, do ls $GOBIN
and that'll give me names of binaries. However, I'm looking for a way to get a list of packages with their long names, e.g. github.com/operator-framework/operator-sdk
.
Update: go list ...
(suggested here) does not seem to apply to my case because this command expects me to be in a directory containing go.mod
file. I understand that go list
is designated for listing packages of a project. In my case, I need to find out all packages that are installed into $GOBIN
of my system/user.
go list all
in a folder outside GOPATH and without ago.mod
? (and what's yourgo version
). – Kmesongo list all
->go: warning: "all" matched no packages
,go version
->go version go1.16.2 linux/amd64
– Simmer