Commit Graph

30 Commits

Author SHA1 Message Date
swanadiva 43858dda87 feat: TUI Key & Snippet Management - Task 19
- KeyListTab: view/add/edit/delete SSH keys (Ctrl+K from host list)
- KeyFormTab: add/edit key form with name, type, private key, passphrase
- SnippetListTab: view/add/edit/delete snippets (Ctrl+P from host list)
- SnippetFormTab: add/edit snippet form with name, command, description, tags
- Updated status bar with new hints
- Save/delete commands for both key pairs and snippets
2026-06-23 15:10:20 +07:00
swanadiva 94ec00c303 feat: TUI SFTP Browser Tab - Task 18
- SFTPBrowserTab with remote directory browsing
- Open via Ctrl+F from host list
- Navigate dirs, filter with /, refresh with r
- Dir/icon display with file sizes
- Sort dirs first, then by name
2026-06-23 15:08:22 +07:00
swanadiva 3dc482e353 feat: TUI Host Forms (add/edit) - Task 17
- HostFormTab with textinput fields for all host fields
- Add (Ctrl+N) and Edit (Ctrl+E) from host list
- Save to JSON storage, auto-reload on save
- Esc to cancel, navigable form with keyboard
2026-06-23 15:05:08 +07:00
swanadiva 809ac1d2e8 fix: session tab I/O — stdin direct write, pollSession triggers re-render 2026-06-23 14:59:48 +07:00
swanadiva 98dfc1c79c feat: Task 16 — SSH Session Tab (multi-session)
- pkg/tui/session.go — SessionTab with live SSH terminal in a tab
- pkg/tui/messages.go — quitMsg, openSessionMsg, sessionOutputMsg
- pkg/tui/tabs.go — Tab.Close() interface, Add() returns tea.Cmd
- pkg/tui/host_list_tab.go — Enter opens session tab, q quits
- pkg/tui/tui.go — handle openSessionMsg/quitMsg, SetDataDir
- cmd/hostkeeper/tui.go — pass dataDir to model
2026-06-23 14:54:44 +07:00
swanadiva 5d9e38f8db feat: Task 15 — TUI Tab Framework + Orange Theme
- pkg/tui/styles.go — orange theme palette and component styles
- pkg/tui/tabs.go — Tab interface + TabManager with add/close/next/prev
- pkg/tui/host_list_tab.go — HostListTab implementing Tab interface
- pkg/tui/tui.go — refactored to use TabManager (backward compatible)
- pkg/tui/host_list.go — removed (logic moved to host_list_tab.go)
- pkg/tui/tui_test.go — adapted + added TabManager tests
2026-06-23 14:51:13 +07:00
swanadiva c5cc3bd711 docs: add Phase 2 tasks 15-19 (TUI Overhaul) to implementation plan 2026-06-23 14:48:32 +07:00
swanadiva e8c451ed56 docs: restructure Phase 2 (TUI priority) + update Phase 3 2026-06-23 14:47:47 +07:00
swanadiva e99a6ac347 docs: rewrite TUI Layer — tab system, orange theme, multi-session SSH 2026-06-23 14:47:30 +07:00
swanadiva 9c1bbd4eac docs: update Key Design Principles — TUI-First + Orange Theme 2026-06-23 14:47:12 +07:00
swanadiva 933ee48f3f docs: update Key Design Decisions — TUI-first architecture 2026-06-23 14:46:55 +07:00
swanadiva b3878de9af feat: Go SSH interactive shell default, --native flag for system SSH 2026-06-23 14:26:58 +07:00
swanadiva 513492e6ee feat: add short ID column to list, improve connect error with hint 2026-06-23 14:23:11 +07:00
swanadiva 1869cff590 fix: host lookup by hostname, interactive input with spaces 2026-06-23 14:16:49 +07:00
swanadiva 48c858df0f feat: complete MVP — all 14 tasks done
- Task 13: Full documentation (README, INSTALLATION, USAGE, ARCHITECTURE)
- Task 14: Release prep (CHANGELOG, RELEASE_CHECKLIST)
- Update PROJECT_STATE.md to reflect 100% completion
v1.0.0
2026-06-23 14:06:31 +07:00
swanadiva c2d6aabea0 feat: add build system and integration tests
- Update Makefile with test-coverage and verify targets
- Add build.sh script for cross-platform builds with SHA256 checksums
- Implement integration tests for full workflow (add/list/get/update/export/delete)
- Add config integration test
- Update project state documentation
2026-06-23 14:03:08 +07:00
swanadiva 30b57f6084 feat: implement export and import commands
- Add export command with JSON file output and size summary
- Add import command with replace/merge strategies and dry-run preview
- Add integration test for export/import round-trip via storage layer
- Update project state documentation
2026-06-23 13:58:51 +07:00
swanadiva fbe444c3ab feat: implement basic TUI framework with host list
- Add Bubble Tea TUI model with Init/Update/View
- Implement host list screen with keyboard navigation (up/down/enter/q)
- Add styled rendering for hosts, selection, tags
- Create hostkeeper tui CLI command
- Add tests for TUI initialization and host loading
- Update project state documentation
2026-06-23 13:54:49 +07:00
swanadiva d6b810de47 feat: implement edit and delete host commands
- Add edit command with flag-based and interactive update modes
- Add delete command with confirmation prompt and --force flag
- Include delete alias 'rm' for convenience
- Add comprehensive tests for both commands
- Update project state documentation
2026-06-23 13:52:10 +07:00
swanadiva 368b7cdadb feat: implement connect host command with native SSH
- Add connect command with native SSH (default) and direct Go SSH (--direct) modes
- Support host lookup by name or ID
- Build SSH arguments for system SSH client
- Include timeout configuration flag
- Add comprehensive tests for command and SSH arg building
- Update project state documentation
2026-06-23 13:48:05 +07:00
Swana Diva Borneos 4087c5fdc7 feat: add & list commands with deadlock fix
- Add 'add' command: register hosts via flags or interactive prompts
  Supports password/key/both auth, groups, tags, notes, port override
