Skip to content

fix: add DPRINT_NODE_MODULES_CACHE env var to not store incremental cache in node_modules - #1507

Merged
dsherret merged 1 commit into
mainfrom
feat/node-modules-cache-env-var
Dec 1, 2026
Merged

dsherret merged 1 commit into
mainfrom
feat/node-modules-cache-env-var

Conversation

@dsherret

@dsherret dsherret commented Dec 1, 2026

Copy link
Copy Markdown
Member

Since #1473, the incremental file is stored in the nearest node_modules/.cache/dprint folder when there is one. That means it's lost between CI runs that only cache dprint's cache directory (ex. dprint/check with cache: true).

This adds a DPRINT_NODE_MODULES_CACHE environment variable. Setting it to 0 or false always stores the incremental file in dprint's cache directory. The default behaviour is unchanged.

@dsherret dsherret changed the title feat: add DPRINT_NODE_MODULES_CACHE env var to not store incremental cache in node_modules fix: add DPRINT_NODE_MODULES_CACHE env var to not store incremental cache in node_modules Dec 1, 2026
@dsherret
dsherret merged commit 1460996 into main Dec 1, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant