Commit Graph

13 Commits

Author SHA1 Message Date
Nathan Baulch 524a97e553 Fix typos
Signed-off-by: Nathan Baulch <nathan.baulch@gmail.com>
2024-09-11 11:21:24 +02:00
Milas Bowman 16d5354d70 watch: add note about goroutine-safety & test
Signed-off-by: Milas Bowman <milas.bowman@docker.com>
2023-03-23 11:33:03 -04:00
Milas Bowman 7aaea283ca watch: data race / segfault fixes
Was getting segfaults with multiple services using
`x-develop` and `watch` at the same time. Turns out
the Moby path matcher lazily initializes the regex
pattern internally the first time it's used, so it's
not goroutine-safe.

Change here is to not use a global instance for the
ephemeral path matcher, but a per-watcher instance.

Additionally, the data race detector caught a couple
other issues that were easy enough to fix:
 * Use the lock that's used elsewhere for convergence
   before manipulating
 * Eliminate concurrent map access when triggering
   rebuilds

Signed-off-by: Milas Bowman <milas.bowman@docker.com>
2023-03-22 18:05:56 -04:00
Milas Bowman da1ca578b5 watch: ignore ephemeral files & minor output tweaks
Big change here is to import the ephemeral ignore set from Tilt.

The `.git` directory is also ignored for now: this restriction
should probably be lifted and made configurable in the future,
but it's not generally important to watch and triggers a LOT of
events (e.g. Git creates `index.lock` files that will appear and
disappear rapidly as terminals/IDEs/etc interact with Git, even
for read-only operations).

The Tilt-provided ephemeral file set has been slowly devised over
time based on temporary files that can cause trouble. We can also
look at a more robust/configurable solution here in the future,
but thse provide a reasonable out-of-the-box configuration for
the moment.

There's also some small tweaks to the output to add missing
newlines in a few edge cases and such.

Signed-off-by: Milas Bowman <milas.bowman@docker.com>
2023-02-24 14:34:51 -05:00
Josh Wilson 6fae6a41f9 Update emacs ignore patterns (#5903)
Currently the emacs ignore patterns include `**/.#*` (lock files), but
doesn't include `**/#*#` (autosave files;
https://www.emacswiki.org/emacs/AutoSave, not to be confused with
`**/*~` backup files which are ignored.)

Add autosave files.
2022-07-26 08:57:40 -05:00
Milas Bowman dd5ea044bb ignore: add Go umask files to ephemeral set (#5740)
When creating files in Go, the stdlib will create (and then rapidly
delete) files ending with `-go-tmp-umask` to determine the umask
to use for permission purposes.

This can cause trouble with Live Update because the files tend to
vanish underneath it, for example.

Fixes #5117.
2022-04-27 16:42:51 -04:00
Milas Bowman 12de97b8d1 filewatch: use apiserver FileWatch model in EngineState (#4277)
This follows the "action-first" approach to use the apiserver model
for `FileWatch` and dispatch simple create/update/delete actions.
2021-03-09 13:05:32 -05:00
Iggy Jackson 62b5f78fd9 Add .kate-swp files to ignore pattern (#3380)
KDE's text editor, kate, uses a file similar to Vim's .swp files. Ignore
these files so we don't rebuild on every keypress.

Fixes #3378
2020-05-27 07:36:06 -07:00
Nick Santos 3f526c5c7b change org name from windmilleng to tilt-dev (#3346) 2020-05-15 10:34:39 -04:00
Matt Landis 12916b75a2 tilt: ignore a few more vim swap files (#2190) 2019-09-12 11:57:39 -04:00
Maia McCormick e3948f6bae ignore: auto-ignore jetbrains .idea file (#2065) 2019-08-15 14:38:44 -04:00
Dan Miller 91a2bdd6de model: move to pkg (#2024) 2019-08-09 12:52:31 -04:00
Nick Santos ce61e7bf18 ignore: improve the ephemeral temp file patterns [ch2663] (#1925) 2019-07-29 11:18:22 -04:00