Skip to content

Feature: Support soft resets and checkouts (non-destructive modes) #17

@dinakars777

Description

@dinakars777

Currently, pressing Enter performs a git reset --hard, which is totally destructive if you have uncommitted changes you forgot about.

We should add alternative keybindings for safer operations:

  • Press s for git reset --soft (keeps working tree intact)
  • Press c for git checkout <hash> (puts you in a detached HEAD state to look around)

Implementation thoughts:

  • Should be pretty straightforward by duplicating the current Command::new("git") logic and mapping it to the new Crossterm keys in src/main.rs.
  • Need to update the footer/help text to display these options.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions