mirror of
https://github.com/pratiktri/dotfiles.git
synced 2026-02-04 08:41:43 +05:30
feat(nvim): Markdown handling improvements
- marksman: Trimmed config file: removed comments, remove default settings - fix: ftplugin for codelens: provide current buffer - new: Add obsidian.nvim plugin to replace markdown-oxide lsp
This commit is contained in:
@@ -1,36 +1,15 @@
|
||||
[core]
|
||||
|
||||
markdown.file_extensions = ["md", "markdown"]
|
||||
# Configures text sync protocol between the editor (LSP client)
|
||||
# and Marksman (LSP server).
|
||||
# Can be either 'full' or `incremental`:
|
||||
# * full: the whole copy of a document is sent by the editor
|
||||
# on every update,
|
||||
# * incremental: only the changed parts are sent by
|
||||
# the editor. This will result in less trafic between
|
||||
# the editor and Marksman, but the overall performance
|
||||
# impact is marginal.
|
||||
# Defaults to `full` because the editors have bugs in incremental
|
||||
# sync which result in slightly correpted state and are really hard
|
||||
# to diagnose.
|
||||
text_sync = "incremental"
|
||||
# Use incremental resolution of project-wide references.
|
||||
# This is much more efficient but is currently experimental
|
||||
incremental_references = true
|
||||
# For debugging only! Enables extra validation checks around
|
||||
# incremental state updates. SIGNIFICANTLY IMPACTS PERFORMANCE
|
||||
text_sync = "full"
|
||||
title_from_heading = true
|
||||
incremental_references = false
|
||||
paranoid = false
|
||||
|
||||
[code_action]
|
||||
# Enable/disable "Table of Contents" code action
|
||||
toc.enable = true
|
||||
|
||||
# Enable/disable "Create missing linked file" code action
|
||||
create_missing_file.enable = false
|
||||
|
||||
[completion]
|
||||
# The style of wiki links completion.
|
||||
# Other values include:
|
||||
# * "file-stem" to complete using file name without an extension,
|
||||
# * "file-path-stem" same as above but using file path.
|
||||
wiki.style = "title-slug"
|
||||
candidates = 50
|
||||
wiki.style = "file-path-stem"
|
||||
|
||||
@@ -11,7 +11,7 @@ local function check_codelens_support()
|
||||
end
|
||||
|
||||
vim.api.nvim_create_autocmd({ "TextChanged", "InsertLeave", "CursorHold", "LspAttach", "BufEnter" }, {
|
||||
buffer = bufnr,
|
||||
buffer = vim.api.nvim_get_current_buf(),
|
||||
callback = function()
|
||||
if check_codelens_support() then
|
||||
vim.lsp.codelens.refresh({ bufnr = 0 })
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
return {
|
||||
cmd = { "markdown-oxide" },
|
||||
filetypes = { "markdown" },
|
||||
root_dir = function()
|
||||
return vim.fn.getcwd()
|
||||
end,
|
||||
settings = {
|
||||
workspace = {
|
||||
didChangeWatchedFiles = {
|
||||
dynamicRegistration = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
@@ -69,6 +69,30 @@ return {
|
||||
end,
|
||||
},
|
||||
|
||||
{
|
||||
"obsidian-nvim/obsidian.nvim",
|
||||
version = "*",
|
||||
enabled = true,
|
||||
opts = {
|
||||
workspaces = {
|
||||
{
|
||||
name = "personal",
|
||||
path = "~/Code/Notes",
|
||||
},
|
||||
},
|
||||
completions = {
|
||||
blink = true,
|
||||
nvim_cmp = false,
|
||||
},
|
||||
comment = { enabled = true },
|
||||
attachments = { img_folder = ".artifacts/img" },
|
||||
footer = { format = "{{backlinks}} backlinks" },
|
||||
legacy_commands = false,
|
||||
ui = { enable = false },
|
||||
frontmatter = { enabled = false },
|
||||
},
|
||||
},
|
||||
|
||||
{
|
||||
"bullets-vim/bullets.vim",
|
||||
ft = { "markdown", "text", "gitcommit", "scratch" },
|
||||
|
||||
Reference in New Issue
Block a user