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
cmd/go: doesn't work with arbitrary git servers on https #2895
Labels
Milestone
Comments
This command is just wrong: git clone camlistore.org/r/p/camlistore /Users/bradfitz/hack/src/camlistore.org/r/p/camlistore.git The repository (argv[2]) should be a full URL with a protocol. Goinstall would cycle through a list of protocols and use the first that worked. As is, the git command tries to look for a directory on the local file system instead of hitting the remote host. |
The fix would look like In vcsCmd, add a scheme []string and also a pingCmd string. The latter is the command to test whether a repository exists. Add a vcsCmd ping method that calls pingCmd. In vcsPaths, add a check function to this case: // General syntax for any server. { re: `^(?P<root>(?P<repo>([a-z0-9.\-]+\.)+[a-z0-9.\-]+(:[0-9]+)?/[A-Za-z0-9_.\-/]*?)\.(?P<vcs>bzr|git|hg|svn))(/[A-Za-z0-9_.\-]+)*$`, }, and have the check function add the scheme:// to the repo after pinging the various schemes in order. There was an established order in goinstall; we should use the same. Russ |
Comment 6 by eikeon@eikeon.com: I've done the fix described in comment 5 and am interested in contributing it. Next I'll hit the learning curve on the contribution process unless someone has already beat me to to fixing this issue? |
Perfect! The contribution instructions are here: http://golang.org/doc/contribute.html |
Comment 8 by eikeon@eikeon.com: Great :) I've run hg change to create: http://golang.org/cl/5651055/ I'm not sure from reading the contribution instructions if I'm to also run hg mail now? Also I'm assuming I needed to ping this ticket manually as it doesn't look like the "fixes issue" comment tied the review together with this issue. |
Thanks. And now join the mailing list, so you can be whitelisted to run "hg mail" in the future without moderation: https://groups.google.com/group/golang-dev/subscribe (You can choose "No email", but you need to be a "member" to work around a bug with Groups' moderation) |
Comment 10 by eikeon@eikeon.com: 5651055 got a LGTM. I can't yet submit the change as I'm not in the CONTRIBUTORS file. I've signed the CLA and will try again if I notice I've been added, else I'm assuming someone else picks up the commit for me. Is there a good place to look for another issue that could use someone working on it? |
This issue was closed by revision dcf5ca7. Status changed to Fixed. |
This issue was closed.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The text was updated successfully, but these errors were encountered: