Configurable buffer specific settings for kiwi-wiki #20
mcjvanschaik
started this conversation in
Ideas
Replies: 1 comment
-
Ooh! I like your idea. My mind didn't go through this path since this was just a personal script which I converted to a plugin. Your points are valid and it would make Kiwi more configurable while keeping it's minimal nature. I'll start a new issue as the feature request and add the main points you mentioned. Feel free to add more points in the comments and once that is set, I'll start working on it. Thanks a lot! This was insightful. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I have been using Kiwi for a while now and wanted to have extra buffer-specific keymappings, but I couldn´t figure out the best way to do it.
I have a fork in which I have seperated the repetitive code for keymaps and moved it to a function for buffer settings, and have added my shift-tab keymapping for backward jumping to a link. I could have created a function for just keymappings, but I decided that all buffer specific settings are relevant. I experimented with a conditional setting for treesitter: If it is active, conceallevel = 1. This would create the described environment in the README. So general buffer settings seemed better.
I started thinking about how it should work. The Kiwi philosophy is to focus on core functions and leave additional features to other plugins and standard functionality. Then I realised that all the key mappings should perhaps also be configurable. This would avoid clashing with existing key mappings, which is to be expected with the tab-key, that is also popular for snippet-tools.
At first I thought I might do that using autocommands. But without a filetype, I wasn´t sure if that was a good idea. I believe that it should be possible to make an augroup using file location. This might be interesting to combine with the kiwi-settings.
Then I read that common practice is to make a setup-function that allows default settings to be overridden. That might also be interesting, but I am not experienced with creating lua-functions.
It was interesting to think about this. What do you guys think? How would you empower any user to create a personalized wiki?
Michael
My fork
Beta Was this translation helpful? Give feedback.
All reactions