Add basic init classes of gerrit-pgm again to plugin api
Since the tentative switch to Buck, plugins could no longer hook into gerrit's init procedure, as the plugin api no longer exposed the required classes. We re-add the required classes to make hooks-its compile against the plugin api. Change-Id: I0da8089c718f4a3c246ccc34cc45ae2f6b7d1aab
This commit is contained in:
committed by
Shawn Pearce
parent
3918177c6b
commit
4c67736d8b
1
BUCK
1
BUCK
@@ -48,6 +48,7 @@ genrule(
|
||||
|
||||
PLUGIN_API = [
|
||||
'//gerrit-server:server',
|
||||
'//gerrit-pgm:init-api',
|
||||
'//gerrit-sshd:sshd',
|
||||
'//gerrit-httpd:httpd',
|
||||
]
|
||||
|
||||
@@ -1,8 +1,38 @@
|
||||
INIT_SRCS = ['src/main/java/com/google/gerrit/pgm/' + n for n in [
|
||||
'init/InitFlags.java',
|
||||
'init/InitStep.java',
|
||||
'init/InitStep.java',
|
||||
'init/InstallPlugins.java',
|
||||
'init/Section.java',
|
||||
'util/ConsoleUI.java',
|
||||
'util/Die.java',
|
||||
]]
|
||||
|
||||
java_library(
|
||||
name = 'init-api',
|
||||
srcs = INIT_SRCS,
|
||||
deps = [
|
||||
'//gerrit-server:server',
|
||||
'//lib:jsr305',
|
||||
'//lib/guice:guice',
|
||||
'//lib/guice:guice-assistedinject',
|
||||
'//lib/jgit:jgit',
|
||||
],
|
||||
visibility = ['PUBLIC'],
|
||||
)
|
||||
|
||||
java_sources(
|
||||
name = 'init-api-src',
|
||||
srcs = INIT_SRCS,
|
||||
visibility = ['PUBLIC'],
|
||||
)
|
||||
|
||||
java_library2(
|
||||
name = 'pgm',
|
||||
srcs = glob(['src/main/java/**/*.java']),
|
||||
srcs = glob(['src/main/java/**/*.java'], excludes = INIT_SRCS),
|
||||
resources = glob(['src/main/resources/**/*']),
|
||||
deps = [
|
||||
':init-api',
|
||||
'//gerrit-cache-h2:cache-h2',
|
||||
'//gerrit-common:server',
|
||||
'//gerrit-extension-api:api',
|
||||
|
||||
Reference in New Issue
Block a user