Add zk no neovim
This commit is contained in:
parent
77ec529eee
commit
72f4b407c3
2 changed files with 25 additions and 1 deletions
|
|
@ -987,7 +987,30 @@ require("lazy").setup({
|
|||
}
|
||||
end,
|
||||
dependencies = { {"nvim-tree/nvim-web-devicons"}}
|
||||
}
|
||||
},
|
||||
{
|
||||
"zk-org/zk-nvim",
|
||||
config = function()
|
||||
require("zk").setup({
|
||||
picker = "telescope",
|
||||
})
|
||||
|
||||
local opts = { noremap = true, silent = true }
|
||||
|
||||
-- new note in the current group/dir
|
||||
vim.keymap.set("n", "<leader>zn", "<cmd>ZkNew { title = vim.fn.input('Title: ') }<cr>", opts)
|
||||
-- new note in inbox (no title needed)
|
||||
vim.keymap.set("n", "<leader>zi", "<cmd>ZkNew { dir = 'inbox' }<cr>", opts)
|
||||
-- search notes by title/filename
|
||||
vim.keymap.set("n", "<leader>zf", "<cmd>ZkNotes { sort = { 'modified' } }<cr>", opts)
|
||||
-- search notes by content (full text)
|
||||
vim.keymap.set("n", "<leader>zs", "<cmd>ZkNotes { sort = { 'modified' }, match = { vim.fn.input('Search: ') } }<cr>", opts)
|
||||
-- search tags
|
||||
vim.keymap.set("n", "<leader>zt", "<cmd>ZkTags<cr>", opts)
|
||||
-- insert a link to another note
|
||||
vim.keymap.set("n", "<leader>zl", "<cmd>ZkInsertLink<cr>", opts)
|
||||
end,
|
||||
},
|
||||
}, {
|
||||
ui = {
|
||||
-- If you are using a Nerd Font: set icons to an empty table which will use the
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@ in
|
|||
home.packages = with pkgs; [
|
||||
foliate
|
||||
inputs.locutus.packages.${pkgs.stdenv.hostPlatform.system}.default
|
||||
zk
|
||||
# jrnl
|
||||
# disable tests for now until the bug is fixed
|
||||
# https://github.com/NixOS/nixpkgs/issues/476190
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue