Type
Files to change
cmd/exec.go
cmd/update.go
cmd/init.go
internal/operations/rename.go
Description
Commit f8181b4 applied errhint.WithFix consistently to user-facing errors across the codebase. Several sites were missed in that sweep and still use bare fmt.Errorf, leaving the user with no actionable recovery hint on failure.
Sites identified:
cmd/init.go — multiple bare fmt.Errorf calls for config-directory, gitignore, and legacy-config failures (lines 126, 137, 143, 148, 166, 172, 177, 184, 212, 232, 238) — each failure could include a "To fix: rimba init" or filesystem-specific hint.
cmd/update.go — update, download, binary-replace, and PATH errors (lines 44–121) — failures during self-update leave the binary in an unknown state; hints like "To fix: re-run rimba update" or "manually replace the binary at " would help.
cmd/exec.go — any error paths not yet covered.
internal/operations/rename.go:31,41 — "branch already exists" and "worktree moved but rename failed" — both benefit from a git branch -m or rimba rename recovery hint.
Acceptance
Bundles
Original candidate folded into this issue:
- E5: follow-up sweep of
fmt.Errorf sites not covered by f8181b4 — cmd/init.go, cmd/update.go, cmd/exec.go, internal/operations/rename.go.
Type
Files to change
cmd/exec.gocmd/update.gocmd/init.gointernal/operations/rename.goDescription
Commit
f8181b4appliederrhint.WithFixconsistently to user-facing errors across the codebase. Several sites were missed in that sweep and still use barefmt.Errorf, leaving the user with no actionable recovery hint on failure.Sites identified:
cmd/init.go— multiple barefmt.Errorfcalls for config-directory, gitignore, and legacy-config failures (lines 126, 137, 143, 148, 166, 172, 177, 184, 212, 232, 238) — each failure could include a "To fix: rimba init" or filesystem-specific hint.cmd/update.go— update, download, binary-replace, and PATH errors (lines 44–121) — failures during self-update leave the binary in an unknown state; hints like "To fix: re-run rimba update" or "manually replace the binary at " would help.cmd/exec.go— any error paths not yet covered.internal/operations/rename.go:31,41— "branch already exists" and "worktree moved but rename failed" — both benefit from agit branch -morrimba renamerecovery hint.Acceptance
fmt.Errorfcalls in the listed files that produce user-visible errors are wrapped witherrhint.WithFix(err, "To fix: <command>").golangci-lintpasses.Bundles
Original candidate folded into this issue:
fmt.Errorfsites not covered by f8181b4 —cmd/init.go,cmd/update.go,cmd/exec.go,internal/operations/rename.go.