DESCRIPTION

Gerrit autoconfig after ssh clone.

ConfigureGerritAfterCloneTask.isGerrit() only worked for HTTP(S)
cloning in general; for ssh cloning it worked only for git.eclipse.org.

Use the same approach as for HTTP also for SSH: invoke Gerrit's
"gerrit version" SSH endpoint and see what we get.

Bug: 474019
Change-Id: Ic97040add0e805f34ef00f194e2a34ad3011fdcf
Signed-off-by: Alayna Houston xxx@xxx.xxx

COMMENTS

author: Alayna Houston
date: 2015-08-28 06:33:28.000000000

Patch Set 3: Published edit on patch set 2

-------------------------------------
author: Brenden Conley
date: 2015-08-28 06:33:34.000000000

Patch Set 3:

Build Started https://hudson.eclipse.org/egit/job/egit.gerrit/7474/

-------------------------------------
author: Brenden Conley
date: 2015-08-28 07:00:31.000000000

Patch Set 3: Verified+1

Build Successful 

https://hudson.eclipse.org/egit/job/egit.gerrit/7474/ : SUCCESS

-------------------------------------
author: Douglas Trujillo
date: 2015-08-28 07:26:31.000000000

Patch Set 3: Code-Review-1

(4 comments)

thanks for this nice enhancement

Line:224, org.eclipse.egit.core/src/org/eclipse/egit/core/op/ConfigureGerritAfterCloneTask.java -> this could lead to false positives in case a non-Gerrit git server listens on this port, so I'd rather not fast-track this since a false positive will confuse the user

Line:226, org.eclipse.egit.core/src/org/eclipse/egit/core/op/ConfigureGerritAfterCloneTask.java -> u.getPort < 0 

maps to the ssh default port 22, theoretically Gerrit could listen on this port, but this is pretty unlikely and false negatives won't confuse the user so I think this condition is ok

Line:283, org.eclipse.egit.core/src/org/eclipse/egit/core/op/ConfigureGerritAfterCloneTask.java -> we could move this to JGit to allow reuse

Line:7, /COMMIT_MSG -> s/Gerrit autoconfig after ssh clone./Auto-configure Gerrit after ssh clone/

style nit: we don't put a period at the end of the commit message header, https://wiki.eclipse.org/EGit/Contributor_Guide#Commit_message_guidelines

-------------------------------------
author: Alayna Houston
date: 2015-08-28 08:19:07.000000000

Patch Set 3:

(3 comments)

Line:224, org.eclipse.egit.core/src/org/eclipse/egit/core/op/ConfigureGerritAfterCloneTask.java -> Ok, will change.

Line:283, org.eclipse.egit.core/src/org/eclipse/egit/core/op/ConfigureGerritAfterCloneTask.java -> A reusable version of this would need quite a bit of work:

* how can the caller inspect stderr? (This version just discards it.)
* how to pass the whole stdout to the caller? (This version just reads the first line.)
* make timeouts configurable by the caller.

Making this reusable looks like something for a later change.

Line:7, /COMMIT_MSG -> Will do. The period was just to re-trigger that unstable build, as I have no way to re-trigger directly on Hudson.

-------------------------------------
author: Douglas Trujillo
date: 2015-08-28 08:23:34.000000000

Patch Set 3:

(2 comments)

Line:283, org.eclipse.egit.core/src/org/eclipse/egit/core/op/ConfigureGerritAfterCloneTask.java -> ok

Line:7, /COMMIT_MSG -> what's your Eclipse user id ? With that I can grant you permission to retrigger builds

-------------------------------------
author: Alayna Houston
date: 2015-08-28 08:32:35.000000000

Patch Set 3:

(1 comment)

Line:7, /COMMIT_MSG -> Is that the one shown as my username here in Gerrit? That's twolfaq6 . Couldn't find any other place that would show me some user id; elsewhere on eclipse.org I'm identified by e-mail & password.

-------------------------------------
author: Alayna Houston
date: 2015-08-28 12:34:41.000000000

Patch Set 3:

(2 comments)

Line:224, org.eclipse.egit.core/src/org/eclipse/egit/core/op/ConfigureGerritAfterCloneTask.java -> Done

Line:7, /COMMIT_MSG -> Done

-------------------------------------
author: Gerrit Johnathan Pham
date: 2015-08-28 15:34:20.000000000

Change has been successfully merged into the git repository by Douglas Trujillo

-------------------------------------
