This commit is contained in:
2025-08-31 17:59:46 +02:00
parent 6d16c65e7b
commit 8b330e7f4a
8 changed files with 76 additions and 45 deletions

View File

@@ -14,6 +14,9 @@ vim.keymap.set("n", "<C-s>", "<cmd>noautocmd w <CR>", opts)
-- quit file
vim.keymap.set("n", "<C-q>", "<cmd> q <CR>", opts)
-- activate spelling
vim.keymap.set("n", "<leader>sp", ":set spell!<CR>")
-- delete single character without copying into register
vim.keymap.set("n", "x", '"_x', opts)

View File

@@ -36,7 +36,7 @@ return {
}
dashboard.section.buttons.val = {
dashboard.button("<CR>", " Select Session", ":SessionSearch <CR>"),
dashboard.button("<CR>", " Select Session", ":AutoSession search <CR>"),
dashboard.button("<leader>ff", " Open file", ":Neotree float <CR>"),
dashboard.button("<leader>fr", " Open recent files.", ":Telescope oldfiles <CR>"),
}

View File

@@ -189,6 +189,7 @@ return {
yamlls = {},
clangd = {},
ocamllsp = {},
tinymist = {},
lua_ls = {
-- cmd = {...},

View File

@@ -18,8 +18,8 @@ return {
"shfmt", -- Shell formatter
"checkmake", -- linter for Makefiles
"ruff", -- Python linter and formatter
"clangd",
"ocamlformat",
"clangd", -- c/cpp formatter and linter
"ocamlformat", -- ocaml formatter
},
automatic_installation = true,
})
@@ -35,6 +35,25 @@ return {
}),
require("none-ls.formatting.ruff_format"),
formatting.clang_format,
formatting.ocamlformat,
-- require("none-ls.formatting.ocamlformat").with({
-- extra_args = {
-- "--if-then-else",
-- "vertical",
-- "--break-cases",
-- "fit-or-vertical",
-- "--type-decl",
-- "sparse",
-- "--type-decl-indent",
-- "4",
-- "--function-indent",
-- "4",
-- "--match-indent",
-- "4",
-- "--let-binding-indent",
-- "4",
-- },
-- }),
}
local augroup = vim.api.nvim_create_augroup("LspFormatting", {})
@@ -49,6 +68,7 @@ return {
group = augroup,
buffer = bufnr,
callback = function()
print("test")
vim.lsp.buf.format({ async = false })
end,
})

View File

@@ -1,18 +1,14 @@
return {
"rmagatti/auto-session",
config = function()
require("auto-session").setup({
auto_session_suppress_dirs = { "~/", "~/Projects", "~/Downloads", "/" },
session_lens = {
buftypes_to_ignore = {},
load_on_setup = true,
theme_conf = { border = true },
previewer = false,
},
})
vim.keymap.set("n", "<Leader>ls", require("auto-session.session-lens").search_session, {
noremap = true,
})
end,
lazy = false,
keys = {
{ "<leader>ls", "<cmd>AutoSession search<CR>", desc = "Session search" },
},
---enables autocomplete for opts
---@module "auto-session"
---@type AutoSession.Config
opts = {
suppressed_dirs = { "~/", "~/Projects", "~/Downloads", "/" },
-- log_level = 'debug',
},
}

View File

@@ -0,0 +1,8 @@
return {
"chomosuke/typst-preview.nvim",
lazy = false, -- or ft = 'typst'
version = "1.*",
opts = {
open_cmd = "chromium %s",
}, -- lazy.nvim will implicitly calls `setup {}`
}