Do not auto refresh archive_repository on windows (#861)
* do not refresh on windows
* trivial changes to force recompile
* Make touch less enthusiastic
* revert trivial change
diff --git a/src/main/starlark/release_archive/repository.bzl b/src/main/starlark/release_archive/repository.bzl
index 58b97ef..cba3568 100644
--- a/src/main/starlark/release_archive/repository.bzl
+++ b/src/main/starlark/release_archive/repository.bzl
@@ -97,15 +97,16 @@
archive = release_artifact,
)
- # update the timestamp on the repository rule source to ensure it's always re-evaluated.
- self = workspace
- for segment in "src/main/starlark/release_archive/repository.bzl".split("/"):
- self = self.get_child(segment)
-
- repository_ctx.execute([
- "touch",
- str(self),
- ])
+ # Update the timestamp on the repository rule source to ensure it's always re-evaluated.
+ # This appears to cause issues on windows with permissions -- so don't do it.
+ if not "win" in repository_ctx.os.name:
+ self = workspace
+ for segment in "src/main/starlark/release_archive/repository.bzl".split("/"):
+ self = self.get_child(segment)
+ repository_ctx.execute([
+ "touch",
+ str(self),
+ ])
# not windows compatible.
# buildifier: disable=unused-variable