Escape dollar sign in plugin manifest entries, to prevent that
it is interpreted by the shell and thus get removed.
Change-Id: Iefd8abdcd207cb985f8156c7e41c094c1aa12b27
* stable-2.8:
Update replication plugin
Enable creating new branch and push local new commits in one step.
Add Implementation-Vendor default manifest entry
Fix incompatibility between "Rebase if Necessary" and "copy*Score*"
Fix submit rule evaluation for non blocking labels
Set uploader to current user in "patchset-created" event upon rebasing
Guard against diff.mnemonicprefix in commit-msg hook
Conflicts:
gerrit-acceptance-tests/src/test/java/com/google/gerrit/acceptance/rest/change/BUCK
gerrit-extension-api/src/main/java/com/google/gerrit/extensions/api/changes/AddReviewerInput.java
gerrit-server/src/main/java/com/google/gerrit/server/change/ChangeJson.java
gerrit-server/src/main/java/com/google/gerrit/server/git/strategy/RebaseIfNecessary.java
Change-Id: Ie59a530fe2c0fe66244d010e01e3cdf41de150f0
In some cases it might be useful to be able to pass dependencies as non
transitive dependencies, that not included in final plugin binary.
Why? When plugin dependencies are needed in both bootstrap classpath and
in plugin then they must be put in $gerrit_path/lib dir. Having them in lib
and inside the plugin doesn't make much sense.
This change exposes compile_deps parameter to the gerrit_{plugin|extension}
methods. It is possible to create both versions of the plugin: with and without
dependencies.
gerrit_plugin(
name = 'javamelody',
srcs = glob(['src/main/java/**/*.java']),
resources = glob(['src/main/resources/**/*']),
manifest_entries = [
'Gerrit-PluginName: javamelody',
'Gerrit-Module: com.googlesource.gerrit.plugins.javamelody.Module',
'Gerrit-HttpModule: com.googlesource.gerrit.plugins.javamelody.HttpModule',
],
deps = [
'//plugins/javamelody/lib:javamelody',
'//plugins/javamelody/lib:jrobin',
],
)
gerrit_plugin(
name = 'javamelody-no-deps',
srcs = glob(['src/main/java/**/*.java']),
resources = glob(['src/main/resources/**/*']),
manifest_entries = [
'Gerrit-PluginName: javamelody',
'Gerrit-Module: com.googlesource.gerrit.plugins.javamelody.Module',
'Gerrit-HttpModule: com.googlesource.gerrit.plugins.javamelody.HttpModule',
],
compile_deps = [
'//plugins/javamelody/lib:javamelody',
'//plugins/javamelody/lib:jrobin',
],
)
Change-Id: Ia274dbeb18de8807f0ab1edf7144f12ff0d02d74
GWT only needs the rebind code for CSS and ServerLinker to be
precompiled as bytecode. Save build time by passing no source
files to the java_library() used by gwt_module().
For a full draft build of ui_safari this cuts the refresh time
down from 32.015s to 26.158s on my MacBook. Saving 6s on each
UI reload adds up during development.
The common annotations need to be provided as bytecode, avoiding
spurious warnings from GWT when there is a Java syntax error.
Change-Id: I37826498650c65c05303e7d4d1177d05781c56f6
Buck lacks a feature to set java source level and target level per project
base, i. e. in .buckconfig file under java section.
The only method that currently is supported and described in the
documentation is to pass custom levels to java_library and java_test methods.
That would work, but that approach would require to touch dozens of files.
Second approach could be to just patch system wide Buck with this patch[1].
However that is not really an option because in this case the increased
java source and target level applies on all projects and branches.
Particularly it is undesirable to build Gerrit 2.8 stable branch or other
projects that were migrated to Buck (e. g. JGit) with increased java source
and target level.
This change redefines the standard definitions of java_test() and
java_library() methods and increases the java source and target level in the
new defined functions. With the combination of "include = default.defs"
construct in .buildconfig file it is garanteed that all BUCK files first
"see" the redefined methods.
Disadvantage of the approach is that every time the original method
definitions are changed in upstream Buck (i. e. new paramters are introduced)
this patch must be changed too.
The best approach would be to extend Buck and enable definition of source and
target level per project base (in .buckconfig file).
[1] https://github.com/facebook/buck/pull/67
Change-Id: Ifaba1eb41e9ac2f033e704a75723f3595e1c1ee5
The plugin api moved into the gerrit-plugin-api package.
Change the reference created by gerrit_plugin() to match.
Change-Id: I390a22f512835847367ae2993a7a9bddf9d11b5c
buck build api
generates now javadocs.
buck build api_install
installs all plugin/extension related artifacts with javadocs in the
local Maven repository.
Change-Id: Ifa6a8eb469f388e16449576ff2bff01a5dce67dd
This changes extends gerrit_plugin function with additional gwt_module
parameters. When passed, GWT application is created. Assumtion is met,
that this application depends on gerrit-plugin-gwtui module.
With this change Gerrit GWT plugins can be build with Buck:
MODULE = 'com.googlesource.gerrit.plugins.cookbook.HelloForm'
gerrit_plugin(
name = 'cookbook-plugin',
srcs = glob(['src/main/java/**/*.java']),
resources = glob(['src/main/**/*']),
gwt_module = MODULE,
manifest_entries = [
'Gerrit-PluginName: cookbook',
'Gerrit-Module: com.googlesource.gerrit.plugins.cookbook.Module',
'Gerrit-HttpModule: com.googlesource.gerrit.plugins.cookbook.HttpModule',
'Gerrit-SshModule: com.googlesource.gerrit.plugins.cookbook.SshModule',
]
)
Change-Id: I4b131c7c2672675d99457651fcee63bf4f149c2f
$TMP, $DEPS, $SRCS, $OUT are no longer supplied by Buck in the
environment unless they appear in the command line. Pass $TMP
where it was assumed to be magically supplied. This allows steps
to continue to use buck-out/gen/ for temporary storage instead of
polluting the system /tmp.
Change-Id: Iea8380e5f93fa16ec77457eb76404832bde93a39
The build system used mixed names for essentially the same things.
Rename all DEFS files to *.defs matching the handful of other files
that are already using this convention.
Change-Id: I3269bd5db5d8d83f5e192ea910f19431c2a4a1cf