mattn/gom

Weird error when a package is already in $GOPATH

nono opened this issue · 8 comments

nono commented

Hi,

I'm trying gom, but I found a weird error. If I have already installed a package with go install (for example github.com/jrallison/go-workers), and then I create a Gomfile with:

gom 'github.com/jrallison/go-workers', :commit => 'f9540adf4c3635a54663b9c55671b54de77d19fc'

If I run gom install, it fails with a weird error:

$ gom install
installing github.com/jrallison/go-workers
gom:  gom currently support git/hg for specifying tag/branch/commit

And vendor/ remains empty.

Could you please try it again with gom install -x ?

nono commented

Yes, it says:

$ gom install -x
installing github.com/jrallison/go-workers
WORK=/tmp/go-build281703598
gom:  gom currently support git/hg for specifying tag/branch/commit

But still nothing in vendor/.

ok, could you please try this in latest version?

nono commented

Still the same.

nono commented

From what I understand of gom, I think the scenario is:

  • gom appends vendor/ to $GOPATH
  • gom lanches go get -u github.com/jrallison/go-workers, but it does nothing as this package is already installed in the $GOPATH
  • gom try to go vendor/src/github.com/jrallison/go-workers to do git stuff, but it can't as the directory doesn't exist
  • so it says this package is not a git/hg repository

Ah, ok. I'll fix.

Done

nono commented

It works fine. Thanks for the quick fix