Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support watching a path even if it's a directory or nonexistent #21339

Closed
wants to merge 1 commit into from

Conversation

Wyverald
Copy link
Member

  • rctx.watch() now supports watching a path even if it's a directory or nonexistent.
    • a path's status changing counts triggers a refetch.
  • added path.is_dir so that users can tell whether a path points to a directory or a file.
  • added watch_X parameters to the following methods, with behavior similar to the watch parameter in rctx.read()
    • rctx.extract(), rctx.patch(), rctx.template() (for the template file), rctx.symlink() (for the symlink target)

Work towards #20952.

@github-actions github-actions bot added team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file. awaiting-review PR is awaiting review from an assigned reviewer labels Feb 13, 2024
- `rctx.watch()` now supports watching a path even if it's a directory or nonexistent.
  - a path's status changing counts triggers a refetch.
- added `path.is_dir` so that users can tell whether a path points to a directory or a file.
- added `watch_X` parameters to the following methods, with behavior similar to the `watch` parameter in `rctx.read()`
  - `rctx.extract()`, `rctx.patch()`, `rctx.template()` (for the template file), `rctx.symlink()` (for the symlink target)

Work towards #20952.
@github-actions github-actions bot removed the awaiting-review PR is awaiting review from an assigned reviewer label Feb 15, 2024
@Wyverald Wyverald deleted the wyv-watch-exists branch February 16, 2024 03:48
Wyverald added a commit that referenced this pull request Feb 20, 2024
- `rctx.watch()` now supports watching a path even if it's a directory or nonexistent.
  - a path's status changing counts triggers a refetch.
- added `path.is_dir` so that users can tell whether a path points to a directory or a file.
- added `watch_X` parameters to the following methods, with behavior similar to the `watch` parameter in `rctx.read()`
  - `rctx.extract()`, `rctx.patch()`, `rctx.template()` (for the template file), `rctx.symlink()` (for the symlink target)

Work towards #20952.

Closes #21339.

PiperOrigin-RevId: 607415094
Change-Id: Iebb6bc28174d05277a034ba3cf5e0c9bf90ce027
Wyverald added a commit that referenced this pull request Feb 20, 2024
- `rctx.watch()` now supports watching a path even if it's a directory or nonexistent.
  - a path's status changing counts triggers a refetch.
- added `path.is_dir` so that users can tell whether a path points to a directory or a file.
- added `watch_X` parameters to the following methods, with behavior similar to the `watch` parameter in `rctx.read()`
  - `rctx.extract()`, `rctx.patch()`, `rctx.template()` (for the template file), `rctx.symlink()` (for the symlink target)

Work towards #20952.

Closes #21339.

PiperOrigin-RevId: 607415094
Change-Id: Iebb6bc28174d05277a034ba3cf5e0c9bf90ce027
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants