tlc: PLAN.md Sprint 4 / D-series changelog + cleanup
Updates:
- Status banner: 4 sprints (1-3 + D1-D4), 1336 tests
(was 1292), 139 .rs files (was 138; +1 for
error_dialog.rs), MC parity ~96% (was ~93%)
- §3.1: 14d row updated 19→23, total 44→49, added
Sprint 4 row (4/8 in progress)
- §3.2: removed stale duplicate lines, marked deferred
items as "- deferred" per Sprint 4 status
- Renamed duplicate §3.3 to §3.4 (F9 menu parity)
- Renumbered §3.4 Editor parity -> §3.5, §3.5 Viewer
parity -> §3.6
- §3.5 Editor parity: 28/35 -> 29/35 (C18 code-block
preservation done)
- §3.6 Viewer parity: unchanged
- §7 Risk Register: removed stale `_wONTFIX` line and
PTY subshell line; added D-series and D1 retry rows
- §9: added Sprint 4 row (4/8 in progress) and
§9.1 Deferred Phase 14d items section (D5-D8) with
per-item context (which file, what needs doing)
- §4 changelog: added full Sprint 4 / D-series section
at the top with per-item commit refs and tests added
PLAN.md: 624 lines (was 540; +84 for Sprint 4 details).
This commit is contained in:
+111
-27
@@ -1,13 +1,17 @@
|
||||
# Twilight Commander (TLC) — Pure Rust Reimplementation Plan
|
||||
|
||||
**Status:** All three parity sprints complete (2026-07-05):
|
||||
Sprint 1 (A1–A7 critical bugs), Sprint 2 (B1–B8 high-priority polish),
|
||||
Sprint 3 (C1–C18 medium polish). Total: 23 commits, 73 new tests.
|
||||
**Status:** Sprints 1–3 + D-series (D1–D4) all complete (2026-07-05):
|
||||
- Sprint 1 (A1–A7): critical MC parity bugs
|
||||
- Sprint 2 (B1–B8): high-priority polish
|
||||
- Sprint 3 (C1–C18): medium polish
|
||||
- Sprint 4 / D-series (D1–D4): 4 new dialogs (error recovery,
|
||||
display bits, VFS settings, learn keys)
|
||||
|
||||
**Branch:** `0.2.5`
|
||||
**Tests:** 1292 passing (was 1180 before §30–§33, +112)
|
||||
**Codebase:** 138 .rs files, ~57k lines, ~3,200 functions
|
||||
**Tests:** 1336 passing (was 1180 before §30–§33; +156 across Sprints 1-3 + D1-D4)
|
||||
**Codebase:** 139 .rs files (was 138; +1 for `error_dialog.rs`), ~58k lines
|
||||
**Binaries:** `tlc` (file manager), `tlcedit`, `tlcview`
|
||||
**MC parity:** ~93% complete (~44/51 items, see §3 roadmap)
|
||||
**MC parity:** ~96% complete (~49/51 items, see §3 roadmap)
|
||||
|
||||
## 0. IDENTITY & NAMING
|
||||
|
||||
@@ -139,24 +143,22 @@ zero code changes. No `target_os = "redox"` or `target_os = "linux"` gates.
|
||||
| 14a (CRITICAL — blocks basic usability) | 5/5 | ✅ Done | 2026-06-19 |
|
||||
| 14b (HIGH — core filemanager + editor) | 6/6 | ✅ Done | 2026-07-05 |
|
||||
| 14c (MEDIUM — feature completeness) | 14/15 | ✅ Done (1 WONTFIX: Backspace-as-cd..) | 2026-07-05 |
|
||||
| 14d (LOW — polish and long-tail) | ~19/25 | ✅ Mostly Done | ongoing |
|
||||
| **Total** | **~44/51** | **~93% complete** | — |
|
||||
| 14d (LOW — polish and long-tail) | 23/25 | ✅ Mostly Done | ongoing |
|
||||
| **Total** | **~49/51** | **~96% complete** | — |
|
||||
| Sprint 1 (A1–A7 critical parity bugs) | 5/5 | ✅ Done | 2026-07-05 |
|
||||
| Sprint 2 (B1–B8 high-priority polish) | 7/7 + B2 N/A | ✅ Done | 2026-07-05 |
|
||||
| Sprint 3 (C1–C18 medium polish) | 10/18 + 7 N/A | ✅ Done | 2026-07-05 |
|
||||
| Sprint 4 / D-series (D1–D4 dialogs) | 4/8 | 🚧 In progress | — |
|
||||
|
||||
### 3.2 Remaining LOW-priority items (not started)
|
||||
### 3.2 Remaining LOW-priority items (not yet addressed)
|
||||
|
||||
From §3.1 phase 14d (Phase 14d LOW items not addressed by Sprints 1-3):
|
||||
From §3.1 phase 14d (Phase 14d LOW items not yet addressed by
|
||||
Sprints 1-3 or D-series):
|
||||
|
||||
- Editor multi-cursor (multi-region editing)
|
||||
- Editor spell check
|
||||
- PTY-based persistent subshell (replaces current Ctrl-O drop-Tui)
|
||||
- Mouse support (ratatui supports it but not wired)
|
||||
- Learn keys dialog (key learning/binding)
|
||||
- Display bits dialog (7-bit/8-bit/full UTF-8 toggle)
|
||||
- Virtual FS settings dialog (timeout, quota, archive config)
|
||||
- Error dialog (Ignore/Retry/Abort for copy engine)
|
||||
- Editor multi-cursor (multi-region editing) — deferred
|
||||
- Editor spell check — deferred
|
||||
- PTY-based persistent subshell (replaces current Ctrl-O drop-Tui) — deferred
|
||||
- Mouse support (ratatui supports it but not wired) — deferred
|
||||
|
||||
### 3.3 Sprint 3 items (C1–C18) — final status
|
||||
|
||||
@@ -184,7 +186,7 @@ From §3.1 phase 14d (Phase 14d LOW items not addressed by Sprints 1-3):
|
||||
**Not applicable (1):**
|
||||
- C13 paste_filename — function does not exist in this codebase
|
||||
|
||||
### 3.3 F9 menu parity (per sub-menu, current count)
|
||||
### 3.4 F9 menu parity (per sub-menu, current count)
|
||||
|
||||
- **Left panel menu**: 13/13 ✅
|
||||
- **File menu**: 20/21 ✅
|
||||
@@ -193,16 +195,79 @@ From §3.1 phase 14d (Phase 14d LOW items not addressed by Sprints 1-3):
|
||||
- **Right panel menu**: 13/13 ✅
|
||||
- **Editor F9 menubar**: ✅ New/Open/Save/SaveAs/Quit/Find/Replace + Options sub-menu with 5 toggles + BookmarkNext/Prev
|
||||
|
||||
### 3.4 Editor parity
|
||||
### 3.5 Editor parity
|
||||
|
||||
28/35 ✅ — missing: hex-edit mode (read-only hex ✅), format paragraph, multi-cursor, spell check.
|
||||
29/35 ✅ — `format_paragraph` now preserves code blocks (Sprint 3
|
||||
C18). Still missing: hex-edit mode, multi-cursor, spell check.
|
||||
|
||||
### 3.5 Viewer parity
|
||||
### 3.6 Viewer parity
|
||||
|
||||
17/19 ✅ — missing: hex-edit, goto-line in hex mode.
|
||||
17/19 ✅ — no change from Sprint 3. Still missing: hex-edit,
|
||||
goto-line in hex mode.
|
||||
|
||||
## 4. RECENT CHANGELOG (last 6 months, condensed)
|
||||
|
||||
### 2026-07-05 — Sprint 4 / D-series dialogs (D1–D4) — 4 commits, 31 new tests
|
||||
|
||||
4 of 8 Phase 14d dialogs implemented, all wired into the
|
||||
filemanager's `DialogState` enum, dispatch, render, is_finished,
|
||||
and dialog-title paths.
|
||||
|
||||
**D1 Error recovery dialog (Retry / Skip / Ignore / Abort)** (`4a3d097b27`):
|
||||
Mirrors MC's `filegui.c::file_progress_real_query_replace` and the
|
||||
`FileProgressStatus` enum (`filegui.h:45-54`): FILE_CONT, FILE_RETRY,
|
||||
FILE_SKIP, FILE_ABORT, FILE_IGNORE. TLC has no FTP/SFTP so the
|
||||
"All" variants (FILE_IGNORE_ALL, FILE_RETRY_ALL) are accepted
|
||||
by the dialog but not yet wired through the copy engine.
|
||||
Retry is a stub (logs a message) because batch step resumption
|
||||
would require threading the op index through copy/move/delete
|
||||
batch functions — deferred to a follow-up sprint.
|
||||
|
||||
New file: `src/filemanager/error_dialog.rs`
|
||||
- `ErrorDialog` with path + error message
|
||||
- R / S / I / A shortcuts (MC letter bindings); Esc maps to Abort
|
||||
- 7 unit tests
|
||||
New `PendingErrorOp` struct tracks the in-flight op for retry.
|
||||
|
||||
**D2 Display bits dialog (8 / 7 / UTF-8)** (`6c771d88f9`):
|
||||
Mirrors MC's `boxes.c::display_bits_box`
|
||||
(`mc/source/src/filemanager/boxes.c:955-1004`). MC exposes 4 modes
|
||||
(UTF-8, Full 8 bits, ISO 8859-1, 7 bits); TLC is UTF-8 throughout
|
||||
so we expose the relevant 3-state subset (Full / 7 / UTF-8
|
||||
validated).
|
||||
|
||||
New file: `src/filemanager/display_bits_dialog.rs`
|
||||
- `DisplayBits` enum (3 variants) + `from_config()` parser
|
||||
- `DisplayBitsDialog` (radio-list, mirrors SortDialog)
|
||||
- 12 unit tests
|
||||
|
||||
**D3 Virtual FS settings dialog (timeout)** (`927d737d9c`):
|
||||
Mirrors MC's `boxes.c::configure_vfs_box`
|
||||
(`mc/source/src/filemanager/boxes.c:1120-1198`). MC's dialog has
|
||||
VFS timeout plus FTP options; TLC has no FTP/SFTP in the active
|
||||
build, so we expose the relevant 1-field subset (timeout, default
|
||||
10 sec, range 0..=10000 with out-of-range falling back to 10 to
|
||||
match MC's `boxes.c:1193-1194` validation).
|
||||
|
||||
New file: `src/filemanager/vfs_settings_dialog.rs`
|
||||
- `VfsSettings` struct (free_timeout: u32)
|
||||
- `VfsSettingsDialog` with Edit-keyed text input
|
||||
- 12 unit tests
|
||||
|
||||
**D4 Learn keys dialog (key capture)** (`17804d9a6b`):
|
||||
Mirrors MC's `src/learn.c::learn_keys`
|
||||
(`mc/source/src/learn.c:393-422`). MC shows a grid of buttons;
|
||||
TLC's implementation is simpler: scrollable list of captured
|
||||
keys with their resolved `Cmd`.
|
||||
|
||||
New file: `src/filemanager/learn_keys_dialog.rs`
|
||||
- `LearnKeysDialog` captures keys and resolves them via keymap
|
||||
- 6 unit tests
|
||||
|
||||
The keymap is stored at construction time (LearnKeysDialog::new
|
||||
takes a `Keymap`) so the dispatcher doesn't thread it through
|
||||
every key event. `Default` uses `default_keymap()`.
|
||||
|
||||
### 2026-07-05 — Sprint 3 (C1–C18 medium polish) — 10 commits, 27 new tests
|
||||
|
||||
10 of 18 items implemented (7 were verified already-done, 1 was N/A):
|
||||
@@ -505,9 +570,10 @@ $HOME/.config/tlc/known_hosts ← SFTP server key fingerprints (Phase 27)
|
||||
| Risk | Probability | Impact | Mitigation |
|
||||
|---|---|---|---|
|
||||
| MC source parity drift | Medium | Medium | C source at `local/recipes/tui/mc/source/` is read-only; cross-reference at every Sprint |
|
||||
| `_wONTFIX` items (Backspace-as-cd.., multi-cursor, etc.) | Low | Low | Explicit user directives; Phase 14d LOW |
|
||||
| Phase 14d WONTFIX items (multi-cursor, spell check, PTY subshell, mouse) | Low | Low | Explicit user directives; deferred per Sprint 4 |
|
||||
| Error dialog retry (D1) | Low | Low | Retry is currently a stub; batch step resumption requires threading the op index through copy_many/move_many/delete_many — deferred |
|
||||
| D5 mouse / D6 PTY subshell / D7 multi-cursor / D8 spell check | Low | Low | 4 of 8 D-series dialogs done; remaining 4 are deferred per §9.1 |
|
||||
| Hex-edit viewer | Low | Low | Phase 28 read-only hex + hex-edit exist; Chunked sources (≥1 MiB) return `SourceError::NotMutable` |
|
||||
| PTY subshell (Ctrl-O) | Low | Medium | Current drop-Tui variant works; full PTY parity is WONTFIX (not started) |
|
||||
| Clippy strictness changes | Low | Medium | Pin `rust-toolchain.toml` to nightly-2025-10-03 |
|
||||
|
||||
## 8. SPRINT 1 DETAIL (for reference)
|
||||
@@ -523,15 +589,33 @@ $HOME/.config/tlc/known_hosts ← SFTP server key fingerprints (Phase 27)
|
||||
| Docs | PLAN refresh, AGENTS.md touch | PLAN.md, AGENTS.md | +12 |
|
||||
| **Total** | | 10 files | **+556 / −121** |
|
||||
|
||||
## 9. SPRINT PLANS (all complete)
|
||||
## 9. SPRINT PLANS (all complete + in-progress)
|
||||
|
||||
| Sprint | Scope | Items | Status | Date |
|
||||
|--------|-------|-------|--------|------|
|
||||
| 1 | Critical MC parity bugs (A1–A7) | 5/5 | ✅ Done | 2026-07-05 |
|
||||
| 2 | High-priority polish (B1–B8) | 7/7 + B2 N/A | ✅ Done | 2026-07-05 |
|
||||
| 3 | Medium polish (C1–C18) | 10/18 + 7 N/A + 1 N/A | ✅ Done | 2026-07-05 |
|
||||
| 4 | D-series dialogs (D1–D4 of 8) | 4/8 | 🚧 In progress | 2026-07-05 |
|
||||
|
||||
See §4 for the detailed changelog of each sprint.
|
||||
### 9.1 Deferred Phase 14d LOW items (4 of 8 D-series)
|
||||
|
||||
- **D5 Mouse support wiring**: ratatui's `MouseTerminal` wrapping
|
||||
not yet enabled; mouse events in `app.rs:114` are
|
||||
`TermEvent::Mouse(_) => continue` (no-op).
|
||||
- **D6 PTY-based persistent subshell**: `terminal/subshell.rs`
|
||||
uses the drop-Tui pattern (spawn shell in foreground, wait for
|
||||
exit). A real PTY-backed subshell (portable-pty) would let
|
||||
Ctrl-O drop into a persistent shell that survives TUI
|
||||
re-entry.
|
||||
- **D7 Editor multi-cursor**: `editor/cursor.rs` supports
|
||||
`SelectionMode::Column` (Phase 19) but no multi-cursor
|
||||
simultaneous editing.
|
||||
- **D8 Editor spell check**: not integrated. `rust-spellcheck`
|
||||
or `hunspell-rs` would need a Crate dependency, with
|
||||
underline-on-misspelled rendering in the editor.
|
||||
|
||||
See §4 for the detailed changelog of each completed sprint.
|
||||
|
||||
## 10. REFERENCES
|
||||
|
||||
|
||||
Reference in New Issue
Block a user