Deno 2.9 task cache skips unchanged builds, cutting a 4-second run to about 10 milliseconds
Deno 2.9.8 added a files field to deno.json task definitions, letting a task skip execution when its declared inputs are unchanged. A developer tested a deliberately slow build step that hashed 40 source files and saw runs of roughly 3.9 to 4.3 seconds drop to under 10 milliseconds on cache hits. Tests showed that touching a file's timestamp without changing its contents did not invalidate the cache, while an actual content edit did. Deleting the declared output directory was restored from the cache store without re-running the command. The output glob determines which generated files are restored on a hit.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in