chipsenkbeil / org-roam.nvim

Port of org-roam to neovim using orgmode
MIT License
107 stars 9 forks source link

feat: provide keybinding prefix option #47

Closed seflue closed 4 months ago

seflue commented 4 months ago

Allows to conveniently rebind the prefix of most of the plugins key mappings without having to change them all explicitly. Resolves #46.

seflue commented 4 months ago

@chipsenkbeil If you are ok with this change, I will also adjust the documentation before merging. While I'm already on it: Should I streamline the documentation (inconsistent use of <Leader> and <LocalLeader>)?

chipsenkbeil commented 4 months ago

@chipsenkbeil If you are ok with this change, I will also adjust the documentation before merging. While I'm already on it: Should I streamline the documentation (inconsistent use of <Leader> and <LocalLeader>)?

The documentation was just to show what you could change the value to be. So if you look through it, I purposely chose a different value for each config setting to show you could change it. If that's confusing, happy to have it be changed to reflect what the current value is in the examples instead.

seflue commented 4 months ago

@chipsenkbeil If you are ok with this change, I will also adjust the documentation before merging. While I'm already on it: Should I streamline the documentation (inconsistent use of <Leader> and <LocalLeader>)?

The documentation was just to show what you could change the value to be. So if you look through it, I purposely chose a different value for each config setting to show you could change it. If that's confusing, happy to have it be changed to reflect what the current value is in the examples instead.

Ah, this was my sloppy mistake. I actually found the occurance of via grep and didn't look at the context. :sweat_smile:

I am unsure now how to treat the prefix notation in the overall documentation. Now, that all bindings can be adjusted as shown in the examples with just one change, it feels a bit redundant to show it for every binding as example. This could be shortened with just providing the key for the bindings table. I am also not sure, if we should replace <Leader>n within the documentation with <prefix>n. If you just want to look up, how to trigger the command, the first is more helpful, if you want to know, how it is affected by adjusting the prefix, the latter is better.

Please have a look at the current documentation, I am very open to suggestions how to adjust it.

chipsenkbeil commented 4 months ago

If you just want to look up, how to trigger the command, the first is more helpful,

I believe this is what nvim-orgmode does. Regardless, I prefer showing something like <Leader>nc versus <prefix>c in documentation and explanations. Being able to change all of them using <prefix> is just a nice to have. 😄

I wouldn't even bother including it in the table, to be honest. Instead, I'd just have a footnote saying that you can change all bindings at once using the prefix config setting.

seflue commented 4 months ago

Thanks. You actually inspired me to make the docs even more explicit.