Merge branch 'stable-2.9'

* stable-2.9:
  Include gerrit.war in api_{install,deploy}

Change-Id: I5f9222d82ec252a3cc3ee00b7e5a0f1feec64d2b
This commit is contained in:
Jonathan Nieder 2014-05-01 13:48:51 -07:00
commit 13d776504b
5 changed files with 9 additions and 6 deletions

2
BUCK
View File

@ -5,7 +5,7 @@ gerrit_war(name = 'chrome', ui = 'ui_chrome')
gerrit_war(name = 'firefox', ui = 'ui_firefox')
gerrit_war(name = 'safari', ui = 'ui_safari')
gerrit_war(name = 'withdocs', docs = True)
gerrit_war(name = 'release', docs = True, context = ['//plugins:core.zip'])
gerrit_war(name = 'release', docs = True, context = ['//plugins:core.zip'], visibility = ['//tools/maven:'])
API_DEPS = [
'//gerrit-extension-api:extension-api',

View File

@ -136,13 +136,13 @@ project directories in `buck-out/gen`, here as example for plugin API:
buck-out/gen/gerrit-plugin-api/plugin-api-javadoc.jar
----
Install {extension,plugin,gwt}-api to the local maven repository:
Install {extension,plugin,gwt}-api and gerrit.war to the local maven repository:
----
buck build api_install
----
Deploy {extension,plugin,gwt}-api to the remote maven repository:
Deploy {extension,plugin,gwt}-api and gerrit.war to the remote maven repository:
----
buck build api_deploy

View File

@ -78,7 +78,7 @@ def war(
visibility = visibility,
)
def gerrit_war(name, ui = 'ui_optdbg', context = [], docs = False):
def gerrit_war(name, ui = 'ui_optdbg', context = [], docs = False, visibility = []):
war(
name = name,
libs = LIBS + ['//gerrit-war:version'],
@ -89,4 +89,5 @@ def gerrit_war(name, ui = 'ui_optdbg', context = [], docs = False):
'//gerrit-gwtui:' + ui + '.zip',
] + context,
docs = docs,
visibility = visibility,
)

View File

@ -22,6 +22,7 @@ maven_package(
'gerrit-plugin-api': '//gerrit-plugin-api:plugin-api-javadoc',
'gerrit-plugin-gwtui': '//gerrit-plugin-gwtui:gwtui-api-javadoc',
},
war = {'gerrit-war': '//:release'},
)
python_binary(

View File

@ -18,11 +18,12 @@ def maven_package(
url = None,
jar = {},
src = {},
doc = {}):
doc = {},
war = {}):
cmd = ['$(exe //tools/maven:mvn)', '-v', version, '-o', '$OUT']
dep = []
for type,d in [('jar', jar), ('java-source', src), ('javadoc', doc)]:
for type,d in [('jar', jar), ('java-source', src), ('javadoc', doc), ('war', war)]:
for a,t in d.iteritems():
cmd.append('-s %s:%s:$(location %s)' % (a,type,t))
dep.append(t)