- Add 'list' command: display hosts with filtering and formatting
  Supports --group, --tag filters, --sort, table/json/wide output
- Fix deadlock bug in JSON storage (RLock within Lock)
  Introduced internal list functions that don't lock
  Affects: ListHosts/GetHost/SaveHost/DeleteHost + KeyPair + Snippet
- Add comprehensive tests for add and list commands
- Update PROJECT_STATE.md (Tasks 1-8 complete, ~55% done)
2026-06-23 10:56:04 +07:00
swanadiva 7dfe181b97 docs: update PROJECT_STATE.md - Task 6 complete (CLI Framework Setup)
- Mark Task 6 (CLI Framework Setup) as complete
- Update completion matrix: CLI Framework 100%, Testing ~30%
- Update overall progress to ~45%
- Mark Milestone 1 (Foundation) as COMPLETE
- Update sprint tracking and roadmap
2026-06-22 16:23:27 +07:00
swanadiva 2bb9d18f57 feat: Implement CLI framework with Cobra
- Add root command with Cobra framework
- Implement shell completion support for bash/zsh/fish/powershell
- Add version command
- Add configuration initialization on startup via PersistentPreRunE
- Include verbose (-v/-vv) and debug flags
- Set up proper error handling and exit codes

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-22 16:21:43 +07:00
swanadiva 8ea4b6e990 feat: Implement SSH client with authentication support (Task 5)
- Add SSH client with Connect/Execute/Close/IsConnected
- Implement password, key, and both authentication methods
- Support default key discovery (~/.ssh/id_ed25519, id_rsa, etc.)
- Support passphrase-protected keys via ParsePrivateKeyWithPassphrase
- Path expansion for ~ in KeyID
- Integrate with HandleSSHError for user-friendly errors
- All 4 SSH tests passing + 5 error tests still passing (9 total)

Progress: Tasks 1-5 complete (~40%)
2026-06-22 16:16:16 +07:00
swanadiva 6fd25e4d02 feat: Implement error handling framework (Task 4)
- Add AppError with error codes and hints system
- Implement ConnectionError for SSH-specific errors
- Add HandleSSHError for intelligent SSH error parsing
- Add FormatConnectionError for user-friendly output
- All 5 test functions passing (TestAppError, TestConnectionError,
  TestHandleSSHError, TestHandleSSHErrorNil, TestFormatConnectionError)
- Update PROJECT_STATE.md to reflect Task 4 completion

Progress: Tasks 1-4 complete (~30%)
2026-06-22 16:12:28 +07:00
swanadiva 33947816b7 feat: complete Tasks 1-3 (setup, models+storage, config management)
- Task 1: Project setup (go.mod, Makefile, .gitignore, main.go)
- Task 2: Core data models (Host, KeyPair, Snippet, AppConfig) + JSON storage layer
- Task 3: Configuration management with cross-platform path support (macOS/Linux/Windows)
- Updated PROJECT_STATE.md with progress tracking
2026-06-22 16:09:02 +07:00
swanadiva 0b0b4ebcbf docs: Add multi-session/LLM continuity references
- Update README.md to prioritize PROJECT_STATE.md for new agents
- Add handoff instructions to implementation plan header
- Ensure any agent/LLM knows to check current status first
- Create clear documentation hierarchy for handoffs
- Fix markdown formatting issues

This ensures any AI agent or human developer can immediately
understand project state and continue work without confusion.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-22 15:49:21 +07:00
swanadiva 0dc6e62b85 docs: Add comprehensive project state tracking and handoff guide
- Create PROJECT_STATE.md for seamless agent/session continuity
- Include current completion status matrix (0% complete, planning done)
- Add detailed implementation task status with dependencies
- Provide quick start guide for new agents/LLMs
- Include handoff procedures for both new and returning agents
- Add testing strategy, debugging guides, and progress tracking
- Enable any agent to continue development without prior context
- Maintain roadmap and milestone tracking
- Cross-reference all documentation for easy navigation

This ensures any LLM/agent can immediately understand project state
and continue implementation from where previous session ended.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-22 15:46:31 +07:00
swanadiva 190c623488 docs: Add comprehensive implementation plan for Hostkeeper MVP
- Create 14 detailed implementation tasks with step-by-step instructions
- Include TDD approach with test-first development
- Add exact file paths, code examples, and commands
- Cover all core features: SSH client, storage, CLI commands, TUI
- Include comprehensive testing and build system
- Add cross-platform build instructions
- Provide release preparation checklist
- Estimate 3-4 weeks development time for MVP

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-22 15:39:49 +07:00
swanadiva ddd3c666c3 docs: Add comprehensive Hostkeeper design document
- Architecture overview: Monolithic CLI with embedded TUI
- Component details: Command, TUI, Core Engine, Storage layers
- Data flow and workflows for all major operations
- Security architecture for Phase 1 (MVP) and Phase 2
- Error handling strategy and recovery procedures
- Cross-platform support strategy
- Implementation phases and success criteria

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-22 14:58:20 +07:00