aboutsummaryrefslogtreecommitdiff
path: root/archlinux
diff options
context:
space:
mode:
authorGrégoire Duchêne <gduchene@awhk.org>2022-06-19 13:31:49 +0100
committerGrégoire Duchêne <gduchene@awhk.org>2022-06-19 13:40:39 +0100
commit41d23c22df853b0bdf35e2d0988c8d4c4281d42f (patch)
tree48ddc49039d6ceded97914374171157515b004be /archlinux
parent21456154ef3172490cef72a3b69bf59bb9795e43 (diff)
Move redirection logic to a separate packagev0.4.0
Also, add an optional ‘-c’ flag to pass the path to a configuration file that can be used to specify several matching patterns and replacements.
Diffstat (limited to 'archlinux')
-rw-r--r--archlinux/PKGBUILD1
-rw-r--r--archlinux/go-import-redirect.conf5
2 files changed, 6 insertions, 0 deletions
diff --git a/archlinux/PKGBUILD b/archlinux/PKGBUILD
index fc5bb65..096d272 100644
--- a/archlinux/PKGBUILD
+++ b/archlinux/PKGBUILD
@@ -24,5 +24,6 @@ package() {
install -Dm644 systemd/${pkgname}.service ${pkgdir}/usr/lib/systemd/system/${pkgname}.service
install -Dm644 systemd/${pkgname}.socket ${pkgdir}/usr/lib/systemd/system/${pkgname}.socket
install -Dm644 README.md ${pkgdir}/usr/share/doc/${pkgname}/README.md
+ install -Dm644 archlinux/${pkgname}.conf ${pkgdir}/usr/share/doc/${pkgname}/examples/${pkgname}.conf
install -Dm644 LICENSE ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
}
diff --git a/archlinux/go-import-redirect.conf b/archlinux/go-import-redirect.conf
new file mode 100644
index 0000000..6bb195a
--- /dev/null
+++ b/archlinux/go-import-redirect.conf
@@ -0,0 +1,5 @@
+[{
+ "pattern": "go\\.example\\.com/(.+)",
+ "replacement": "https://git.example.com/$1",
+ "vcs": "git"
+}]