← Back to issue list

go plugin ignores the source-subdir keyword

View original Launchpad issue

Metadata

Project
snapcraft
Number
#1613779
Type
issue
State
open
Author
~jgrimm
Labels
plugin sources
Created
2016-08-16 16:05:11.434516+00:00
Updated
2017-03-19 20:55:25.656357+00:00
Closed

Current evaluation

No evaluation has been recorded for this issue yet.

Issue body

When using 'source', the go plugin assumes source is in the git root dir. Sample snapcraft.yaml of project that shows this below. The go plugin attempts to symlink in the source from the local cloned repo, but makes an assumption that the root of the git repo holds the source. In the below case the real source to build is at 'src/cmd/frps' within the git repo. Here's the symlink created: jgrimm@jgrimm-ThinkPad-X250:~/snapit/frps/parts/frps/go/src/github.com/fatedier/frp/src/cmd$ ll total 12 drwxr-xr-x 2 jgrimm lxd 4096 Aug 16 10:24 ./ drwxr-xr-x 3 jgrimm lxd 4096 Aug 16 10:24 ../ lrwxrwxrwx 1 jgrimm lxd 39 Aug 16 10:24 frps -> /home/jgrimm/snapit/frps/parts/frps/src/ Instead that frps link should be to /home/jgrimm/snapit/frps/parts/frps/src/src/cmd/frps/ --- snapcraft.yaml --- name: frps version: "0.8" summary: frps - short text description: | FIXME: confinement: devmode apps: frps: command: bin/frps plugs: [network, network-bind] parts: frps: plugin: go source: https://github.com/fatedier/frp.git go-importpath: github.com/fatedier/frp/src/cmd/frps build-packages: [git] ---

Evaluation history

No evaluation history available.