Repository navigation
Add Sweepito: safely clean caches and build artifacts - #1
Merged
Merged
Conversation
Sweepito finds the technologies in a repository and removes only git-ignored, untracked caches and build output, guided by marker files. - CLI: scan, clean, check, report, rules, profiles, config, init, hook, doctor, with Rich output and plain --json - 17 built-in profiles (97 rules) as TOML data; risk levels safe, configurable and high-impact, plus always-on custom rules - Safety model: only git-ignored and untracked paths inside the project root, never .git, symlinks and Windows junctions are never followed - sweepito.toml / [tool.sweepito] configuration with custom path rules and profiles; --risk custom runs only a project's own rules - Native git hook installer and pre-commit hook definitions - Tests (unit, per-profile and custom-rule integration), CI for Linux, Windows and macOS, docs, changelog and community files
- Ignore a symlink candidate by name in the test: a "build/" pattern only matches real directories, so git never ignored the symlink. - Stop assuming one table border style in the output tests; Rich draws light, heavy or ASCII borders depending on the platform.
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.
Summary
First version of Sweepito (0.1.0): a CLI that finds the technologies in a repository and removes only the caches and build output that are safe to remove.
It only ever deletes paths that Git already ignores and does not track, inside the project root. A folder such as
build/is a candidate only when the project's own marker file is present (CMakeLists.txt,pom.xml, ...), never because of its name.What's included
scan,clean,check,report,rules,profiles,config,init,hook,doctor. Output uses Rich;--jsonstays plain for scripts.saferuns by default,configurableandhigh-impactare opt-in via--enable/--risk. Rules a user writes themselves arecustom, always on, and--risk customruns only those.sweepito.tomlor[tool.sweepito], with custom path rules and profiles..pre-commit-hooks.yaml.Safety
.gitis never touched.execrules are rejected.Testing
Before releasing
SECURITY.md)pypienvironmentv0.1.0after merge (the README's pre-commit example pins it)