summaryrefslogtreecommitdiff
path: root/internal/shell/shell.go
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2026-02-22 17:05:02 +0200
committerPaul Buetow <paul@buetow.org>2026-02-22 17:05:02 +0200
commit8480d1b1b074729ebfe43cc2fcb400910880627f (patch)
tree839078b6774a676ed0094c99a0ed93864720b8ba /internal/shell/shell.go
parentbcb07f5587c310063b74d280f7e82aa47a132c39 (diff)
Implement internal/cli package (task 352/cli)
Full command dispatch, interactive shell loop, and all geheim commands mirroring the Ruby CLI class (geheim.rb lines 551-713). Key design points: - CLI struct holds all runtime deps; lastResult field enables Ruby-style fallback search term when a search command is given without an argument - dispatch → dispatchSimple (no-term commands) + dispatchSearch (term-based) kept under ~50 lines each per style guidelines - ActionOpen shreds the exported file immediately after opening, matching Ruby's shred_file(delay: 0) call - import implements Ruby's three-way dest_dir logic: nil→full src_path, contains-dot→literal dest, plain-dir→dir/basename(src) - completionFn notes $PIN limitation for description completion - openExported extends Ruby's OS detection with xdg-open, iTerm, Termux heuristics; comment documents the divergence from Ruby's evince default Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'internal/shell/shell.go')
0 files changed, 0 insertions, 0 deletions