Skip to content

v1.2: configurable sidebar keys#11

Open
sebasv wants to merge 1 commit intomainfrom
feat/v1.2-configurable-keys
Open

v1.2: configurable sidebar keys#11
sebasv wants to merge 1 commit intomainfrom
feat/v1.2-configurable-keys

Conversation

@sebasv
Copy link
Copy Markdown
Owner

@sebasv sebasv commented Apr 21, 2026

Summary

[keys] config section lets users remap the top-level sidebar bindings. Stacked on #10.

Navigation (j/k/h/l/Enter), terminal-forwarding, diff-view, and modal keys stay fixed for 1.x.

Test plan

  • 95 tests (+8 keymap parser / roundtrip / match tests)
  • Release build clean

🤖 Generated with Claude Code

@sebasv sebasv mentioned this pull request Apr 21, 2026
3 tasks
@sebasv sebasv force-pushed the feat/v1.2-configurable-keys branch from f5ea56d to 2b52dd3 Compare April 21, 2026 19:54
@sebasv sebasv force-pushed the feat/v1.1-mouse branch 2 times, most recently from 4c0fa62 to 680b48f Compare April 21, 2026 20:35
@sebasv sebasv force-pushed the feat/v1.2-configurable-keys branch from 2b52dd3 to 0212061 Compare April 21, 2026 20:35
@sebasv sebasv force-pushed the feat/v1.2-configurable-keys branch from 0212061 to 699fe50 Compare April 21, 2026 20:41
@sebasv sebasv force-pushed the feat/v1.2-configurable-keys branch from 699fe50 to 0cc5af5 Compare April 21, 2026 21:55
@sebasv sebasv force-pushed the feat/v1.1-mouse branch 2 times, most recently from 20a4e84 to bbb9078 Compare April 22, 2026 20:04
@sebasv sebasv force-pushed the feat/v1.2-configurable-keys branch from 0cc5af5 to 6a398ff Compare April 22, 2026 20:04
@sebasv sebasv force-pushed the feat/v1.1-mouse branch 2 times, most recently from 5ce0faa to b29c354 Compare April 22, 2026 21:30
Base automatically changed from feat/v1.1-mouse to main April 22, 2026 21:31
- `src/keymap.rs`: `KeyChord` with a serde (de)serialise path from the
  human-readable `"Ctrl+q"` / `"Alt+Enter"` / `"F5"` format; robust parsing
  with friendly error messages on unknown modifiers/keys.
- `Keymap` covers seven top-level sidebar actions: quit, help, refresh,
  add_repo, remove_repo, new_worktree, remove_worktree. Each field has a
  serde default so partial `[keys]` overrides are accepted.
- `config.toml` gains `[keys]` section; unset keys fall through to defaults.
- `default_keys` now consults the Keymap first; navigation (j/k/h/l/Enter)
  stays hard-coded.

Eight new unit tests for parsing, round-tripping, deserialisation, and
`matches` behaviour. 95 tests total. Release build clean.

Version 1.2.0.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@sebasv sebasv force-pushed the feat/v1.2-configurable-keys branch from 6a398ff to b8d88ef Compare April 22, 2026 21:44
sebasv added a commit that referenced this pull request Apr 24, 2026
* docs: v1.3 onboarding & unified worktree modals plan

Design doc for the intermediate release slotted between v1.1 and
v1.2 (configurable keys, PR #11). Covers README/CLI cleanup, one-shot
CWD entry, bulk scan, theme persistence, base-branch auto-detect,
GitHub auth surfacing, keybind quirks, and the two unified worktree
modals (create/delete) with auto-fetch before remote-dependent ops.

Proposes 5 independent PRs off main.

Co-Authored-By: Claude <noreply@anthropic.com>

* docs: revise v1.3 plan — activity system & unified entry

Rework after review feedback:

- Combine `grove [<path>]` with the old `grove scan` into one entry
  point that dispatches on whether `path` is itself a repo or a
  parent directory. Replaces two CLI shapes with one.
- Replace "sync fetch before remote-sensitive workflow" with a
  periodic background fetch scheduler. Keypress paths stay local; the
  cache is kept warm.
- New explicit non-blocking-UX contract: no keypress blocks on I/O;
  modals render from cache immediately; spinners surface any async
  work.
- New activity footer at the bottom of the sidebar reports whatever
  background tasks are in-flight (fetch, PR poll, status refresh,
  scan). GitHub auth warning reuses the same row when idle.
- Introduce PR 2 (activity + sync infra) as a prerequisite for the
  new-worktree modal and auth indicator.
- Renumber downstream PRs: 3 = unified entry, 4 = persistence + auth,
  5 = new-worktree modal, 6 = delete modal.

Co-Authored-By: Claude <noreply@anthropic.com>

* docs: v1.3 plan — input styling + contextual delete modal

Two additions after review feedback:

- New PR 2: theme gains an input-field background colour; text_input
  widget and existing modals adopt it so users see where typing will
  land. Lands early so the unified new-worktree modal (now PR 6) is
  styled from the start. Renumber downstream PRs.

- Rework the delete-worktree modal (now PR 7): instead of exposing
  both -d and -D as menu options, check if the branch is merged into
  its base and offer only the contextual variant. Keys are absolute
  (`d` for regular delete, `D` for force delete, `k`/Enter for keep,
  `Esc` for cancel) rather than arrow-navigable, so muscle-memory
  Enter cannot accidentally destroy work. Capital `D` deliberately
  raises the barrier to force-delete.

Co-Authored-By: Claude <noreply@anthropic.com>

---------

Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant