It's worth noting that @latest only works for "releases" and not for tags/releases labelled pre-release. Just in case anyone hits the same issue I did a while back! :)
On Wednesday, 25 May 2022 at 07:40:04 UTC+1 Volker Dobler wrote: > If you want the command to be installed: Why don't you install > _the_ _command_ with > go install https://github.com/chmike/clog/cmd/clogClr@latest > ? (Note that there is no need to install the package.) > > V. > > On Wednesday, 25 May 2022 at 08:13:58 UTC+2 christoph...@gmail.com wrote: > >> I have a small package (https://github.com/chmike/clog) that also >> contains a command in the cmd subdirectory (clogClr). How do I install >> the clog package and the command ? >> >> When I execute "go install github.com/chmike/clog@latest" I get the >> error message that it is not a main package. When I use go get that package >> is installed, but not the command (clogClr). >> >> I understand that for security purpose installing a package should not >> automatically install an executable binary. >> >> For now I do a git clone and a "go install ./...". It's fine for me, not >> for an end user. I assume there is a better way. >> > -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/248b767d-d4d2-473a-a685-35c41eab6bfan%40googlegroups.com.