-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve key mappings example #18
Conversation
d42462f
to
8e4aa41
Compare
Looks good overall. I have some thoughts, but have no time right now. I'll let you know in the evening. |
@kabouzeid Do you want to address some stuff with this PR? |
Some mappings, like for example In the case of --- in main config
vim.api.nvim_set_keymap("n", "<leader>zn", "<Cmd>ZkNew { title = vim.fn.input('Title: ') }<CR>", opts)
--- ~/.config/nvim/ftplugin/markdown.lua
if require("zk.util").notebook_root(vim.fn.expand('%:p')) ~= nil then
-- overwrite with a more specific mapping
vim.api.nvim_buf_set_keymap(0, "n", "<leader>zn", "<Cmd>ZkNew { dir = vim.fn.expand('%:p:h'), title = vim.fn.input('Title: ') }<CR>", opts)
end |
You're perfectly right, I updated the README and fixed your other comments as well. Thanks! |
lgtm :) |
Clarify the key mappings example, including the basic LSP ones.
See #17