Commit Graph

16 Commits

Author SHA1 Message Date
Félix Saparelli
6c23afe839
feat: make it possible to watch non-recursively (#827)
Fixes #227
Fixes #174

docs(cli): be more precise in print-events advice to use `-v`
docs(cli): improve jaq error help
feat(cli): add `-W` for non-recursive watches
feat(cli): use non-blocking logging
feat(globset): hide `fmt::Debug` spew from ignore crate
feat(ignore-files): hide `fmt::Debug` spew from ignore crate
feat(lib): make it possible to watch non-recursively
fix(lib): inserting `WatchedPath`s directly should be possible
refactor(lib): move `WatchedPath` out of `fs` mod
2024-04-28 06:33:07 +00:00
Félix Saparelli
4f757de8df
Canonicalise paths for ignore discovery (#760) 2024-01-04 09:32:47 +00:00
Victor Adossi ("vados")
cb1cfb6bf5
Optimise ignore file gathering (#663)
Co-authored-by: Félix Saparelli <felix@passcod.name>
2024-01-01 05:01:14 +00:00
thislooksfun
3ad0e1aa57
Respect applies_in scope when processing nested ignores (#746)
Previously, when importing multiple nested ignore files, some info from
the parent—notably the "root" path—would be inherited. This lead to some
problems with matching of "pseudo-absolute" rules (those with a leading
slash) in nested ignore files (see #745 for more details). To fix this,
we now fully isolate each path of the tree during the import process.
This leads to more accurate, though unfortunately slightly less
performant, rule matching. The only time a builder is reused now is if
two input files have the same `applies_in` value, in which case they are
merged together.

I have added tests to ensure correctness and prevent a regression. I
also was careful to make sure no previous tests broke in any way (all
changes to existing tests were made in isolation, and thus are not
affected by the logic changes). As far as I can tell, the only behavior
change is that now some previously-ignored rules will now be applied,
which could, in very rare configurations, lead to files being
unintentionally ignored. However, due to the aforementioned logic bug,
those files were all ignored by git already, so I suspect the number of
people actually caught off guard by this change to be extremely low,
likely zero.

Fixes #745.
2023-12-30 14:12:59 +13:00
Félix Saparelli
a13bc429eb
Watchexec lib v3 (#601)
Co-authored-by: emilHof <95590295+emilHof@users.noreply.github.com>
2023-11-25 20:33:44 +00:00
Félix Saparelli
4c3b9f0960
Clippy and update lockfile (#646) 2023-08-30 03:43:57 +00:00
Jonathan Cammisuli
638cddcf83
handle relative paths when using Ignore programmatically (#599) 2023-06-03 20:24:39 +12:00
Jonathan Cammisuli
6a86caacf2
Fix adding globs to the IgnoreFilter (#581) 2023-05-14 16:59:59 +12:00
Jonathan Cammisuli
3e79957ad3
Handle nested gitignores (#580) 2023-05-08 22:13:04 +00:00
Félix Saparelli
5c63a99013
Fix and adjust docs (#530) 2023-03-18 10:23:46 +00:00
Félix Saparelli
14f53a6bf5
Clap 4 and revamp manpage, completions (#513) 2023-03-05 14:57:34 +13:00
David Perez
70beb51ab5
Switch to gix-config because git-config is deprecated (#502)
Co-authored-by: Félix Saparelli <felix@passcod.name>
2023-03-02 16:17:19 +13:00
Félix Saparelli
dc98370492
Clippy fixes (#465) 2023-01-07 02:53:49 +13:00
Félix Saparelli
24a3a3c2f2
Deps: update miette and git-config (#406) 2022-09-07 02:52:53 +00:00
Félix Saparelli
669ad6a7bf
Ditch actions-rs (#395) 2022-09-07 02:15:38 +00:00
Félix Saparelli
35cf63bc85 Split into more crates (#307) 2022-06-15 03:25:05 +00:00