all repos — gopkgs @ d378084c72c2d3b7b198838357b17f279e506453

Go module vanity import paths

show badges from pkg.go.dev

Alan Pearce
commit

d378084c72c2d3b7b198838357b17f279e506453

parent

b70c509077939606bb065917d62ed7e1bd683de6

1 file changed, 4 insertions(+), 0 deletions(-)

changed files
M main.gomain.go
@@ -69,6 +69,10 @@ func godocURL(config *Config, pkg string) string {
return must(url.JoinPath("https://pkg.go.dev", packageImportPath(config, pkg))) } +func badgeURL(config *Config, pkg string) string { + return must(url.JoinPath("https://pkg.go.dev/badge/", packageImportPath(config, pkg))) +} + func packageImportPath(config *Config, pkg string) string { return config.Domain.JoinPath(pkg).String() }