dotfiles/dot_config/nvim/lua/plugins/notes.lua.tmpl

82 lines
2.8 KiB
Cheetah
Raw Normal View History

2023-10-13 21:54:13 +02:00
return {
{
"renerocksai/telekasten.nvim",
lazy = true,
dependencies = {
"nvim-telescope/telescope.nvim",
"renerocksai/calendar-vim",
},
opts = {
take_over_my_home = true,
2024-04-04 21:27:51 +02:00
auto_set_filetype = false,
2024-02-15 09:53:19 +01:00
home = "{{ .home }}/doc/zettelkasten",
dailies = "{{ .home }}/doc/zettelkasten/daily",
weeklies = "{{ .home }}/doc/zettelkasten/weekly",
templates = "{{ .home }}/doc/zettelkasten/templates",
2023-10-13 21:54:13 +02:00
image_subdir = "img",
extension = ".md",
new_note_filename = "uuid-title",
uuid_type = "%Y%m%d%H%M",
uuid_sep = "-",
follow_creates_nonexisting = true,
dailies_create_nonexisting = true,
weeklies_create_nonexisting = true,
journal_auto_open = false,
-- template for new notes (new_note, follow_link)
-- set to `nil` or do not specify if you do not want a template
2024-02-15 09:53:19 +01:00
template_new_note = "{{ .home }}/doc/zettelkasten/templates/new_note.md",
2023-10-13 21:54:13 +02:00
-- template for newly created daily notes (goto_today)
-- set to `nil` or do not specify if you do not want a template
2024-02-15 09:53:19 +01:00
template_new_daily = "{{ .home }}/doc/zettelkasten/templates/daily.md",
2023-10-13 21:54:13 +02:00
-- template for newly created weekly notes (goto_thisweek)
-- set to `nil` or do not specify if you do not want a template
2024-02-15 09:53:19 +01:00
template_new_weekly = "{{ .home }}/doc/zettelkasten/templates/weekly.md",
2023-10-13 21:54:13 +02:00
-- image link style
-- wiki: ![[image name]]
-- markdown: ![](image_subdir/xxxxx.png)
image_link_style = "wiki",
-- default sort option: 'filename', 'modified'
sort = "filename",
-- integrate with calendar-vim
plug_into_calendar = true,
calendar_opts = {
weeknm = 4,
calendar_monday = 1,
calendar_mark = "left-fit",
},
close_after_yanking = false,
insert_after_inserting = true,
tag_notation = "#tag",
command_palette_theme = "dropdown",
show_tags_theme = "ivy",
subdirs_in_links = true,
template_handling = "smart",
new_note_location = "smart",
rename_update_links = true,
follow_url_fallback = nil,
},
keys = {
{ "<leader>zf", "<cmd>Telekasten find_notes<cr>" },
{ "<leader>zd", "<cmd>Telekasten find_daily_notes<cr>" },
{ "<leader>zg", "<cmd>Telekasten search_notes<cr>" },
{ "<leader>zz", "<cmd>Telekasten follow_link<cr>" },
{ "<leader>zn", "<cmd>Telekasten new_note<cr>" },
{ "<leader>zr", "<cmd>Telekasten rename_note<cr>" },
{ "<leader>zc", "<cmd>Telekasten show_calendar<cr>" },
{ "<leader>#", "<cmd>Telekasten show_tags<cr>" },
{ "<leader>z", "<cmd>Telekasten panel<cr>" },
},
init = function()
vim.api.nvim_set_hl(0, "tklink", { fg = "#689d6a", bg = "" })
vim.api.nvim_set_hl(0, "tkBrackets", { fg = "gray", bg = "gray" })
end,
},
}