neorg
neorg copied to clipboard
default key bindings mess up with vim defaults
Contributions
- [X] I have read contribution guidelines
Plugin Version
- [X] I am using the latest version of the plugin
Neovim Version
- [X] I am using either 0.5 stable or the latest compiled 0.6 version
Neovim Version
v0.7.0-dev+667-g419e0d117
Log Output
No response
Branch
unstable
Loaded modules
telescope
Expected behavior
I expect standard gt
binging to switch to the next tab.
Actual behavior
instead I get which-key
popup for the 3 neorg bindings gtd
, gtu
, gtp
.
I realize, that without whch-key
It would probably work after a timeout, it's still I think not a good idea to mask such a standard mapping.
Potentially conflicting plugins
No response
Other information
No response
Help
No response
Implementation help
No response
Good call! We'll be remapping these soon then. I'll let you know when we do :)
Bringing up this discussion once again since I just came across this issue. As a new neorg user what is my workflow supposed to look like? Since calling NeorgStart
or changing to a workspace changes my pwd
I would want to do this in a separate tab. These default mappings (plus which-key) prevent me from jumping back and forth to the previous tab I had. Personally, they also feel a little cumbersome to hit (ex. gtd
on a qwerty keyboard). Open to creating a pr if we can come to better defaults, or removing them and letting the user decide (with docs).
Thanks for all the work on this great plugin by the way! I want this to be my default note taker.
Ps: any tips on being able to sync and edit on mobile? Thanks once again
Fair! I'd like to change some of the defaults as well. Do you guys have any specific keybind in mind? I'd like for the keybinds to still act like mnemonics. Vim-specific keys (like overriding C-]
, etc.) would be an addition (maybe toggleable, or a different keybind preset altogether?). Down to discuss this sort of stuff.
The problem is that there are a lot of different task states we need to create default mappings for. I have never used emacs so I don't know how this is handled in org-mode, but I'm for not creating default mappings for most of these but instead give the user the ability to easily set the keymaps they want (through documentation and similar methods).
Instead maybe a single keymap that toggles through the most common scenarios: ex. UNDONE -> PENDING -> DONE. In which case some popular mappings might be <tab>
, <space>
, etc.... Possibly only have these mappings trigger on a todo line (through tree-sitter)?
Another option/addition can be a todo/task mode (entered by <localleader>mt
that lets you jump through todo's and change their states with single key mappings.
Just throwing some thoughts/ideas out there, would love to get some feedback and ideas for this.
Well FYI C-space is already mapped to such a toggle (TODO -> PENDING -> UNDONE), so it's just a matter of making the specific keybinds easy-ish to remember.
Hi, I've just faced the same issue with gt
not working as expected.
Apart from changing the keybindings, one other way to prevent the override could be to have a setting that will prepend the leader key to all normal mode keybindings (or most of them). I think this might be a relatively unobtrusive change that could improve the new user experience.
Is there a way at least disable keybinds entirely, so I can define my own and be happy with it? I have default_keybinds = false
in my require('neorg').setup
but this seems take no effect (or not affect every keybinds) since I still can't use 'gt' for tabs and sometimes my keybinding for switching buffers - 'Alt-j/k' start act like go to link or something (second one can be temporarely fixed by enter/exit command mode with colon-Esc)
use {
"nvim-neorg/neorg",
config = function()
require('neorg').setup {
load = {
["core.defaults"] = {}, -- Loads default behaviour
["core.keybinds"] = { -- Loads default behaviour
config = {
default_keybinds = false,
}
},
["core.norg.concealer"] = {}, -- Adds pretty icons to your documents
["core.norg.completion"] = { -- Adds completion support for Neorg
config = {
engine = 'nvim-cmp',
},
},
["core.norg.dirman"] = { -- Manages Neorg workspaces
config = {
workspaces = {
notes = "~/Notes",
},
default_workspace = "notes",
},
},
},
}
end,
run = ":Neorg sync-parsers",
requires = "nvim-lua/plenary.nvim",
}
I know that the wiki says that it's not supported, but at least as a workaround to completely disable keybinds you can try setting this :
['core.keybinds'] = {
config = {
keybind_preset = 'none'
}
}
Here I've set it to 'none', but the important part is that it should not be 'norg' (or 'neorg', I'm not sure).
"We'll be remapping these soon", and then I forgot for one and a quarter of a year :rofl:, sorry! I'm considering remapping these to <LocalLeader>t*
instead of gt*
. I assume this makes the most sense, right?
And after so long this has finally been fixed as of 4.0.0
! Please use <LocalLeader>t
as your prefix instead :)