summaryrefslogtreecommitdiff
path: root/debian/patches/allow-dashes-in-repository-names.patch
diff options
context:
space:
mode:
Diffstat (limited to 'debian/patches/allow-dashes-in-repository-names.patch')
-rw-r--r--debian/patches/allow-dashes-in-repository-names.patch13
1 files changed, 13 insertions, 0 deletions
diff --git a/debian/patches/allow-dashes-in-repository-names.patch b/debian/patches/allow-dashes-in-repository-names.patch
new file mode 100644
index 0000000..9fe5994
--- /dev/null
+++ b/debian/patches/allow-dashes-in-repository-names.patch
@@ -0,0 +1,13 @@
+This allows '-' for package names
+see: https://github.com/xiam/vanity/pull/6
+--- a/main.go
++++ b/main.go
+@@ -24,7 +24,7 @@
+ repoRootFlag = flag.String("repo-root", "", "Git repository root URL (e.g.: https://github.com/upper).")
+ )
+
+-var packagePattern = regexp.MustCompile(`^/([a-zA-Z0-9]+)\.?(v[1-9][0-9]*)?(.*)$`)
++var packagePattern = regexp.MustCompile(`^/([-a-zA-Z0-9]+)\.?(v[1-9][0-9]*)?(.*)$`)
+
+ var httpClient = &http.Client{Timeout: 10 * time.Second}
+