Canop / broot

A new way to see and navigate directory trees : https://dystroy.org/broot
MIT License
10.68k stars 234 forks source link

Define hardcoded shortcuts inside verbs.hjson #920

Open adriangalilea opened 2 months ago

adriangalilea commented 2 months ago

It would be great to have the default shortcuts on verbs.hjson so we can modify them.

Is there any reason not to?

I mean things like alt-enter so we can choose shift-enter for instance.

Even things like esc tho I think it may be a bit trickier due it's logic I would like to alter the esc logic to:

When I press esc from the first match(initial location) I would like to actually trigger exit. (perhaps this needs to be it's own github issue.)

Canop commented 2 months ago

Is there any reason not to?

The application is always changing, features, and shortcuts, are always added, but the config file isn't changed everytime.

I mean things like alt-enter so we can choose shift-enter for instance.

The doc explains how you can define a new binding for this action, and other ones. See https://dystroy.org/broot/conf_verbs/

When I press esc from the first match(initial location) I would like to actually trigger exit. (perhaps this needs to be it's own github issue.)

There's a specific setting for that: https://dystroy.org/broot/conf_file/#quit-on-last-cancel

adriangalilea commented 2 months ago

Is there any reason not to?

The application is always changing, features, and shortcuts, are always added, but the config file isn't changed everytime.

Haven't thought of that, good point.

I mean things like alt-enter so we can choose shift-enter for instance.

The doc explains how you can define a new binding for this action, and other ones. See https://dystroy.org/broot/conf_verbs/

Problem is, that I can't use alt-enter, I surely can map another keybinding for that action, but the help line on broot will forever read "alt-enter to open and quit" which is not valid for me, so it may confuse me if I use broot some time in the future.

Can't think of a clean solution then considering what you just told me.

When I press esc from the first match(initial location) I would like to actually trigger exit. (perhaps this needs to be it's own github issue.)

There's a specific setting for that: https://dystroy.org/broot/conf_file/#quit-on-last-cancel

Added to the conf, thanks.