Skip to content

bug: fish cannot set multiple binds for the same key but different modes #8795

@DerRockWolf

Description

@DerRockWolf

Are you following the right branch?

  • My Nixpkgs and Home Manager versions are in sync

Is there an existing issue for this?

  • I have searched the existing issues

Issue description

I want to remove the default ctrl+v keybinds and because I'm using fish_vi_key_bindings I need to do:

binds."ctrl-v" = {
  erase = true;
  operate = "preset";
};

multiple times, once per mode: default, insert & visual.

This is currently not possible without extending functions.fish_user_key_binds manually, because the attrset key is used.
To fix this, it's often enough to add an additional key / name option that is used instead of the attrset key if not null. This is also already the case for shellAbbrs.


On that note: at least visual is missing from the mode option enum.

Maintainer CC

@SandWoodJones @9ary @fmway

System information

Not relevant

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugtriageIssues or feature request that have not been triaged yet

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions