Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

go-use plugin doesn't respect source-subdir #978

Open
tigarmo opened this issue Jan 16, 2025 · 1 comment · May be fixed by #980
Open

go-use plugin doesn't respect source-subdir #978

tigarmo opened this issue Jan 16, 2025 · 1 comment · May be fixed by #980
Labels
Bug Something isn't working Triaged

Comments

@tigarmo
Copy link
Contributor

tigarmo commented Jan 16, 2025

Bug Description

Some go modules are hosted in subdirs of a git repo; for example, https://github.com/elazarl/goproxy/tree/master/ext has the github.com/elazarl/goproxy/ext module but the repo itself is github.com/elazarl/goproxy. One can use source-subdir to specify the build subdir, but the go-use plugin doesn't respect it.

To Reproduce

.

part yaml

parts:
  elazarl/goproxy/ext:
    override-pull: craftctl default; git checkout a0805db90819
    plugin: go-use
    source: https://github.com/elazarl/goproxy.git
    source-subdir: ext

Relevant log output

.
@tigarmo tigarmo added Bug Something isn't working Triaged labels Jan 16, 2025
Copy link

Thank you for reporting your feedback to us!

The internal ticket has been created: https://warthogs.atlassian.net/browse/CRAFT-3906.

This message was autogenerated

tigarmo added a commit that referenced this issue Jan 17, 2025
It's possible, and somewhat common, for a go module to be defined inside a
repo's subdir; in this case we can define source-subdir, but the go-use
plugin needs to use this - otherwise the repo root gets used.

Fixes #978
@tigarmo tigarmo linked a pull request Jan 17, 2025 that will close this issue
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working Triaged
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant