Gilles Moris  committed 8b9d9df

Add --target-people and --target-groups options.

To be able to set the reviewers from the command line.
Reviewers can be passed as a comma separated list or as a repetition
of the target option.

  • Participants
  • Parent commits 7e9bdb0
  • Branches default

Comments (0)

Files changed (1)

         parentdiff = ''
     for field in ('target_groups', 'target_people'):
-        value = ui.config('reviewboard', field)
+        if opts.get(field):
+            value = ','.join(opts.get(field))
+        else:
+            value = ui.config('reviewboard', field)
         if value:
             fields[field] = value
         ('e', 'existing', '', _('existing request ID to update')),
         ('u', 'update', False, _('update the fields of an existing request')),
         ('p', 'publish', None, _('publish request immediately')),
-        ('', 'parent', '', _('parent revision for the uploaded diff'))
+        ('', 'parent', '', _('parent revision for the uploaded diff')),
+        ('U', 'target_people', [], _('comma separated list of people needed to review the code')),
+        ('G', 'target_groups', [], _('comma separated list of groups needed to review the code')),
         _('hg postreview [OPTION]... [REVISION]')),