aboutsummaryrefslogtreecommitdiffhomepage
path: root/gbp/scripts/import_orig.py
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2017-04-04 07:12:38 +0200
committerGuido Günther <agx@sigxcpu.org>2017-04-12 10:42:51 +0200
commit7cfe71d6d45399ded9b50209a2c0dcbf132afd3d (patch)
tree6ca85c89ef8724440e0192642dce94751b22e8fa /gbp/scripts/import_orig.py
parent5d414c1a2a09fa0499bca25f4b829c51c94dbf44 (diff)
import_orig: move merge function closer next to each other
Gbp-Dch: Ignore
Diffstat (limited to 'gbp/scripts/import_orig.py')
-rw-r--r--gbp/scripts/import_orig.py22
1 files changed, 11 insertions, 11 deletions
diff --git a/gbp/scripts/import_orig.py b/gbp/scripts/import_orig.py
index 5df4d7b0..61ad7a26 100644
--- a/gbp/scripts/import_orig.py
+++ b/gbp/scripts/import_orig.py
@@ -364,6 +364,17 @@ def debian_branch_merge_by_replace(repo, tag, version, options):
repo.force_head(commit, hard=True)
+def debian_branch_merge_by_merge(repo, tag, version, options):
+ gbp.log.info("Merging to '%s'" % options.debian_branch)
+ branch = repo.get_branch()
+ repo.set_branch(options.debian_branch)
+ try:
+ repo.merge(tag)
+ except GitRepositoryError:
+ raise GbpError("Automatic merge failed.")
+ repo.set_branch(branch)
+
+
def get_component_tarballs(name, version, tarball, components):
"""
Figure out the paths to the component tarballs based on the main
@@ -383,17 +394,6 @@ def get_component_tarballs(name, version, tarball, components):
return tarballs
-def debian_branch_merge_by_merge(repo, tag, version, options):
- gbp.log.info("Merging to '%s'" % options.debian_branch)
- branch = repo.get_branch()
- repo.set_branch(options.debian_branch)
- try:
- repo.merge(tag)
- except GitRepositoryError:
- raise GbpError("Automatic merge failed.")
- repo.set_branch(branch)
-
-
def set_bare_repo_options(options):
"""Modify options for import into a bare repository"""
if options.pristine_tar or options.merge: