My favorites | Sign in
Project Home Downloads Wiki Issues Source
New issue   Search
for
  Advanced search   Search tips   Subscriptions
Issue 602: Upload code-review comments over ssh
28 people starred this issue and may be notified of changes. Back to list
Status:  Submitted
Owner:  conl...@google.com
Closed:  Jul 28


Sign in to add a comment
 
Project Member Reported by bklarson@gmail.com, Jun 18, 2010
My script to give negative reviews to changes with improper commit messages[1] is working well.  As a next step, I'd like to pass changes through a tool like checkstyle[2] to verify that they meet my company's coding standards.

It'd be nice if the script could put in-line comments for where it finds problems (this line has tabs, spacing is incorrect here, etc).  Is this currently only possible with json?  I can probably make that work, is there any documentation?  If not, where can I find more about the format?  I can upload some documentation.

Doing this over ssh would be preferable, but I'm not sure about the interface.  Putting all the comments on the command line worries me.  Escaping the strings correctly is a huge pain, as I found in [1].

[1] https://review.source.android.com//#change,15177
[2] http://checkstyle.sourceforge.net/

Jun 18, 2010
#1 sop@google.com
Maybe we should teach the review command a new --json-input
flag, that if passed causes it to read a structured JSON
object from stdin.  Then you can feed it your high level
commands and line-level comments in JSON:

  {message: "Seems OK",
   verified: "+1",
   comments: [
     {file: "src/README",
      line: 5,
      message: "Spelling error"},
     {file: "src/Makefile",
      line: 70,
      message: "warning: Don't use /bin/sh, use $(SHELL)"}
   ]}


Status: Accepted
Jun 18, 2010
Project Member #2 bklarson@gmail.com
+1, lgtm.  Would we deprecate the message and review score options from review command?  If not, do we need to handle duplicate/conflicting options?
Jun 18, 2010
#3 sop@google.com
No, I wouldn't deprecate the command line options.

So we'd need to have a check in the command that
makes sure you don't use the existing options at
the same time as this new --json-input option.
Feb 22, 2012
#4 sop@google.com
 Issue 1269  has been merged into this issue.
Feb 22, 2012
#5 sop@google.com
(No comment was entered for this change.)
Owner: conl...@google.com
Mar 7, 2013
#6 dal...@meetme.com
Is this being actively worked on?
Mar 7, 2013
Project Member #7 edwin.ke...@gmail.com
Not sure about ssh, but with latest Gerrit master there is a REST API that allows to upload comments via http [1].

[1] https://gerrit-review.googlesource.com/Documentation/rest-api-changes.html#set-review
Jul 15, 2014
#8 mani.cha...@gmail.com
Link to change uploaded for this issue:
https://gerrit-review.googlesource.com/#/c/58266/
Jul 15, 2014
Project Member #9 David.Os...@gmail.com
(No comment was entered for this change.)
Status: ChangeUnderReview
Jul 28, 2014
#10 sop@google.com
(No comment was entered for this change.)
Status: Submitted
Labels: FixedIn-2.11
Sign in to add a comment

Powered by Google Project Hosting