Skip already excluded directories#97
Open
VladRassokhin wants to merge 3 commits intostevegrunwell:developfrom
Open
Skip already excluded directories#97VladRassokhin wants to merge 3 commits intostevegrunwell:developfrom
VladRassokhin wants to merge 3 commits intostevegrunwell:developfrom
Conversation
Using `mdfind` since it's fast, yet it may not return all excluded directories Kinda fixes stevegrunwell#68
django23
added a commit
to django23/asimov
that referenced
this pull request
Feb 19, 2026
Use Spotlight metadata (mdfind) to identify directories already excluded from Time Machine and skip them during the find traversal. Also fixes a comment typo and removes duplicate Gradle sentinel entries. Inspired by stevegrunwell#97, props @VladRassokhin.
4 tasks
django23
added a commit
to django23/asimov
that referenced
this pull request
Feb 19, 2026
Use Spotlight metadata (mdfind) to identify directories already excluded from Time Machine and skip them during the find traversal. Also fixes a comment typo and removes duplicate Gradle sentinel entries. Inspired by stevegrunwell#97, props @VladRassokhin.
django23
added a commit
to django23/asimov
that referenced
this pull request
Feb 19, 2026
* docs(readme): clarify that asimov only affects Time Machine, not Spotlight Add a note explaining that asimov does not hide directories from Spotlight indexing, with guidance on how to configure Spotlight privacy settings separately. Addresses stevegrunwell#90. * feat(sentinels): add .NET project build directory exclusions Exclude bin/ and obj/ directories when *.csproj (C#) or *.fsproj (F#) project files are present, using glob sentinel patterns. Inspired by stevegrunwell#87, props @guigomesa. * feat: skip already-excluded directories for faster subsequent runs Use Spotlight metadata (mdfind) to identify directories already excluded from Time Machine and skip them during the find traversal. Also fixes a comment typo and removes duplicate Gradle sentinel entries. Inspired by stevegrunwell#97, props @VladRassokhin. * feat: exclude well-known global cache directories Add fixed directory exclusions for common tool caches (~/.cache, ~/.gradle/caches, ~/.m2/repository, ~/.npm/_cacache, ~/.nuget/packages, ~/.kube/cache) that are always safe to exclude without sentinel files. Inspired by stevegrunwell#69, props @pkuczynski.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I've a
~/development/projectdirectory which is manually marked as excluded from Time Machine.Previously
asimovwould iterate over its subdirectories, now it won't.Also, subsequent runs could benefit from that feature.
Using
mdfindinstead offind "${ASIMOV_ROOT}" -type d -xattrname "com.apple.metadata:com_apple_backup_excludeItem" -prune -printas it's superfast. Though it has a downside: some excluded directories are not reported.