summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMauricio Pasquier Juan <mauricio@pasquierjuan.com.ar>2013-09-10 21:22:46 -0300
committerMauricio Pasquier Juan <mauricio@pasquierjuan.com.ar>2013-09-10 21:22:46 -0300
commite9fccc7c9374c0129159282f0c7f4619a390e8a2 (patch)
tree03d362a6385f5ba53dc83be73405bf3354593f05
parent6f362119e111a95d8a1356656b8d4e5527adf8c7 (diff)
command to delete repositories
-rwxr-xr-xgit-shell-commands/delete-repo13
1 files changed, 13 insertions, 0 deletions
diff --git a/git-shell-commands/delete-repo b/git-shell-commands/delete-repo
new file mode 100755
index 0000000..8349308
--- /dev/null
+++ b/git-shell-commands/delete-repo
@@ -0,0 +1,13 @@
+#!/bin/sh
+# * delete-repo
+# Allows users to delete repositories permanently
+# ssh git@host delete-repo repo1 repo2 ...
+
+set -e
+
+for i in $@; do
+ if [ -z "$repo" ]; then continue; fi
+
+ # lo and behold absolute horror
+ rm -rf "$repo".git
+done