summaryrefslogtreecommitdiffstats
path: root/mirror.psgi
diff options
context:
space:
mode:
Diffstat (limited to 'mirror.psgi')
-rw-r--r--mirror.psgi12
1 files changed, 12 insertions, 0 deletions
diff --git a/mirror.psgi b/mirror.psgi
new file mode 100644
index 0000000..90d02fa
--- /dev/null
+++ b/mirror.psgi
@@ -0,0 +1,12 @@
+#!/usr/bin/env perl
+use strict;
+use warnings;
+
+use Plack::Request;
+
+sub {
+ my $req = Plack::Request->new($_[0]);
+ system("git fetch --prune --tags");
+ system("git push --mirror");
+ return [200, ['Content-Type' => 'text/plain'], ['']];
+};