Merge branch 'stable-2.15' into stable-2.16

* stable-2.15:
  Remove unnecessary explicit loading of rules_python
  Remove unnecessary explicit loading of rules_proto
  Documentation: Clarify that gerrit.reportBugText only works in GWT
  Bazel: Move codemirror library import to cm.bzl

Also remove another explicit loading of rules_proto which was
accidentally introduced in an earlier merge commit.

Change-Id: I590aa9e9d1287d6b2dd2718e67d8eb9398043542
This commit is contained in:
David Pursehouse
2019-09-24 18:10:00 +09:00
4 changed files with 13 additions and 51 deletions

View File

@@ -2218,7 +2218,7 @@ should set this to the URL of their issue tracker, if necessary.
+
Text to be displayed in the link to the bug report URL.
+
Only used when `gerrit.reportBugUrl` is set.
Only used when `gerrit.reportBugUrl` is set and only supported in GWT (Old UI).
+
Defaults to "Report Bug".

View File

@@ -3,7 +3,6 @@ workspace(name = "gerrit")
load("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository")
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive", "http_file")
load("//tools/bzl:maven_jar.bzl", "GERRIT", "MAVEN_LOCAL", "maven_jar")
load("//lib/codemirror:cm.bzl", "CM_VERSION", "DIFF_MATCH_PATCH_VERSION")
load("//plugins:external_plugin_deps.bzl", "external_plugin_deps")
load("//tools:nongoogle.bzl", "declare_nongoogle_deps")
@@ -57,29 +56,6 @@ load("@bazelisk_version//:check.bzl", "check_bazel_version")
check_bazel_version()
# Protobuf rules support
http_archive(
name = "rules_proto",
sha256 = "602e7161d9195e50246177e7c55b2f39950a9cf7366f74ed5f22fd45750cd208",
strip_prefix = "rules_proto-97d8af4dc474595af3900dd85cb3a29ad28cc313",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/rules_proto/archive/97d8af4dc474595af3900dd85cb3a29ad28cc313.tar.gz",
"https://github.com/bazelbuild/rules_proto/archive/97d8af4dc474595af3900dd85cb3a29ad28cc313.tar.gz",
],
)
# Rules Python
http_archive(
name = "rules_python",
sha256 = "b5bab4c47e863e0fbb77df4a40c45ca85f98f5a2826939181585644c9f31b97b",
strip_prefix = "rules_python-9d68f24659e8ce8b736590ba1e4418af06ec2552",
urls = ["https://github.com/bazelbuild/rules_python/archive/9d68f24659e8ce8b736590ba1e4418af06ec2552.tar.gz"],
)
load("@rules_python//python:repositories.bzl", "py_repositories")
py_repositories()
load("@io_bazel_rules_closure//closure:repositories.bzl", "closure_repositories")
# Prevent redundant loading of dependencies.
@@ -93,6 +69,9 @@ closure_repositories(
omit_rules_cc = True,
)
# This has to be done after loading of rules_closure, because it loads rules_java
load("//lib/codemirror:cm.bzl", "CM_VERSION", "DIFF_MATCH_PATCH_VERSION")
# Golang support for PolyGerrit local dev server.
http_archive(
name = "io_bazel_rules_go",
@@ -119,17 +98,6 @@ load("@bazel_gazelle//:deps.bzl", "gazelle_dependencies", "go_repository")
gazelle_dependencies()
# Protobuf rules support
http_archive(
name = "rules_proto",
sha256 = "602e7161d9195e50246177e7c55b2f39950a9cf7366f74ed5f22fd45750cd208",
strip_prefix = "rules_proto-97d8af4dc474595af3900dd85cb3a29ad28cc313",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/rules_proto/archive/97d8af4dc474595af3900dd85cb3a29ad28cc313.tar.gz",
"https://github.com/bazelbuild/rules_proto/archive/97d8af4dc474595af3900dd85cb3a29ad28cc313.tar.gz",
],
)
# Dependencies for PolyGerrit local dev server.
go_repository(
name = "com_github_robfig_soy",

View File

@@ -1,4 +1,4 @@
load("@rules_java//java:defs.bzl", "java_import", "java_library")
load("@rules_java//java:defs.bzl", "java_library")
load("//lib/codemirror:cm.bzl", "pkg_cm")
# This library is only used to insert a license statement into
@@ -10,17 +10,3 @@ java_library(
)
pkg_cm()
LICENSE = "//lib:LICENSE-codemirror-original"
LICENSE_MINIFIED = "//lib:LICENSE-codemirror-minified"
[java_import(
name = "codemirror" + suffix,
data = [license],
jars = [":jar%s" % suffix],
visibility = ["//visibility:public"],
) for suffix, license in [
("", LICENSE),
("_r", LICENSE_MINIFIED),
]]

View File

@@ -1,3 +1,4 @@
load("@rules_java//java:defs.bzl", "java_import")
load("//tools/bzl:genrule2.bzl", "genrule2")
CM_CSS = [
@@ -366,3 +367,10 @@ def pkg_cm():
],
outs = ["codemirror%s.jar" % suffix],
)
java_import(
name = "codemirror" + suffix,
jars = [":jar%s" % suffix],
visibility = ["//visibility:public"],
data = [license],
)