gddo icon indicating copy to clipboard operation
gddo copied to clipboard

Mention Gitea, and generic git, mecurial, bzr support

Open coolaj86 opened this issue 6 years ago • 7 comments

As I understand it, the docs just work by git (or mercurial or bzr) and are not tied to specific platforms.

However, the docs on the website are unclear about this:

GoDoc hosts documentation for Go packages on Bitbucket, GitHub, Google Project Hosting and Launchpad.

Being new to the Go community and trying to understand how things work, I was confused by this at first.

I'd suggest updating the copy to read something more similar to this:

GoDoc hosts documentation for Go packages using git, mercurial, and bzr import URLs.

This works with popular hosting sites such as Bitbucket, GitHub, Google Project Hosting and Launchpad, as well as peer platforms such as GitLab and Gitea.

Related to https://github.com/golang/gddo/issues/538

coolaj86 avatar Sep 03 '18 22:09 coolaj86

I wonder ... does it support any git provider site? For example I am using https://git.sr.ht , however it can't seem to find this https://godoc.org/?q=git.sr.ht%2F%7Ebiosmarcel%2Fanimaid%2Fanimaid

Bios-Marcel avatar Nov 30 '18 20:11 Bios-Marcel

Struggling with the same issue, but with my own go get-able site that godoc.org doesn't recognize. The import path is import "go.azarus.ch/fuelconv"

refacto avatar Mar 19 '19 10:03 refacto

Looks like the pattern in the gddo/gosrc.service for generic VCS is insufficient. The regexp is pretty strict and only allows A-Za-z0-9_.\-/, but the spec allows for most unicode characters except !"#$%&'()*,:;<=>?[\]^`{|}.

That being said, the two examples you gave are for git.sr.ht and hg.sr.ht, both of which suffer from go-get issues and fail for other reasons:

  • https://todo.sr.ht/~sircmpwn/hg.sr.ht/11
  • https://todo.sr.ht/~sircmpwn/git.sr.ht/130

Do you have an example git.sr.ht repo that I can test with that contains go code at the root? (e.g. git.sr.ht/~user/pkg)

urandom2 avatar Mar 20 '19 10:03 urandom2

Here: https://git.sr.ht/~biosmarcel/animaid or https://git.sr.ht/~biosmarcel/go-webclock (this actually has no exported symbols, probably useless)

Bios-Marcel avatar Mar 20 '19 10:03 Bios-Marcel

Hi Colin,

Here's an hg repo: https://hg.sr.ht/~azarus/fuelconv

I'll mirror it under https://git.sr.ht/~azarus/gfuelconv in a minute.

refacto avatar Mar 20 '19 12:03 refacto

yeah, adding the tilde char will unblock these go get-able repos:

https://go-review.googlesource.com/c/gddo/+/168065 image

I think there is a larger discussion to be had about the long term fix, since this regexp does not follow the spec, but that is for the repo maintainers.

urandom2 avatar Mar 21 '19 05:03 urandom2

If gddo is going to run a command like git or svn to fetch the source code, wouldn't it be simpler to just run go get?

dncohen avatar May 16 '19 09:05 dncohen