Merge branch 'stable-2.15' into stable-2.16
* stable-2.15: Use bazelisk as first choice for api.sh ProjectConfig: Add method to read from repository Remove buck related entries from .gitignore Replace references to bazel-genfiles with bazel-bin Set version to 2.14.21-SNAPSHOT Change-Id: Ia6d9fe13f43e85514b6c5dce8cee1670d5dd8f12
This commit is contained in:
commit
8c9a473cb0
1
.gitignore
vendored
1
.gitignore
vendored
@ -10,7 +10,6 @@
|
||||
/.apt_generated
|
||||
/.apt_generated_tests
|
||||
/.bazel_path
|
||||
/.buckd
|
||||
/.classpath
|
||||
/.factorypath
|
||||
/.idea
|
||||
|
@ -69,7 +69,7 @@ bazel build plugins/<plugin-name>:<plugin-name>
|
||||
The output can be normally found in the following directory:
|
||||
|
||||
----
|
||||
bazel-genfiles/plugins/<plugin-name>/<plugin-name>.jar
|
||||
bazel-bin/plugins/<plugin-name>/<plugin-name>.jar
|
||||
----
|
||||
|
||||
Some plugins describe their build process in `src/main/resources/Documentation/build.md`
|
||||
|
@ -200,6 +200,14 @@ public class ProjectConfig extends VersionedMetaData implements ValidationError.
|
||||
return r;
|
||||
}
|
||||
|
||||
// TODO(dpursehouse): Add @UsedAt annotation
|
||||
public static ProjectConfig read(Repository repo, Project.NameKey name)
|
||||
throws IOException, ConfigInvalidException {
|
||||
ProjectConfig r = new ProjectConfig(name);
|
||||
r.load(repo);
|
||||
return r;
|
||||
}
|
||||
|
||||
public static CommentLinkInfoImpl buildCommentLink(Config cfg, String name, boolean allowRaw)
|
||||
throws IllegalArgumentException {
|
||||
String match = cfg.getString(COMMENTLINK, name, KEY_MATCH);
|
||||
|
@ -60,7 +60,13 @@ if [[ "${VERBOSE:-x}" != "x" ]]; then
|
||||
set -o xtrace
|
||||
fi
|
||||
|
||||
bazel build //tools/maven:gen_${command} "$@" || \
|
||||
{ echo "bazel failed to build gen_${command}. Use VERBOSE=1 for more info" ; exit 1 ; }
|
||||
if [[ `which bazelisk` ]]; then
|
||||
BAZEL_CMD=bazelisk
|
||||
else
|
||||
BAZEL_CMD=bazel
|
||||
fi
|
||||
|
||||
./bazel-genfiles/tools/maven/${command}.sh
|
||||
${BAZEL_CMD} build //tools/maven:gen_${command} "$@" || \
|
||||
{ echo "${BAZEL_CMD} failed to build gen_${command}. Use VERBOSE=1 for more info" ; exit 1 ; }
|
||||
|
||||
./bazel-bin/tools/maven/${command}.sh
|
||||
|
Loading…
Reference in New Issue
Block a user