Skip to content

Exclude node_modules from Time Machine backups#857

Open
guillaumekh wants to merge 6 commits intonpm:mainfrom
guillaumekh:copilot/create-rfc-for-issue-471
Open

Exclude node_modules from Time Machine backups#857
guillaumekh wants to merge 6 commits intonpm:mainfrom
guillaumekh:copilot/create-rfc-for-issue-471

Conversation

@guillaumekh
Copy link

@guillaumekh guillaumekh commented Mar 16, 2026

What this PR does

This PR adds an opt-in time-machine-exclude boolean flag to npm configuration.

When enabled, on MacOS machines, it sets a file system extended attribute on the node_modules folder that excludes it from Time Machines backups.

Motivation

node_modules directories can take a lot of space, and contain a lot of files, resulting in slower Time Machine backups and wasted backup storage space.

References

Prior art

Disclaimer

The PR was drafted with Claude, but tested and edited by me. If something stupid slipped in, it's on me.

Copilot AI and others added 5 commits March 16, 2026 11:28
Co-authored-by: guillaumekh <1011994+guillaumekh@users.noreply.github.com>
…up alternative

Co-authored-by: guillaumekh <1011994+guillaumekh@users.noreply.github.com>
…tory creation

Co-authored-by: guillaumekh <1011994+guillaumekh@users.noreply.github.com>
@guillaumekh guillaumekh requested a review from a team as a code owner March 16, 2026 15:50
Copy link
Contributor

@ljharb ljharb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this would be great

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.

[RRFC] Exclude node_modules from Time Machine backups (macOS)

3 participants