Plugins can register ReceivePackInitializer's in order to provide custom
initialization of the ReceivePack instance. For example, the quota plugin
may use this extension point to set the maximum allowed pack size based
on its quota configuration and the disk space occupied by that project.
Change-Id: I8d6e7d4bb75099b0fa5f6968ae5371883bf865ee
Add a method to the JavaScript API to open the Gerrit ErrorDialog with
a given message. Plugins don't want to reimplement the ErrorDialog.
Change-Id: Iec18fb873bfbe9f47684414aacbaf697076d315f
Signed-off-by: Edwin Kempin <edwin.kempin@sap.com>
* changes:
notedb: Use Patch-set instead of Patch-Set
SubmitRecord: Add equals and hashCode methods
Support multiple ChangeUpdate operations in a batch
Inject MetaDataUpdate/ChangeUpdate in ChangeNotesTest
This is a simpler approach as it doesn't require generating extra test
targets for Buck, nor rebuilding test jars to get everything working
in Eclipse. There are enough tests running at any given time with Buck
that having each acceptance test take twice as long should maintain
adequate parallelism.
Change-Id: I109acaf6b957e8f9dd621e98abe46a75f78cdc32
It will be possible in the future for a single end-user action to
cause the server to make modifications to a change on behalf of
someone not the immediate end user, e.g. normalizing labels on submit.
To represent this, we would have multiple commits in a single update
with different authors. For consistency, use the server identity for
all resultant committers.
Change-Id: I6930d1da3125b724af53514549a9408086bbb7fd
To get the following fixes and updates:
- Change default push refSpec to 'refs/*:refs/*' (non-forced push)
- Allow default force update to be configurable
- Correct misspelled method name
Change-Id: Ic734a7290a303562e42b11a0b64697a0fcbc1d71
Explicitly mention checkout, pull, and cherry-pick in the intro to the
new change screen to make it easier for people used to the old change
screen to find their new location.
Change-Id: I1cc687624a6b6486ae899e16612727e07b338ee2
Old change screen had grey styled cells in approval table for labels a
reviewer hadn't right to vote on. The new change screen uses chips to
present the reviewers name and therefore this valuable information is lost.
Add it back in form of tooltip with the list of votable labels for each
reviewer.
Bug: issue 2078
Change-Id: I0f101e43c625bfe1f181b46574c6677d930a5c19
If a RestCollection in a plugin implements AcceptsPost POST requests
for it currently fail with Not Found.
Change-Id: I6db50cbe08c5ec53dac727d90af58fbe4538dbcf
Signed-off-by: Edwin Kempin <edwin.kempin@sap.com>
Result of the operation is always an integer so the call to Math.round()
is redundant.
Change-Id: I19fe01b0d71241012ad9f2b5f5c11fabf2b216f5
Signed-off-by: Eryk Szymanski <eryksz@gmail.com>
GWT's class obfuscation makes it impossible for users to write their
own CSS that won't break on upgrade. This further helps preserve
class names so users can continue to rely on the names and use
GerritSite.css to its full ability.
Change-Id: I10acf06c150daebf9d74ba8ad101c9643392781a
We are now able to display a GWT screen when clicking on a menu item.
The GWT plugin archetype should create an example screen. So far it
was only showing a dialog.
Change-Id: I8b599542ae92e01195ce0402ae085615e86a1b62
Signed-off-by: Edwin Kempin <edwin.kempin@sap.com>
Plugins can have their global configuration in a plugin subsection of
the gerrit.config file. PluginConfigFactory provides easy access to
this global plugin configuration and ensures that the gerrit.config
file is not on any access loaded from the filesystem. The
GerritServerConfig is injected into the PluginConfigFactory
so that updates of the gerrit.config file only get visible in
PluginConfigFactory after the server has been restarted.
Plugins may want to provide ways to live update their global
configuration, e.g. they could provide a REST endpoint to update
their plugin section in gerrit.config. To make the changes visible
in PluginConfigFactory the cached GerritServerConfig in it needs
to be reloaded. For this purpose this change adds a refresh flag
to the method in PluginConfigFactory that reads the global plugin
config. The GerritServerConfig is then reloaded when it is was
changed in the filesystem.
Change-Id: Ide6b1457bfe5a63459e816ca9e00604a62da8365
Signed-off-by: Edwin Kempin <edwin.kempin@sap.com>
Draft workflow breaks replication and some sites might want to disable it
for all projects. While it is already possible to block new draft changes
from be uploaded, it is still possible to delete existing drafts.
This change disable draft workflow completely.
Change-Id: Iabae835a26caab5ea4c10701c75c9b0b84882f86
The Maven plugin archetypes are used to create new plugin projects.
The files generated for these new plugin projects should have the
correct year in the license headers.
Change-Id: I86919f19191089e83ba9111d86a29d2798b75feb
Signed-off-by: Edwin Kempin <edwin.kempin@sap.com>
For project plugin configuration parameter it is now possible to
provide a warning. If set this warning is shown as a tooltip on a
warning icon that is displayed for the project plugin configuration
parameter on the ProjectInfoScreen.
E.g. a warning could be displayed when a configuration parameter is
not editable to explain why this parameter cannot be edited. For
example the Jira plugin allows to enabled/disabled the Jira
integration for a project from the ProjectInfoScreen. This parameter
is not editable if the Jira integration is enforced by a parent
project. In this case it makes sense to display a message which says
that the Jira integration cannot be disabled for this project because
the Jira integration is enforced by parent project X.
The warning icon is taken from the Tango Icon Library [1].
[1] http://tango.freedesktop.org/Tango_Icon_Library
Change-Id: I15d1bec7eaceced487c22202b2514b09dc7c50f8
Signed-off-by: Edwin Kempin <edwin.kempin@sap.com>
CM3 needs a call to refresh() after setHeight to get the horizontal
width correct for any lines longer than the window width.
Bug: Issue 2428
Change-Id: I608264d71c98829c2f39d9acef12445088591bbb
Ctrl-C/Cmd-C should be copy to clipboard and should not activate the
insert new comment feature of Gerrit. Bind to the C key not 'c'.
This uses a different binding method inside of CM3 allowing the
browser to still handle Ctrl-C/Cmd-C.
Bug: issue 2416
Change-Id: Iad6d4e8502c1766caf1cc897f1398068bbde7155