diff --git a/.index.mf b/.index.mf new file mode 100644 index 0000000..3f1d0f1 Binary files /dev/null and b/.index.mf differ diff --git a/CLAUDE.md b/CLAUDE.md index eb8a9ef..f4556e2 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -1,5 +1,10 @@ # Important Rules +* when fixing a bug, write a failing test FIRST. only after the test fails, write + the code to fix the bug. then ensure the test passes. leave the test in + place and commit it with the bugfix. don't run shell commands to test + bugfixes or reproduce bugs. write tests! + * never, ever mention claude or anthropic in commit messages. do not use attribution * after each change, run "make fmt". diff --git a/README.md b/README.md index 30999c8..71a05b3 100644 --- a/README.md +++ b/README.md @@ -365,7 +365,7 @@ The manifest file would do several important things: - [x] **Add unit tests for `internal/checker`** - 88.5% coverage. - [x] **Add unit tests for `internal/scanner`** - 80.1% coverage. -- [ ] **Clean up FIXMEs in manifest.go** - Validate input paths exist, validate filesystem. +- [x] **Clean up FIXMEs in manifest.go** - Validated input paths, validated filesystem, added context cancellation. - [x] **Validate input paths before scanning** - Fails fast with clear error if paths don't exist. # Open Questions diff --git a/TODO.md b/TODO.md deleted file mode 100644 index 425694a..0000000 --- a/TODO.md +++ /dev/null @@ -1,33 +0,0 @@ -# TODO for 1.0 Release - -## High Priority - -- [ ] **Fix panic in log.go** - `internal/log/log.go:141` has a `panic("unable to get logger")` that should return an error or handle gracefully instead. - -- [ ] **Clean up FIXMEs in manifest.go** - Multiple FIXMEs need attention: - - Line 67: Validate input paths exist before processing - - Line 77: Add validation for filesystem input - - Line 163: Avoid redundant stat calls - - Line 182: Add context support for cancellation - -- [ ] **Fix WriteToFile overwrite behavior** - `mfer/output.go:9` has FIXME to refuse overwriting without `-f` flag. - -- [ ] **Consolidate legacy manifest code** - `mfer/manifest.go` has old scanning code (`Scan()`, `addFile()`) that duplicates the new `internal/scanner` + `mfer/builder.go` pattern. Remove duplication. - -## Medium Priority - -- [ ] **Add unit tests for `internal/checker`** - Currently has no test files; only tested indirectly via CLI tests. - -- [ ] **Add unit tests for `internal/scanner`** - Currently has no test files. - -- [ ] **Add context cancellation to legacy code** - The old `manifest.Scan()` doesn't support context cancellation; the new scanner does. - -- [ ] **Validate input paths before scanning** - Should fail fast with a clear error if paths don't exist. - -- [ ] **Add resume support for fetch** - Allow resuming partial downloads using HTTP Range requests and existing temp files. - -## Lower Priority - -- [ ] **Add manifest signature support** - Implement signing and verification using signify or similar. - -- [ ] **Improve error messages** - Ensure all error messages are clear and actionable.