Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fix edit file key binding (alt-e) in diff and add #415

Merged
merged 1 commit into from
Dec 22, 2024
Merged

Conversation

wfxr
Copy link
Owner

@wfxr wfxr commented Dec 21, 2024

Check list

  • I have performed a self-review of my code
  • I have commented my code in hard-to-understand areas
  • I have made corresponding changes to the documentation

Description

The key binding alt-e for editing a file in diff and add was not working properly on recent versions of fzf. As its documentation suggests, we should replace execute-silent with execute since we need to switch to a new screen and handle both input and output.

fzf switches to the alternate screen when executing a command. However, if the command is expected to complete quickly, and you are not interested in its output, you might want to use execute-silent instead, which silently executes the command without the switching.

Type of change

  • Bug fix
  • New feature
  • Refactor
  • Breaking change
  • Documentation change

Test environment

  • Shell
    • bash
    • zsh
    • fish
  • OS
    • Linux
    • Mac OS X
    • Windows
    • Others:

The key binding for editing a file in diff and add was not working
properly on recent versions of fzf. As its documentation suggests, we
should replace `execute-silent` with `execute` since we need to switch
to a new screen and handle both input and output.

> fzf switches to the alternate screen when executing a command.
> However, if the command is expected to complete quickly, and you are
> not interested in its output, you might want to use execute-silent
> instead, which silently executes the command without the switching.
Copy link
Collaborator

@sandr01d sandr01d left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can confirm the issue and the fix

@wfxr wfxr merged commit df51911 into main Dec 22, 2024
7 checks passed
@wfxr wfxr deleted the fix-alt-e branch December 22, 2024 01:18
@sandr01d sandr01d mentioned this pull request Dec 31, 2024
15 tasks
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.

3 participants