From 4ade859c4cb6d1cdeef4e7f37d78c1cf3a1d9ac4 Mon Sep 17 00:00:00 2001
From: vg <vgm+dev@devys.org>
Date: Thu, 27 Jun 2019 15:17:44 +0200
Subject: update gitcmd to be compatible with ssh:// git clone urls

---
 gitcmd | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'gitcmd')

diff --git a/gitcmd b/gitcmd
index 32d3670..c2c5c0f 100755
--- a/gitcmd
+++ b/gitcmd
@@ -29,7 +29,7 @@ except FileNotFoundError:
 try:
     ssh_original_command = os.environ['SSH_ORIGINAL_COMMAND'].split()
     command = ssh_original_command[0]
-    repository = ssh_original_command[1].split('.git')[0].strip("'")
+    repository = ssh_original_command[1].split('.git')[0].strip("'").strip('/')
 except IndexError:
     if command == 'ls':
         lsexit_repositories(repositories_ro, repositories_rw)
-- 
cgit v1.2.3