fixed github directory match pattern
The regexp "[a-z0-9A-Z_.\-/]" is strict , not match dir
with space(issue #293) or other special character.
change it to "[^/]" matching more directories in github repo URL.
fixed #293
diff --git a/gosrc/github.go b/gosrc/github.go
index b612346..181d938 100644
--- a/gosrc/github.go
+++ b/gosrc/github.go
@@ -18,7 +18,7 @@
func init() {
addService(&service{
- pattern: regexp.MustCompile(`^github\.com/(?P<owner>[a-z0-9A-Z_.\-]+)/(?P<repo>[a-z0-9A-Z_.\-]+)(?P<dir>/[a-z0-9A-Z_.\-/]*)?$`),
+ pattern: regexp.MustCompile(`^github\.com/(?P<owner>[a-z0-9A-Z_.\-]+)/(?P<repo>[a-z0-9A-Z_.\-]+)(?P<dir>/[^/]*)?$`),
prefix: "github.com/",
get: getGitHubDir,
getPresentation: getGitHubPresentation,