1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-01-23 20:10:05 +08:00
SpaceVim/bundle/vim-zettelkasten/plugin/zettelkasten.lua

24 lines
910 B
Lua
Raw Normal View History

--=============================================================================
-- zettelkasten.lua --- init plugin for zk
2023-03-26 13:44:47 +08:00
-- Copyright (c) 2016-2023 Wang Shidong & Contributors
-- Author: Wang Shidong < wsdjeg@outlook.com >
-- URL: https://spacevim.org
-- License: GPLv3
--=============================================================================
2024-12-10 22:45:40 +08:00
vim.cmd([[command ZkNew :lua require('zettelkasten').zknew({})]])
2024-12-10 22:45:40 +08:00
vim.cmd([[command ZkListTemplete :Telescope zettelkasten_template]])
vim.cmd([[command ZkListTags :Telescope zettelkasten_tags]])
2024-07-05 23:11:59 +08:00
2024-12-10 22:45:40 +08:00
vim.api.nvim_create_user_command('ZkBrowse', function(opt)
require('zettelkasten.browser').browse(opt.fargs)
end, { nargs = '*' })
_G.zettelkasten = {
2024-12-10 22:45:40 +08:00
tagfunc = require('zettelkasten').tagfunc,
completefunc = require('zettelkasten').completefunc,
zknew = require('zettelkasten').zknew,
zkbrowse = function()
vim.cmd('edit zk://browser')
end,
}