summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/pyfedpkg/__init__.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/pyfedpkg/__init__.py b/src/pyfedpkg/__init__.py
index 075608c..5c48d67 100644
--- a/src/pyfedpkg/__init__.py
+++ b/src/pyfedpkg/__init__.py
@@ -11,7 +11,7 @@
import os
import shutil
-#import pycurl
+import re
import subprocess
import hashlib
import koji
@@ -25,6 +25,7 @@ LOOKASIDE = 'http://cvs.fedoraproject.org/repo/pkgs'
LOOKASIDEHASH = 'md5'
GITBASEURL = 'ssh://%(user)s@pkgs.stg.fedoraproject.org/%(module)s'
ANONGITURL = 'git://pkgs.stg.fedoraproject.org/%(module)s'
+BRANCHFILTER = 'FC?-\d\d?|master'
# Define our own error class
class FedpkgError(Exception):
@@ -212,7 +213,8 @@ def clone_with_dirs(module, user, path=os.getcwd()):
repo_git = git.Git(repo_path)
# Get a branch listing
- branches = [x for x in repo_git.branch().split() if x != "*"]
+ branches = [x for x in repo_git.branch().split() if x != "*" and
+ re.match(BRANCHFILTER, x)]
for branch in branches:
try: