I have this file structure
project/main.go
project/go.mod
project/dependency1/mod.go
When I’m inside project
I can run go build main.go
, but when I try to run from anywhere else, I get errors like
src/lattigo/go/main.go:7:2: no required module provides package github.com/ldsec/lattigo/v2/ckks: go.mod file not found in current directory or any parent directory; see 'go help modules'
Is there a way to specify the current directory on Go? I tried GOPATH but it does not work either