Add --author-name and --author-email support for gbs import
authorZhang Qiang <qiang.z.zhang@intel.com>
Sat, 31 Mar 2012 06:13:45 +0000 (14:13 +0800)
committerZhang Qiang <qiang.z.zhang@intel.com>
Sat, 31 Mar 2012 06:13:45 +0000 (14:13 +0800)
gitbuildsys/cmd_import.py
gitbuildsys/cmd_import_orig.py

index 4c6e3c4..231f1d7 100644 (file)
@@ -44,6 +44,11 @@ def do(opts, args):
     if not os.path.exists(tmpdir):
         os.makedirs(tmpdir)
 
+    if opts.author_name:
+        COMM_NAME = opts.author_name
+    if opts.author_email:
+        COMM_EMAIL = opts.author_email
+
     specfile = None
     if len(args) < 1:
         msger.error('missing argument, please reference gbs import --help.')
index 0a9a327..89e1315 100644 (file)
@@ -62,6 +62,11 @@ def do(opts, args):
                     'the tarball.  The format of tarball name should be '
                     'name-version-tizen.<ext> or name-version.<ext>')
 
+    if opts.author_name:
+        COMM_NAME = opts.author_name
+    if opts.author_email:
+        COMM_EMAIL = opts.author_email
+
     try:
         msger.info('unpack upstream tar ball ...')
         upstream.unpack(tardir)