This extension provides a view of your Gerrit server.
When parts of the tree are updated they are displayed larger and brighter. Clicking items will reset them.
By default, the view is automatically refreshed every minute.
The extension assumes that Jenkins is being used for continuous integration.
Note: This was developed for use in my work place. If you find things don't work as expected, please raise an issue here and I'll try to help.
TODO: Provide access to the tree structure configuration.
Some elements of the tree have icons. A green tick indicates a passed build with a red cross indicating a failure. If the build is in progress, a timer indicator is shown.
Scores are shown with a green background for positive (+1, +2) and a red background for negative (-1, -2).
The view title bar contains the following buttons:
clears all changed items
show only changed items
show all items
filter the view based on the contents of one of the fields
clear the current filter
refresh the view
collapse the view
Change set nodes in the tree also have a context menu which allows the change set to be opened in a browser.
You can install the latest version of the extension via the Visual Studio Marketplace here.
Alternatively, open Visual Studio code, press Ctrl+P
or Cmd+P
and type:
> ext install gerrit-view
Note: Don't forget to reload the window to activate the extension!
You have to reload the window after installing to start displaying the
Go to the settings and select Gerrit View settings
The Server
field should be filled with just the dns name of the server (and not with http or ssh)
e.g:
If your server URL is https://gerrit.server.com
, just enter gerrit.server.com
in this field
The Port
should have a value of the port at which the Gerrit server is listening to.
This can be got from the SSH clone command in any of the repos in Gerrit
e.g: if the clone command is
git clone "ssh://[email protected]:8282/REPOSITORY/NAME"
Here 8282
is the port. This should be entered in the Port
field in settings
The Path To Ssh Key
should have the private key (generally the id_rsa file in the ~/.ssh/ path) file in the machine to which you have connected to. Make sure the corresponding public key is added in the Gerrit server (else you will get authentication error)
The source code is available on GitHub here.
The default query is status:open
which will return open change sets from all projects and branches. To modify the query, use the Gerrit View: Set Query
command.
Setting | Default | Description |
---|---|---|
gerrit-view.server | Your Gerrit server hostname. | |
gerrit-view.port | 29418 | Port number for your Gerrit server. |
gerrit-view.username | (your username) | Username to sign in to your Gerrit server. |
gerrit-view.pathToSshKey | ".ssh/id_rsa" | Path to your ssh key. |
gerrit-view.queryBufferSize | 200 | Size of query buffer in kilobytes. Increase this if you expect lots of query results. |
gerrit-view.options | "--current-patch-set" | Query options. |
gerrit-view.query | "status:open" | Query for retrieving data. |
gerrit-view.debug | false | Create a debug channel in the Output view. |
gerrit-view.showInExplorer | true | Show the tree in the explorer view. |
gerrit-view.filterCaseSensitive | false | Set to true if you want the view filtering to be case sensitive. |
gerrit-view.autoRefresh | 60 | Automatically refresh the tree after this many seconds. Set to 0 to disable. |
Icon from wikipedia - attribution: By Original uploader was Leucosticte at MediaWiki - Transferred from MediaWiki, Public Domain, https://commons.wikimedia.org/w/index.php?curid=27361356
Building icon made by Bogdan Rosu from www.flaticon.com is licensed by CC 3.0 BY
Score icons license: Apache 2.0
Verfied/Failed icons license: http://creativecommons.org/licenses/by-sa/3.0/
Empty star icon made by Gregor Cresnar from www.flaticon.com is licensed by CC 3.0 BY
Closed star icon made by Revicon from www.flaticon.com is licensed by CC 3.0 BY