gopath Questions

4

Solved

Before it happened, what I am doing is trying to use the dep to manage my golang code dependency. What I found right now is I cannot do any command with go, even if I try to uninstall it with brew ...
Aguila asked 26/2, 2020 at 4:23

8

Small part of error I'm getting after trying to run go build command go build ./... trillian.pb.go:7:8: cannot find package "github.com/golang/protobuf/proto" in any of: /usr/local/go/src/github....
Ketron asked 10/4, 2017 at 13:48

2

I have a ~/.config/fish/config.fish which contains the following lines: set PATH $PATH (go env GOPATH)/bin set -x GOPATH (go env GOPATH) If I simply run go env GOPATH at the command line, I get ...
Tews asked 23/10, 2019 at 2:13

25

Solved

I'm trying to install doozer like this: $ goinstall github.com/ha/doozer I get these errors. goinstall: os: go/build: package could not be found locally goinstall: fmt: go/build: package coul...
Unscramble asked 1/11, 2011 at 17:32

2

Solved

I have the following project structure, outside of GOPATH. . // Project root ├── Dockerfile ├── .env ├── README.md └── src ├── main.go ├── go.mod ├── go.sum ├── internal │   ├── somepackage │...
Polik asked 11/11, 2020 at 6:43

4

I installed Golang and faced with go.mod file not found in current directory or any parent directory error at very first time. But I'm working on <GOPATH>/src directory. Isn't go.mod only req...
Cozza asked 11/6, 2021 at 0:21

7

Solved

I'm unable to run go get git@github<user/repo> in my $GOPATH folder. Getting this error: go: cannot use path@version syntax in GOPATH mode I just want to understand why go get isn't work...
Fraternal asked 29/1, 2019 at 7:18

5

I have some confusion regarding Golang directory structure. Base on the book The Way to Go by Ivo Balbaert, project code should be placed into src, and recommends the following directory structure....
Hex asked 9/10, 2017 at 12:32

1

Solved

I need to remove absolute path in the trace, that corresponds to the imported module. Even though I compile my program so: go build -gcflags=-trimpath=$GOPATH -asmflags=-trimpath=$GOPATH I still ge...
Woodhouse asked 10/9, 2020 at 14:11

3

coming from a java and grails background, (and having written millions of lines of C 30 years ago), I cant see how go can be usable with a fixed gopath on windows. installing go creates this struc...
Skittish asked 30/1, 2018 at 21:49

1

Solved

So I've been scratching my head at this for a couple weeks now, and after reading several source on how $ go build works and its three magic directories, /bin, /pkg, /src, it's still not very clear...
Rudnick asked 30/11, 2018 at 17:20

1

Solved

Simple Go project, with a external dependence: import ( "fmt" "html" "log" "net/http" "github.com/gorilla/mux" ) My path working fine for other tasks like run, build, etc.: GOPATH="/h...
Claiborne asked 23/6, 2017 at 17:11

1

Solved

I'm a new golang developer and I wonder why $GOPATH environment variable is needed to be set at the root of my project. If I'm working on several projects at the same time, I need to each time re-...
Semela asked 19/6, 2016 at 5:35
1

© 2022 - 2024 — McMap. All rights reserved.