1. mdelagra
  2. mercurial-reviewboard

Commits

mdelagra  committed 9587ef8

incrementing version number to 3.0, review changes will no longer be published automatically

  • Participants
  • Parent commits 2d3cd6a
  • Branches default

Comments (0)

Files changed (3)

File CHANGELOG

View file
  • Ignore whitespace
+Version 3.0.0 (TBD)
+
+    * updates to existing reviews will no longer publish automatically
+    
+    use the -p flag to publish a review change immediately
+
 Version 2.1.0 (11/19/09)
 
     * merged in latest changes from parent project

File mercurial_reviewboard/__init__.py

View file
  • Ignore whitespace
 
 from reviewboard import ReviewBoard, ReviewBoardError
 
-__version__ = '2.1.0'
+__version__ = '3.0.0'
 
 def postreview(ui, repo, rev='tip', **opts):
     '''post a changeset to a Review Board server
     reviewboard = getreviewboard(ui, opts)
     try:
         reviewboard.update_request(request_id, fields, diff, parentdiff)
+        if opts['publish']:
+            reviewboard.publish(request_id)
     except ReviewBoardError, msg:
         raise util.Abort(_(msg))
     

File mercurial_reviewboard/reviewboard.py

View file
  • Ignore whitespace
     def publish(self, id):
         self._api_post('api/json/reviewrequests/%s/publish/' % id)
 
-    def _save_draft(self, id):
-        rsp = self._api_post("/api/json/reviewrequests/%s/draft/save/" % id )
-
     def _api_post(self, url, fields=None, files=None):
         """
         Performs an API call using HTTP POST at the specified path.
         self._set_fields(id, fields)
         if diff:
             self._upload_diff(id, diff, parentdiff)
-        if fields or diff:
-            self._save_draft(id)