Skip to content
This repository has been archived by the owner on Aug 25, 2018. It is now read-only.

Fails with symlinks #12

Closed
peter-mogensen opened this issue Dec 16, 2015 · 3 comments · May be fixed by constabulary/gb#534
Closed

Fails with symlinks #12

peter-mogensen opened this issue Dec 16, 2015 · 3 comments · May be fixed by constabulary/gb#534

Comments

@peter-mogensen
Copy link

Projects can contain internal relative symlinks and work fine with go get.
(example: https://github.com/valyala/ybc)

However, the current file handling code skips symlinks when copying - breaking otherwise fine working go-getable Go packages.

I think I have a small patch to make it work, but those knowing github.com/constabulary/gb and how it's vendored into gvt could probably make a more general patch.

@FiloSottile
Copy link
Owner

Yeah, this broke my vendor/ tests with a couple projects, too.

The background is at constabulary/gb#184, I'll submit a PR to fix it upstream, since now Copyfile is in filepath, which gvt vendors.

FiloSottile added a commit to FiloSottile/gb that referenced this issue Jan 9, 2016
This was removed instead of being special cased in constabulary#185, because gb has no
direct need for it (see constabulary#184).  However it's useful for other users of the
library.  For example gvt needs to retain test fixtures intact (as vendor/
packages are testable) and needs to support symlink-based packages (since
the go build tool does).

Fixes FiloSottile/gvt#12
@peter-mogensen
Copy link
Author

I think I have a primitive fix in my fork.
It doesn't handle file permissions perfect when copying from /tmp to the
vendor dir though.

/Peter

@FiloSottile
Copy link
Owner

I submitted a banal patch to gb, now waiting on Dave.

Sent from a small keyboard

On 09 gen 2016, at 05:30, peter-mogensen [email protected] wrote:

I think I have a primitive fix in my fork.
It doesn't handle file permissions perfect when copying from /tmp to the
vendor dir though.

/Peter

Reply to this email directly or view it on GitHub.

FiloSottile added a commit that referenced this issue Mar 19, 2016
This was removed instead of being special cased in constabulary/gb#185,
because gb has no direct need for it (see constabulary/gb#184).  However
it's useful for gvt, as it needs to retain test fixtures intact (as vendor/
packages are testable) and needs to support symlink-based packages (since
the go build tool does).

Fixes #12
@FiloSottile FiloSottile modified the milestone: Blog announcement Apr 26, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants