Closed directormac closed 1 year ago
I removed the "d" keys on hint and resetting keys did the trick for now but hoing youd have a fiix on it.
Please try out the latest version and try whether it works now.
The default config works smooth now, but the "gk" and "gj" isn't triggering the hardtime for some unknown reasons, was working sometimes like a week ago.
the "d" now shows which-key menu but i think reset is triggering from what "dd" should do.
The default config works smooth now, but the "gk" and "gj" isn't triggering the hardtime for some unknown reasons, was working sometimes like a week ago.
Do you mean pressing gkgkgk
doesn't trigger hardtime?
Pressing gk and gj directly triggers hard time, but on some frameworks they remapped j
to gj
and and k
to gk
.
The yanking yy and deleting entire line with dd only opens the whichkey menu now but not doing any actions.
Can you provide your mapping of gj and gk? Or are you using the default config of LazyVim?
The default one from lazyvim, i believe this is it.
-- better up/down
map({ "n", "x" }, "j", "v:count == 0 ? 'gj' : 'j'", { expr = true, silent = true })
map({ "n", "x" }, "k", "v:count == 0 ? 'gk' : 'k'", { expr = true, silent = true })
This mapping works for me. Do you have any other config that might override this?
I will check it out soon and setup a fresh install with lazyvim and only use your plugin.
Thanks a lot.
d and key are doing its job, it's just not showing the whichkey menu, maybe its because of the delays set on which-key by default at lazyvim i am not sure tho, Thank you for fixing that! 🤖
I tried remapping j and k but hardtime isn't detecting it. vim.keymap.set({ "n", "v" }, "j", "j", { noremap = true }) vim.keymap.set({ "n", "v" }, "k", "k", { noremap = true })
Do you set the keymap before the plugin's setup? If yes, try to set the keymap after that.
@m4xshen, just to let you know, I'm facing the same problem.
Do you mean that gj and gk don't trigger hardtime? Do you also use LazyVim or use custom map for j and k?
@directormac please try out the latest version. Thanks.
Do you mean that gj and gk don't trigger hardtime? Do you also use LazyVim or use custom map for j and k?
I just use a custom map
vim.keymap.set("n", "k", "v:count == 0 ? 'gk' : 'k'", { noremap = true, expr = true, silent = true })
vim.keymap.set("n", "j", "v:count == 0 ? 'gj' : 'j'", { noremap = true, expr = true, silent = true })
I just use a custom map
vim.keymap.set("n", "k", "v:count == 0 ? 'gk' : 'k'", { noremap = true, expr = true, silent = true }) vim.keymap.set("n", "j", "v:count == 0 ? 'gj' : 'j'", { noremap = true, expr = true, silent = true })
After setting the keymap, the j and k don't trigger hardtime?
I just use a custom map
vim.keymap.set("n", "k", "v:count == 0 ? 'gk' : 'k'", { noremap = true, expr = true, silent = true }) vim.keymap.set("n", "j", "v:count == 0 ? 'gj' : 'j'", { noremap = true, expr = true, silent = true })
After setting the keymap, the j and k don't trigger hardtime?
Trying out hardline for the first time now. Hardtime fails to trigger with this keymap.
Trying out hardline for the first time now. Hardtime fails to trigger with this keymap.
What Neovim version are you using? I can't reproduce the issue. Also do you load the plugin first or set the keymap first?
Also do you load the plugin first or set the keymap first?
Yup, that was the issue. Good shout.
This fixes it by making hardtime
load after my keymaps:
return {
{
"m4xshen/hardtime.nvim",
+ event = "VeryLazy",
opts = {}
},
}
Thank you very much!
Also do you load the plugin first or set the keymap first?
Yup, that was the issue. Good shout.
This fixes it by making
hardtime
load after my keymaps:return { { "m4xshen/hardtime.nvim", + event = "VeryLazy", opts = {} }, }
I tried doing this still j and k with gk and gj rebinding from lazyvim does not trigger hardtime, thanks @m4xshen you fixed it finally i mised hardtime for the past few days.
LazyVim Discussion Reference