Merge "Add gitiles as core plugin"

This commit is contained in:
Luca Milanesio 2019-01-23 13:43:00 +00:00 committed by Gerrit Code Review
commit 3797361bbb
7 changed files with 151 additions and 10 deletions

5
.gitmodules vendored
View File

@ -18,6 +18,11 @@
url = ../plugins/download-commands
branch = .
[submodule "plugins/gitiles"]
path = plugins/gitiles
url = ../plugins/gitiles
branch = .
[submodule "plugins/hooks"]
path = plugins/hooks
url = ../plugins/hooks

View File

@ -86,6 +86,14 @@ Documentation] |
link:https://gerrit.googlesource.com/plugins/download-commands/+doc/master/src/main/resources/Documentation/config.md[
Configuration]
[[gitiles]]
=== gitiles
Plugin running Gitiles alongside a Gerrit server.
link:https://gerrit-review.googlesource.com/admin/repos/plugins/gitiles[
Project]
[[hooks]]
=== hooks
@ -264,14 +272,6 @@ Plugin to integrate with GitHub: replication, pull-request to Change-Sets
link:https://gerrit-review.googlesource.com/admin/repos/plugins/github[
Project]
[[gitiles]]
=== gitiles
Plugin running Gitiles alongside a Gerrit server.
link:https://gerrit-review.googlesource.com/admin/repos/plugins/gitiles[
Project]
[[imagare]]
=== imagare

View File

@ -302,6 +302,12 @@ maven_jar(
sha1 = "6505a72a097d9270f7a9e7bf42c4238283247755",
)
maven_jar(
name = "commons-text",
artifact = "org.apache.commons:commons-text:1.2",
sha1 = "74acdec7237f576c4803fff0c1008ab8a3808b2b",
)
maven_jar(
name = "commons-dbcp",
artifact = "commons-dbcp:commons-dbcp:1.4",
@ -334,6 +340,33 @@ maven_jar(
sha1 = "959a0c62f9a5c2309e0ad0b0589c74d69e101241",
)
COMMONMARK_VERS = "0.10.0"
# commonmark must match the version used in Gitiles
maven_jar(
name = "commonmark",
artifact = "com.atlassian.commonmark:commonmark:" + COMMONMARK_VERS,
sha1 = "119cb7bedc3570d9ecb64ec69ab7686b5c20559b",
)
maven_jar(
name = "cm-autolink",
artifact = "com.atlassian.commonmark:commonmark-ext-autolink:" + COMMONMARK_VERS,
sha1 = "a6056a5efbd68f57d420bc51bbc54b28a5d3c56b",
)
maven_jar(
name = "gfm-strikethrough",
artifact = "com.atlassian.commonmark:commonmark-ext-gfm-strikethrough:" + COMMONMARK_VERS,
sha1 = "40837da951b421b545edddac57012e15fcc9e63c",
)
maven_jar(
name = "gfm-tables",
artifact = "com.atlassian.commonmark:commonmark-ext-gfm-tables:" + COMMONMARK_VERS,
sha1 = "c075db2a3301100cf70c7dced8ecf86b494458a2",
)
FLEXMARK_VERS = "0.34.18"
maven_jar(
@ -486,7 +519,7 @@ maven_jar(
sha1 = "31e2e1fbe8273d7c913506eafeb06b1a7badb062",
)
# Transitive dependency of flexmark
# Transitive dependency of flexmark and gitiles
maven_jar(
name = "autolink",
artifact = "org.nibor.autolink:autolink:0.7.0",
@ -669,14 +702,30 @@ maven_jar(
sha1 = "f7be08ec23c21485b9b5a1cf1654c2ec8c58168d",
)
GITILES_VERS = "0.2-7"
maven_jar(
name = "blame-cache",
artifact = "com/google/gitiles:blame-cache:0.2-7",
artifact = "com.google.gitiles:blame-cache:" + GITILES_VERS,
attach_source = False,
repository = GERRIT,
sha1 = "8170f33b8b1db6f55e41d7069fa050a4d102a62b",
)
maven_jar(
name = "gitiles-servlet",
artifact = "com.google.gitiles:gitiles-servlet:" + GITILES_VERS,
repository = GERRIT,
sha1 = "f23b22cb27fe5c4a78f761492082159d17873f57",
)
# prettify must match the version used in Gitiles
maven_jar(
name = "prettify",
artifact = "com.github.twalcari:java-prettify:1.2.2",
sha1 = "b8ba1c1eb8b2e45cfd465d01218c6060e887572e",
)
# Keep this version of Soy synchronized with the version used in Gitiles.
maven_jar(
name = "soy",

23
lib/LICENSE-commonmark Normal file
View File

@ -0,0 +1,23 @@
Copyright (c) 2015-2016, Atlassian Pty Ltd
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

62
lib/gitiles/BUILD Normal file
View File

@ -0,0 +1,62 @@
java_library(
name = "gitiles",
visibility = ["//visibility:public"],
exports = [
":cm-autolink",
":commonmark",
":commons-text",
":gfm-strikethrough",
":gfm-tables",
":gitiles-servlet",
":prettify",
],
)
java_library(
name = "cm-autolink",
data = ["//lib:LICENSE-commonmark"],
visibility = ["//visibility:public"],
exports = ["@cm-autolink//jar"],
)
java_library(
name = "commons-text",
data = ["//lib:LICENSE-Apache2.0"],
visibility = ["//visibility:public"],
exports = ["@commons-text//jar"],
)
java_library(
name = "commonmark",
data = ["//lib:LICENSE-commonmark"],
visibility = ["//visibility:public"],
exports = ["@commonmark//jar"],
)
java_library(
name = "gfm-strikethrough",
data = ["//lib:LICENSE-Apache2.0"],
visibility = ["//visibility:public"],
exports = ["@gfm-strikethrough//jar"],
)
java_library(
name = "gfm-tables",
data = ["//lib:LICENSE-Apache2.0"],
visibility = ["//visibility:public"],
exports = ["@gfm-tables//jar"],
)
java_library(
name = "gitiles-servlet",
data = ["//lib:LICENSE-Apache2.0"],
visibility = ["//visibility:public"],
exports = ["@gitiles-servlet//jar"],
)
java_library(
name = "prettify",
data = ["//lib:LICENSE-Apache2.0"],
visibility = ["//visibility:public"],
exports = ["@prettify//jar"],
)

1
plugins/gitiles Submodule

@ -0,0 +1 @@
Subproject commit 950225ed2c0ee4100ba1bdb3bc32e2e8725997de

View File

@ -3,6 +3,7 @@ CORE_PLUGINS = [
"commit-message-length-validator",
"delete-project",
"download-commands",
"gitiles",
"hooks",
"replication",
"reviewnotes",