RRethy/vim-hexokinase

go: cannot find main module, but found .git/config in /home/wangjl/.config/nvim/plugged/vim-hexokinase

Closed this issue · 3 comments

git submodule init && git submodule update && cd hexokinase/ && go build
go: cannot find main module, but found .git/config in /home/wangjl/.config/nvim/plugged/vim-hexokinase
to create a module there, run:
cd .. && go mod init
make: *** [Makefile:3: hexokinase] Error 1

What's the output of go version and go env?

go version go1.14.4 linux/amd64

GO111MODULE="on"
GOARCH="amd64"
GOBIN="/home/wangjl/go/bin"
GOCACHE="/home/wangjl/.cache/go-build"
GOENV="/home/wangjl/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/home/wangjl/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/lib/go"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/lib/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/dev/null"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build306316343=/tmp/go-build -gno-record-gcc-switches"

Try it again and reopen if it still doesn't work.