Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [che-dev] Simplify mounting of project sources to plugins

Yes, Lukas, you are completely right. We can’t clone Che-plugin-broker into /projects since traditional go tooling would not work

вт, 22 янв. 2019 г. в 18:01, Lukas Krejci <lkrejci@xxxxxxxxxx>:


On 22. 01. 19 16:43, tmader@xxxxxxxxxx wrote:
> On Tue, 2019-01-22 at 17:32 +0200, Oleksandr Garagatyi wrote:
>> @Thomas Maeder
>> In Go world projects are located by the GOPATH. Usually, GOPATH env
>> var is exported in bash profile or so. E.g. export
>> GOPATH=/home/user/goAfter that Go compiler and utils follow next
>> structural location of files:
>> $GOPATH/src <- projects AND dependencies (though dependencies not
>> always go here)
>> $GOPATH/bin <- compiled and packaged Go apps (usually added to PATH
>> to launch tools from it, often used for go based linters and other Go
>> related tools)
>> $GOPATH/src contains folders that represent Go packages and usually
>> include source hosting like github.com or golang.org.
>> For example, when I'm working on Che broker repo my path is
>> $GOPATH/src/github.com/eclipse/che-plugin-broker or
>> /home/gaal/workspace/go/src/github.com/eclipse/che-plugin-broker on
>> my system in particular.
>> All the Go tools like linters, compiler, and others expect GOPATH to
>> be populated in the system and structure to be respected.
>>
>> Hope it helps. If not, please, let me know.
> Thanks for the explanation. Howerver, I don't think it's a problem for
> the tooling, because the tooling will be installed in the plugin
> sidecar, where we control the value of $GOPATH (as well as in the Theia
> container). Why should GOPATH not be /projects?
>

You need to checkout your code into a particular subdirectory of GOPATH
that corresponds to the "structure convention" of Go, if I am not
mistaken (and please correct me if I'm wrong, Alex, I'm a Go noob).

E.g. because che-plugin-broker is hosted on github, it *needs* to be
checked out precisely to

$GOPATH/src/github.com/eclipse/che-plugin-broker

is that compatible we how we checkout stuff into /projects?

> /Thomas
>
>
>
>
>
> _______________________________________________
> che-dev mailing list
> che-dev@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or unsubscribe from this list, visit
> https://www.eclipse.org/mailman/listinfo/che-dev
>
_______________________________________________
che-dev mailing list
che-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/che-dev
--
Oleksandr Garagatyi

Back to the top