FAQ
Hello,

So I am just getting started with Go and have installed it prebuilt from
the ubuntu software (the joys of being lazy). To my dismay, it doesn't seem
to have created anything resembling the go root. It created a folder called
go, however it only contains a folder src.

Furthermore VIM should be being configured to recognize *.go files and
highlight/indent them, but it doesn't seem to be doing this, any
suggestions would be great.

--

Search Discussions

  • David Symonds at Nov 20, 2012 at 3:59 am

    On Tue, Nov 20, 2012 at 1:07 PM, Danny Gratzer wrote:

    Furthermore VIM should be being configured to recognize *.go files and
    highlight/indent them, but it doesn't seem to be doing this, any suggestions
    would be great.
    Did you view the README in misc/vim?

    --
  • Dave Cheney at Nov 20, 2012 at 4:11 am
    GOROOT is not required when using the ubuntu package, it is hard coded
    into the go tool itself,

    go env

    will show you the details.
    On Tue, Nov 20, 2012 at 1:07 PM, Danny Gratzer wrote:
    Hello,

    So I am just getting started with Go and have installed it prebuilt from the
    ubuntu software (the joys of being lazy). To my dismay, it doesn't seem to
    have created anything resembling the go root. It created a folder called go,
    however it only contains a folder src.

    Furthermore VIM should be being configured to recognize *.go files and
    highlight/indent them, but it doesn't seem to be doing this, any suggestions
    would be great.

    --
    --
  • Danny Gratzer at Nov 20, 2012 at 5:38 am
    No misc file appears. I ended up just giving up and downloading the tar
    from golang.org. It's a bit odd that the package ubuntu offers doesn't do
    that though.
    On Monday, November 19, 2012 10:11:34 PM UTC-6, Dave Cheney wrote:

    GOROOT is not required when using the ubuntu package, it is hard coded
    into the go tool itself,

    go env

    will show you the details.
    On Tue, Nov 20, 2012 at 1:07 PM, Danny Gratzer wrote:
    Hello,

    So I am just getting started with Go and have installed it prebuilt from the
    ubuntu software (the joys of being lazy). To my dismay, it doesn't seem to
    have created anything resembling the go root. It created a folder called go,
    however it only contains a folder src.

    Furthermore VIM should be being configured to recognize *.go files and
    highlight/indent them, but it doesn't seem to be doing this, any
    suggestions
    would be great.

    --
    --
  • David Symonds at Nov 20, 2012 at 5:39 am
    What's the package name, and which release of Ubuntu are you using?

    --
  • Danny Gratzer at Nov 20, 2012 at 5:41 am
    Ubuntu 12.04, The package is golang. The one liner description in synaptic
    is: "Go programming language compiler - metapackage" It's description seems
    to imply that it's the go toolchain, and it seems to be except for the fact
    that it doesn't create anything resembling a goroot.
    On Monday, November 19, 2012 11:39:09 PM UTC-6, David Symonds wrote:

    What's the package name, and which release of Ubuntu are you using?
    --
  • David Symonds at Nov 20, 2012 at 5:48 am

    On Tue, Nov 20, 2012 at 4:41 PM, Danny Gratzer wrote:

    Ubuntu 12.04, The package is golang. The one liner description in synaptic
    is: "Go programming language compiler - metapackage" It's description seems
    to imply that it's the go toolchain, and it seems to be except for the fact
    that it doesn't create anything resembling a goroot.
    As Dave Cheney pointed out, you don't need to set up a GOROOT. The
    golang-go package (a dep of the golang package) installs /usr/bin/go;
    you should be able to use that. It looks like its GOROOT is set up in
    /usr/lib/go.

    misc/vim does indeed seem to be omitted from those packages. I don't
    know how to change that. There's a golang-mode package for just the
    emacs support files, but it seems silly to have to have a golang-x
    package for every possible editor.


    Dave.

    --
  • Danny Gratzer at Nov 20, 2012 at 5:50 am
    Yeah... Though it was a very very minor inconvenience to just download the
    tar. Something that should be mentioned to whoever maintains those packages.

    --
  • Dave Cheney at Nov 20, 2012 at 5:53 am
    Hi Danny,

    Although I work for Canonical, I don't maintain this package (I think
    it comes from the debian upstream), the best way to raise this would
    be a bug on either

    https://launchpad.net/ubuntu/+source/golang

    or

    http://packages.debian.org/sid/golang

    Sorry I can't be more help, I just dont' work in that part of Canonical.

    Cheers

    Dave
    On Tue, Nov 20, 2012 at 4:50 PM, Danny Gratzer wrote:
    Yeah... Though it was a very very minor inconvenience to just download the
    tar. Something that should be mentioned to whoever maintains those packages.

    --
    --
  • Rémy Oudompheng at Nov 20, 2012 at 7:48 am
    You should never have to set GOROOT, except in very, very specific situations.

    The vim plugin is in the vim-syntax-go package on Debian.

    Rémy.

    2012/11/20, Danny Gratzer <danny.gratzer@gmail.com>:
    Hello,

    So I am just getting started with Go and have installed it prebuilt from
    the ubuntu software (the joys of being lazy). To my dismay, it doesn't seem

    to have created anything resembling the go root. It created a folder called

    go, however it only contains a folder src.

    Furthermore VIM should be being configured to recognize *.go files and
    highlight/indent them, but it doesn't seem to be doing this, any
    suggestions would be great.

    --

    --
  • Starfish at Nov 21, 2012 at 9:43 am
    I had an issue with the gocode tool. This had to do with $GOROOT not being
    set, so I think it should be set just in case.

    --
  • Dave Cheney at Nov 21, 2012 at 10:12 am
    I disagree. gocode should configure itself using the output of `go env`
    On Wed, Nov 21, 2012 at 8:43 PM, Starfish wrote:
    I had an issue with the gocode tool. This had to do with $GOROOT not being
    set, so I think it should be set just in case.

    --
    --

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupgolang-nuts @
categoriesgo
postedNov 20, '12 at 3:58a
activeNov 21, '12 at 10:12a
posts12
users5
websitegolang.org

People

Translate

site design / logo © 2022 Grokbase