chore(git): untrack fuzz/target build artifacts - #5
Merged
Conversation
391 cargo build artifacts under `fuzz/target/` were tracked in git: `.fingerprint/` entries, `dep-lib-*`, `invoked.timestamp`, `.cargo-*-lock`, `*.json` metadata. Tracking them made an ordinary maintenance operation destructive — a routine `cargo sweep` across the fleet deleted them, because every reasonable tool assumes everything under `target/` is regenerable. The root `.gitignore` had `/target/`, which is anchored to the repo root and so never covered `fuzz/target/` (`fuzz` is a nested cargo package with its own `Cargo.toml`, outside the workspace members, so it gets its own build dir). Making the pattern unanchored covers a `target/` at any package root. No file was deleted from disk: `git rm -r --cached` removes index entries only. No source change. `cargo build --workspace` and `cargo test --workspace` (55 passed) confirm nothing depended on the tracked state. The artifacts were not in the published crate payload — the published packages are `core/` and `forensic/`, and `fuzz/` sits outside both (verified: 0 `target/` entries in `cargo package --list` for vhd-core and vhd-forensic). Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
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.
What this is
Index hygiene only. 391 files removed from the git index, zero files removed from disk, no source change.
The diff will render as ~391 deletions. Nothing was deleted —
git rm -r --cacheddrops index entries and leaves the working tree untouched. The only content change in this PR is 4 lines in.gitignore.The defect
391 cargo build artifacts under
fuzz/target/were tracked in git:.fingerprint/entries,dep-lib-*,invoked.timestamp,.cargo-*-lock,*.jsonmetadata.The root
.gitignorewas the single line/target/— a leading slash anchors the pattern to the repo root, so it never coveredfuzz/target/. (fuzzis a nested cargo package with its ownCargo.toml, outside the workspacememberslist, so it gets its own build dir.) The fix makes the pattern unanchored so it matches atarget/at any package root.Why it matters beyond bloat
Tracking these made an ordinary maintenance operation destructive: a routine
cargo sweepacross the fleet deleted them, because every reasonable tool assumes everything undertarget/is regenerable. They were restored withgit restore, but the next person running anytarget/-cleaning tool hits the same trap.Published crate payload
Not affected. The published packages are
core/(vhd-core) andforensic/(vhd-forensic);fuzz/sits outside both, so cargo never sees it —cargo package --listreturns 0target/entries for each. Consumers were not downloading build fingerprints.Nothing depended on the tracked state
grep -rn 'fuzz/target' .github— no matches.cargo build --workspace— clean.cargo test --workspace— 55 passed, 7 suites.Verification
Note for reviewers with other open PRs
Branched from
origin/main. The diff is.gitignoreplus index removals underfuzz/target/, so it should not collide with source changes in the other open PRs.🤖 Generated with Claude Code