Gerrit plugin to modify clone URL

148 views
Skip to first unread message

WekTorALL

unread,
Jul 7, 2016, 8:37:06 AM7/7/16
to Repo and Gerrit Discussion
Hi!

I want to generate specific clone URL for each Gerrit project, because I have hooks that should run only for some projects... Is there any way to modify clone URL from Gerrit Web UI with a plugin? 
If yes, could you give me some hints please? I can`t get nothing really usefull in plugin developement docs...
If no, do you know any other posibilities for doing this?... 

Thank`s

Edwin Kempin

unread,
Jul 7, 2016, 11:32:44 AM7/7/16
to WekTorALL, Repo and Gerrit Discussion
Your plugin can add clone commands as described in

An example can be found in the download-commands plugin:

Project-specific download commands are more tricky, but I once wrote a POC for this, see project-download-commands plugin:

But not sure if it's still working... it wasn't touched for a long time.

 

Thank`s

--
--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


WekTorALL

unread,
Jul 8, 2016, 8:14:22 AM7/8/16
to Repo and Gerrit Discussion, wekt...@gmail.com
Thank you for your reply!
As far as I see, com.google.gerrit.extensions.config.CloneCommand interface  is available only in Gerrit 2.12 and later. I want to create a plugin for Gerrit 2.11.7, because we use this version. Is there eny way to use this interface in 2.11.7?

Edwin Kempin

unread,
Jul 8, 2016, 8:18:11 AM7/8/16
to WekTorALL, Repo and Gerrit Discussion
On Fri, Jul 8, 2016 at 2:14 PM, WekTorALL <wekt...@gmail.com> wrote:
Thank you for your reply!
As far as I see, com.google.gerrit.extensions.config.CloneCommand interface  is available only in Gerrit 2.12 and later. I want to create a plugin for Gerrit 2.11.7, because we use this version. Is there eny way to use this interface in 2.11.7?
IIRC in 2.11 the clone command was based on the CheckoutCommand, but I'm not sure if that helps you.
Reply all
Reply to author
Forward
0 new messages