diff options
author | David Ostrovsky <david@ostrovsky.org> | 2018-12-03 05:37:14 +0100 |
---|---|---|
committer | David Ostrovsky <david@ostrovsky.org> | 2019-10-13 12:10:22 +0200 |
commit | 1634d5ab5b21af33e250e1312085d174a9c8049d (patch) | |
tree | b604179496730fdd053e793f16e1dfbd5cc8fba6 | |
parent | e9a5dcb2f2eef825a0c7d053d7738900804dcd95 (diff) |
Bazel: Include eclipse-out directory in .bazelignore
Since [1] Bazel added support for .bazelignore, allowing to specify
directories that should be ignored. We still preserve the exclusion of
BUILD files in generated .classpath file to avoid Eclipse warnings in
the form:
The resource is a duplicate of java/BUILD \
and was not copied to the output folder
[1] https://github.com/bazelbuild/bazel/issues/4888
Change-Id: I8dfd9b5701dfcc85fd51f626af448d0306b02857
-rw-r--r-- | .bazelignore | 1 | ||||
-rwxr-xr-x | tools/eclipse/project.py | 5 |
2 files changed, 3 insertions, 3 deletions
diff --git a/.bazelignore b/.bazelignore new file mode 100644 index 0000000000..30f16134c3 --- /dev/null +++ b/.bazelignore @@ -0,0 +1 @@ +eclipse-out diff --git a/tools/eclipse/project.py b/tools/eclipse/project.py index dace18227e..5fd612637c 100755 --- a/tools/eclipse/project.py +++ b/tools/eclipse/project.py @@ -141,9 +141,8 @@ def gen_classpath(ext): def classpathentry(kind, path, src=None, out=None, exported=None): e = doc.createElement('classpathentry') e.setAttribute('kind', kind) - # TODO(davido): Remove this and other exclude BUILD files hack - # when this Bazel bug is fixed: - # https://github.com/bazelbuild/bazel/issues/1083 + # Excluding the BUILD file, to avoid the Eclipse warnings: + # "The resource is a duplicate of ..." if kind == 'src': e.setAttribute('excluding', '**/BUILD') e.setAttribute('path', path) |