msprev / fzf-bibtex

a BibTeX source for fzf
BSD 3-Clause "New" or "Revised" License
129 stars 15 forks source link

go get: installing executables with 'go get' in module mode is deprecated. #25

Closed ghost closed 3 years ago

ghost commented 3 years ago

When I tried to install fzf-bibtex by running

go get github.com/msprev/fzf-bibtex/cmd/bibtex-ls
go install github.com/msprev/fzf-bibtex/cmd/bibtex-ls
go install github.com/msprev/fzf-bibtex/cmd/bibtex-markdown
go install github.com/msprev/fzf-bibtex/cmd/bibtex-cite

I got errors as follows.

go: downloading github.com/msprev/fzf-bibtex v0.0.0-20201112190009-53c49fab1011
go get: installing executables with 'go get' in module mode is deprecated.
    Use 'go install pkg@version' instead.
    For more information, see https://golang.org/doc/go-get-install-deprecation
    or run 'go help get' or 'go help install'.
go install: version is required when current directory is not in a module
    Try 'go install github.com/msprev/fzf-bibtex/cmd/bibtex-ls@latest' to install the latest version
go install: version is required when current directory is not in a module
    Try 'go install github.com/msprev/fzf-bibtex/cmd/bibtex-markdown@latest' to install the latest version
go install: version is required when current directory is not in a module
    Try 'go install github.com/msprev/fzf-bibtex/cmd/bibtex-cite@latest' to install the latest version

The following codes worked instead.

go get -d github.com/msprev/fzf-bibtex/cmd/bibtex-ls
go install github.com/msprev/fzf-bibtex/cmd/bibtex-ls@latest
go install github.com/msprev/fzf-bibtex/cmd/bibtex-markdown@latest
go install github.com/msprev/fzf-bibtex/cmd/bibtex-cite@latest

update: go version

go version go1.17 darwin/amd64
msprev commented 3 years ago

Thanks very much for spotting this. I've updated the install instructions now. My understanding is that go get -d ... is not needed in this context so I've omitted that line from the instructions.