NS8 slice: Make file, tree, and project search panels editing-ready #49

Closed
opened 2026-06-21 09:12:13 +00:00 by tmk241 · 1 comment
Owner

OBJECTIVE: Files, directory browsing, gitignore-aware file finding, and project text search become production editing entry points that return cleanly to the editor.

AUTHORITY: Parent #43; KEYMAP.md Panels and Search and navigation; req: repo/001-002, ui/001-002, session/002-004, testing/001-004.

AGENT AUTHORITY:

  • Delivery authority: local-commit
  • Tracker authority: this issue may be commented and closed when acceptance passes; parent #43 may be commented/checklisted.
  • Handoff state: committed clean, tracker commented/closed.

PARENT: #43 via explicit issue link and parent checklist.

SCOPE: File finder/tree panel, directory-root handling, project text search panel, result preview/open, create-new-file path from folder context if needed for mim missing-file, panel stack return, gitignore behavior. Reuse existing repo/panel code where possible.

BOUNDARIES: Git mutation belongs elsewhere. Do not implement fuzzy ranking beyond what is needed for useful navigation. Do not introduce external search dependencies unless already present and optional.

ACCEPTANCE:

  • Space f opens files/tree/recent according to available project context.
  • mim directory starts in a usable file browser rooted at that directory.
  • Opening a file from the panel returns to the editor buffer with cursor/status intact.
  • Space s p searches project text and opens results at the correct file/line.
  • Gitignored files are excluded by default with a visible include-ignored path.
  • Empty directories, permission errors, binary files, deleted files during panel use, and long paths are reported without crashes or hidden mutation.

VERIFICATION:

  • zig build test
  • Fixture tests for gitignore include/exclude, directory open, project search jump, missing/deleted files, permission denial, and panel return.
  • zig build v1-smoke

BLOCKERS: none.

OBJECTIVE: Files, directory browsing, gitignore-aware file finding, and project text search become production editing entry points that return cleanly to the editor. AUTHORITY: Parent #43; KEYMAP.md `Panels` and `Search and navigation`; req: repo/001-002, ui/001-002, session/002-004, testing/001-004. AGENT AUTHORITY: - Delivery authority: local-commit - Tracker authority: this issue may be commented and closed when acceptance passes; parent #43 may be commented/checklisted. - Handoff state: committed clean, tracker commented/closed. PARENT: #43 via explicit issue link and parent checklist. SCOPE: File finder/tree panel, directory-root handling, project text search panel, result preview/open, create-new-file path from folder context if needed for `mim missing-file`, panel stack return, gitignore behavior. Reuse existing repo/panel code where possible. BOUNDARIES: Git mutation belongs elsewhere. Do not implement fuzzy ranking beyond what is needed for useful navigation. Do not introduce external search dependencies unless already present and optional. ACCEPTANCE: - `Space f` opens files/tree/recent according to available project context. - `mim directory` starts in a usable file browser rooted at that directory. - Opening a file from the panel returns to the editor buffer with cursor/status intact. - `Space s p` searches project text and opens results at the correct file/line. - Gitignored files are excluded by default with a visible include-ignored path. - Empty directories, permission errors, binary files, deleted files during panel use, and long paths are reported without crashes or hidden mutation. VERIFICATION: - `zig build test` - Fixture tests for gitignore include/exclude, directory open, project search jump, missing/deleted files, permission denial, and panel return. - `zig build v1-smoke` BLOCKERS: none.
tmk241 added the sliceready-for-agentgoal labels 2026-06-21 09:12:13 +00:00
Author
Owner

Completed in commit 1d1ecf2 (Add file and project search panels).

What changed:

  • Space f now opens a real file picker panel from the repo/directory file list.
  • Panel o/Enter opens the selected file into the editor buffer; q/Esc closes the active panel.
  • Space s p opens a project-search prompt and displays matching rows in a transient project-search panel.
  • Opening a project-search result loads the target file and places the cursor at the match offset.
  • mim <directory> now seeds repo-backed file rows with readable file contents, so directory-start panels can open files rather than just preview names.
  • Added panel accessors and tests for file picker open, project search result open, ignored/default-empty behavior, no-match status, and panel close.

Verification:

  • zig fmt src/main.zig src/leader.zig src/session.zig src/panel.zig src/tui.zig && zig build test
  • zig build
  • zig build v1-smoke
  • zig build run -- --help
  • zig build run -- src/main.zig
  • zig build run -- src
  • redgate lint /opt/repositories/mim/REQUIREMENTS.md && redgate health /opt/repositories/mim/REQUIREMENTS.md

Notes:

  • This closes the file/tree/project-search panel slice. Deeper git workbench behavior remains outside #49.
Completed in commit 1d1ecf2 (`Add file and project search panels`). What changed: - `Space f` now opens a real file picker panel from the repo/directory file list. - Panel `o`/Enter opens the selected file into the editor buffer; `q`/Esc closes the active panel. - `Space s p` opens a project-search prompt and displays matching rows in a transient project-search panel. - Opening a project-search result loads the target file and places the cursor at the match offset. - `mim <directory>` now seeds repo-backed file rows with readable file contents, so directory-start panels can open files rather than just preview names. - Added panel accessors and tests for file picker open, project search result open, ignored/default-empty behavior, no-match status, and panel close. Verification: - `zig fmt src/main.zig src/leader.zig src/session.zig src/panel.zig src/tui.zig && zig build test` - `zig build` - `zig build v1-smoke` - `zig build run -- --help` - `zig build run -- src/main.zig` - `zig build run -- src` - `redgate lint /opt/repositories/mim/REQUIREMENTS.md && redgate health /opt/repositories/mim/REQUIREMENTS.md` Notes: - This closes the file/tree/project-search panel slice. Deeper git workbench behavior remains outside #49.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: tmk241/mim#49