summaryrefslogtreecommitdiffstats
path: root/src/pyfedpkg
diff options
context:
space:
mode:
Diffstat (limited to 'src/pyfedpkg')
-rw-r--r--src/pyfedpkg/__init__.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/pyfedpkg/__init__.py b/src/pyfedpkg/__init__.py
index 2fd1e6f..61991e2 100644
--- a/src/pyfedpkg/__init__.py
+++ b/src/pyfedpkg/__init__.py
@@ -270,7 +270,11 @@ def clone(module, user, path=os.getcwd(), branch=None, bare_dir=None):
"""
# construct the git url
- giturl = GITBASEURL % {'user': user, 'module': module}
+ if user:
+ giturl = GITBASEURL % {'user': user, 'module': module}
+ else:
+ giturl = ANONGITURL % {'module': module}
+
# Create the command
cmd = ['git', 'clone']
# do the clone