Open
Description
Is go-getter able to retrieve a single file from a git repo? It appears to work fine when the source is a directory, but not when the source is a file.
It does create the target directory, but does not write the file.
$ ./go-getter github.com/hashicorp/go-getter//helper/url/url.go url
2018/01/29 16:12:51 Success!
$ cat url/url.go
cat: url/url.go: No such file or directory
$ ls -al url/url.go
ls: cannot access url/url.go: No such file or directory
$ ls -al url
total 0
drwxr-xr-x 2 ec2-user ec2-user 6 Jan 29 16:12 .
drwx------ 5 ec2-user ec2-user 124 Jan 29 16:12 ..
Also tried specifying the destination as a filename, but that just creates a directory named for the file:
$ ./go-getter github.com/hashicorp/go-getter//helper/url/url.go url/url.go
2018/01/29 16:21:36 Success!
$ ls -al url
total 0
drwxr-xr-x 3 ec2-user ec2-user 20 Jan 29 16:21 .
drwx------ 5 ec2-user ec2-user 124 Jan 29 16:12 ..
drwxr-xr-x 2 ec2-user ec2-user 6 Jan 29 16:21 url.go
$ ls -al url/url.go
total 0
drwxr-xr-x 2 ec2-user ec2-user 6 Jan 29 16:21 .
drwxr-xr-x 3 ec2-user ec2-user 20 Jan 29 16:21 ..
Metadata
Metadata
Assignees
Labels
No labels