diff options
author | Jesse Keating <jkeating@redhat.com> | 2010-07-29 12:33:54 -0700 |
---|---|---|
committer | Jesse Keating <jkeating@redhat.com> | 2010-07-29 12:34:30 -0700 |
commit | cc4d89e57d19b1f569e890920f3d9fb90adf1df1 (patch) | |
tree | 8574d471b848c58c44ae5632f35dd33415b63633 /src | |
parent | f120061eb07471770245783a786b70b6dc90e9a0 (diff) | |
download | fedora-packager-cc4d89e57d19b1f569e890920f3d9fb90adf1df1.tar.gz fedora-packager-cc4d89e57d19b1f569e890920f3d9fb90adf1df1.tar.xz fedora-packager-cc4d89e57d19b1f569e890920f3d9fb90adf1df1.zip |
Make fedpkg clone -b f?? package work
Also works for el? and olpc?
Diffstat (limited to 'src')
-rw-r--r-- | src/pyfedpkg/__init__.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/pyfedpkg/__init__.py b/src/pyfedpkg/__init__.py index c956eec..992ca54 100644 --- a/src/pyfedpkg/__init__.py +++ b/src/pyfedpkg/__init__.py @@ -278,6 +278,12 @@ def clone(module, user, path=os.getcwd(), branch=None, bare_dir=None): else: giturl = ANONGITURL % {'module': module} + # do some branch name conversions + if branch: + remotere = 'f\d\d|el\d|olpc\d' + if re.match(remotere, branch): + branch = '%s/master' % branch + # Create the command cmd = ['git', 'clone'] # do the clone |