summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRay Strode <rstrode@redhat.com>2016-12-07 18:15:46 +0000
committerRay Strode <rstrode@redhat.com>2016-12-07 18:15:46 +0000
commit9316a1a3e6a0ea3ba42cf86bb843ac9933dafc1b (patch)
tree20f4813cd0fd6fa3f4d631647eb5c2e50e5abdb7
parente7c0cb2adaeee0cdc576595c47e3d8dd8eb9d71c (diff)
sync-github-mirror: strip off .git part of non-bare repos
we're ending up with bin- instead of bin getting synced to github
-rwxr-xr-xsync-github-mirror3
1 files changed, 3 insertions, 0 deletions
diff --git a/sync-github-mirror b/sync-github-mirror
index 9222f50..9b0bcd5 100755
--- a/sync-github-mirror
+++ b/sync-github-mirror
@@ -116,6 +116,9 @@ def get_repo_name ():
elif repo_namespace and repo_parts[1] == repo_namespace:
repo_parts.remove(repo_parts[1])
+ if repo_parts[-1] == ".git":
+ repo_parts = repo_parts[:-1]
+
repo_name = "-".join(repo_parts)
if repo_name.endswith(".git"):