Replies: 3 comments 1 reply
-
Well the whole point was to allow the user to order their help menu. The ordering doesn't impact the functioning of those commands in any way but it's a helpful guide to ordering the help menu rather than just sorting it randomly. |
Beta Was this translation helpful? Give feedback.
-
I think this could be done in a way that is in line with the TOML specification. Maybe by allowing keybindings to not only take lists and strings, but also sets. This approach would also expand upon the features of having a minor mode. A keybind like this [keys.normal]
D = ["ensure_selections_forward", "extend_to_line_end"] Works exactly as intended, it selects to the current line's end. However, with sets, this would look like [keys.normal]
D = {
label = "Select to Line End",
position = 2,
command = ["ensure_selections_forward", "extend_to_line_end"],
hidden = false,
} Now, in the minor mode help menu an entry called D labelled "Select to Line End" will be displayed in the second position. More options could be introduce to allow users to create their own Helix "distributions" similar to how NeoVim has AstroNVim or LazyVim. And yes, I do believe a distribution can be created by simply combining different Helix recipies scattered across the internet (for example the yazi and lazygit integration, git blame for current line using command expansion etc.) I'm aware that Helix aims to keep configuration to a minimum (in the user's space, anyway) but this enhancement would offer fine grain control to people who desire it. Please turn this issue into a discussion. |
Beta Was this translation helpful? Give feedback.
-
this is fine grained control which is not something helix is likely to support having a feature rely on the order of the keys in a TOML record is fine, as long as it works consistently, if the functionality is purely cosmetic |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Messy title, however I cannot think of a way to make it more concise, sorry.The order of the keybindings in a minor mode help menu relies on the order of the TOML keys. This behvaiour is helpful; however, TOML specification states that the keys are not in any order, meaning a config with transposed keys should produce the exact same behaviour.
This issue mostly came up in my NixOS configuration as the Nix TOML generator alphabetically sorts the keys I write in Nix. Ref: nix-community/home-manager#6575
Beta Was this translation helpful? Give feedback.
All reactions