4

I'm a beginner in Go and I would like to use the Revel web framework. I installed: Git; Mercurial and even: Bazaar and CVS.

I checked my environment variables. I set environment variable GOPATH to D:\Go and added D:\Go\bin to PATH.But I still get these errors when I go get The Revel Framework (go get github.com/revel/revel)

**

  • package golang.org/x/net/websocket: unrecognized import path "golang.org/x/net/websocket"

  • package gopkg.in/fsnotify.v1: unrecognized import path "gopkg.in/fsnotify.v1"**

Neat Head
  • 37
  • 4
  • 1
    Don't set GOROOT if you have. What is the output of `go env`? You also may have an old version of git (or maybe go). What is the output of `git version` and `go version`? – JimB Apr 24 '15 at 14:02
  • I deleted GOROOT but I still have the same problem. Here is the output of go env: C:\windows\system32>go env set GOARCH=386 set GOBIN= set GOCHAR=8 set GOEXE=.exe set GOHOSTARCH=386 set GOHOSTOS=windows set GOOS=windows set GOPATH=C:\Users\MixaMo\Documents\Go set GORACE= set GOROOT=C:\Go set GOTOOLDIR=C:\Go\pkg\tool\windows_386 set CC=gcc set GOGCCFLAGS=-m32 -mthreads -fmessage-length=0 set CXX=g++ set CGO_ENABLED=1 -The output of git version: git version 1.9.5.msysgit.1 -Te output of go version go version go1.4.2 windows/386 – Neat Head Apr 28 '15 at 08:34
  • Try setting the GOBIN ? Also your GOROOT is still set and does not match what you mentioned above ? – LenW Jun 22 '15 at 16:02

1 Answers1

2

For instalation of GO into your home folder you need this environment variables:

.
├── bin
├── go (GO)
└── src
    ├── revel.project
    │   ├── app
    │   │   ├── controllers
    │   │   ├── models
    │   │   ├── routes
    │   │   ├── tmp
    │   │   └── views
    │   │       ├── admin
    │   │       ├── App
    │   │       ├── errors
    │   │       └── users
    │   ├── conf
    │   ├── messages
    │   ├── public
    │   │   ├── css
    │   │   │   └── administrator
    │   │   ├── img
    │   │   ├── js
    │   │   └── uploads
    │   │       └── 1
    │   ├── resources
    │   ├── scripts
    │   ├── test-results
    │   └── tests
    ├── code.google.com
    ├── github.com
    │   ├── revel
    │   │   ├── cmd
    │   │   ├── modules
    │   │   └── revel

run this in your prompt path or modify if your folders are differents.

  export GOARCH=amd64
  export GOPATH=~/go
  export GOBIN=~/go/go/bin
  export GOROOT=~/go/go
  export PATH=$PATH:$GOPATH/go/bin
  export GOTOOLDIR=~/go/go/pkg/tool/linux_amd64
  export CC="gcc"
  export GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0"
  export CXX=g++
  export CGO_ENABLED=1

Where ~ is the name of you personal folder in the system (Bash Gnu Linux)

ggerman
  • 21
  • 5