summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xgit-import-orig3
1 files changed, 2 insertions, 1 deletions
diff --git a/git-import-orig b/git-import-orig
index 0d0d3a65..ad558549 100755
--- a/git-import-orig
+++ b/git-import-orig
@@ -175,7 +175,8 @@ on howto create it otherwise use --upstream-branch to specify it.
import_upstream_tree(repo, orig_dir, version, options.filters, verbose=not is_empty)
if options.pristine_tar:
- gbpc.PristineTar().commit(archive, options.upstream_branch)
+ upstream_branch = [ options.upstream_branch, 'master' ][is_empty]
+ gbpc.PristineTar().commit(archive, upstream_branch)
gbpc.GitTag(options.sign_tags, options.keyid)(build_tag(options.upstream_tag, version),
msg="Upstream version %s" % version)