null-ls and session

This commit is contained in:
markus.dieckmann
2025-10-17 15:23:13 +02:00
parent 6bdb8cca5b
commit 7dd6bd1675
7 changed files with 202 additions and 48 deletions

View File

@ -1,15 +1,16 @@
{
"auto-session": { "branch": "main", "commit": "517a75727d28a4d1ee9c79b56dde239a5408778f" },
"blink.cmp": { "branch": "main", "commit": "327fff91fe6af358e990be7be1ec8b78037d2138" },
"bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" },
"conform.nvim": { "branch": "master", "commit": "fbcb4fa7f34bfea9be702ffff481a8e336ebf6ed" },
"fidget.nvim": { "branch": "main", "commit": "3f5475949679953af6d78654db29b944fa826e6a" },
"flash.nvim": { "branch": "main", "commit": "2febce67ff9cf7638d2569d17c41af02c38401eb" },
"friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" },
"fzf-lua": { "branch": "main", "commit": "db3ccffe79480543d8e0f7b0cac0d9b220f9486e" },
"fzf-lua": { "branch": "main", "commit": "83e4080ae886a42ec48c5c26ce5892ceb557c425" },
"git-blame.nvim": { "branch": "master", "commit": "54da04264ec5313d602aebea7c5dc90141696ad7" },
"gitsigns.nvim": { "branch": "main", "commit": "1ee5c1fd068c81f9dd06483e639c2aa4587dc197" },
"json-to-types.nvim": { "branch": "main", "commit": "e8dcc6ac710c59fcac354255a835f72916171ba8" },
"kanagawa.nvim": { "branch": "master", "commit": "27f1e119f3a7e6d11d435a59e3262e6affda1f83" },
"kanagawa.nvim": { "branch": "master", "commit": "aef7f5cec0a40dbe7f3304214850c472e2264b10" },
"lazy.nvim": { "branch": "main", "commit": "1ea3c4085785f460fb0e46d2fe1ee895f5f9e7c1" },
"lazydev.nvim": { "branch": "main", "commit": "e28ce52fc7ff79fcb76f0e79ee6fb6182fca90b9" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "6bdb14f230de0904229ec367b410fb817e59b072" },
@ -18,9 +19,11 @@
"mini.icons": { "branch": "main", "commit": "284798619aed9f4c1ac1b9417b9a5e3b4b85ef3a" },
"mini.nvim": { "branch": "main", "commit": "94cae4660a8b2d95dbbd56e1fbc6fcfa2716d152" },
"mini.statusline": { "branch": "main", "commit": "faa39777ca729c6dafe86041207ba8db9321cb29" },
"neo-tree.nvim": { "branch": "v3.x", "commit": "4c60a198e3f92098778a32a1c76d2bd7ba46a3b5" },
"neo-tree.nvim": { "branch": "v3.x", "commit": "c4c168e459395275c552179a1baf9c3d885d6a74" },
"none-ls-extras.nvim": { "branch": "main", "commit": "402c6b5c29f0ab57fac924b863709f37f55dc298" },
"none-ls.nvim": { "branch": "main", "commit": "a96172f673f720cd4f3572e1fcd08400ed3eb25d" },
"nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" },
"nvim-dap": { "branch": "master", "commit": "881f7dc17c0b4204a1d844732f95539575350e5b" },
"nvim-dap": { "branch": "master", "commit": "6782b097af2417a4c3e33849b0a26ae2188bd7ea" },
"nvim-dap-ui": { "branch": "master", "commit": "cf91d5e2d07c72903d052f5207511bf7ecdb7122" },
"nvim-dap-virtual-text": { "branch": "master", "commit": "fbdb48c2ed45f4a8293d0d483f7730d24467ccb6" },
"nvim-lsp-file-operations": { "branch": "master", "commit": "9744b738183a5adca0f916527922078a965515ed" },
@ -32,12 +35,12 @@
"nvim-vtsls": { "branch": "main", "commit": "0b5f73c9e50ce95842ea07bb3f05c7d66d87d14a" },
"nvim-web-devicons": { "branch": "master", "commit": "b8221e42cf7287c4dcde81f232f58d7b947c210d" },
"nvim-window-picker": { "branch": "main", "commit": "6382540b2ae5de6c793d4aa2e3fe6dbb518505ec" },
"oil.nvim": { "branch": "master", "commit": "919e155fdf38e9148cdb5304faaaf53c20d703ea" },
"oil.nvim": { "branch": "master", "commit": "71948729cda5fc1b761d6ae60ff774b5525f1d50" },
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
"project.nvim": { "branch": "main", "commit": "8c6bad7d22eef1b71144b401c9f74ed01526a4fb" },
"rainbow-delimiters.nvim": { "branch": "master", "commit": "3277ad5f96eb03c9d618c88e24f683e4364e578c" },
"rustaceanvim": { "branch": "master", "commit": "12504405821c05874d2d1f6b5ec919f9808e2c99" },
"snacks.nvim": { "branch": "main", "commit": "b8d838d8be274c8eecced4306cca15378cde9830" },
"snacks.nvim": { "branch": "main", "commit": "454ba02d69347c0735044f159b95d2495fc79a73" },
"toggleterm.nvim": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" },
"trouble.nvim": { "branch": "main", "commit": "c098362fe603d3922095e7db595961e020bdf2d0" },
"vim-helm": { "branch": "master", "commit": "2c8525fd98e57472769d137317bca83e477858ce" },

View File

@ -37,3 +37,4 @@ require("lazy").setup({
})
require("config.keymap")
require("fzf-lua").register_ui_select()

View File

@ -11,6 +11,9 @@ return {
},
opts = {
async = true,
format = {
timeout_ms = 5000,
},
formatters_by_ft = {
lua = { "stylua" },
-- Conform will run multiple formatters sequentially
@ -20,10 +23,10 @@ return {
-- Conform will run the first available formatter
javascript = { "eslint_d", "prettierd", "prettier", stop_after_first = true },
typescript = { "eslint_d", "prettierd", "prettier", stop_after_first = true },
prisma = { "null-ls", lsp_format = false },
format_on_save = {
-- These options will be passed to conform.format()
timeout_ms = 500,
lsp_format = "fallback",
timeout_ms = 5000,
},
},
},

View File

@ -1,23 +1,92 @@
return {
"ibhagwan/fzf-lua",
dependencies = { "echasnovski/mini.icons" },
opts = {
winopts={
config = function()
require("fzf-lua").setup({
winopts = {
height = 0.85,
width = 0.95,
}
},
})
require("fzf-lua").register_ui_select()
end,
keys = {
{ "<leader>ff", function() require('fzf-lua').files() end, desc="Find Files in current dir"},
{ "<leader>fb", function() require('fzf-lua').buffers() end, desc="Find open buffers"},
{ "<leader><leader>", function() require('fzf-lua').buffers() end, desc="Find open buffers"},
{ "<leader>fgf", function() require('fzf-lua').git_files() end, desc="Find git files"},
{ "<leader>fgb", function() require('fzf-lua').git_branches() end, desc="Find git branches"},
{ "<leader>fB", function() require('fzf-lua').builtin() end, desc="Find builtin finders"},
{ "<leader>fr", function() require('fzf-lua').resume() end, desc="Resume last search"},
{ "<leader>fG", function() require('fzf-lua').live_grep() end, desc="Grep files live"},
{ "<leader>fw", function() require('fzf-lua').grep_cword() end, desc="Grep current word"},
{ "<leader>fW", function() require('fzf-lua').grep_cWORD() end, desc="Grep current WORD"},
{ "<leader>/", function() require('fzf-lua').lgrep_curbuf() end, desc="Grep current buffer"},
}
{
"<leader>ff",
function()
require("fzf-lua").files()
end,
desc = "Find Files in current dir",
},
{
"<leader>fb",
function()
require("fzf-lua").buffers()
end,
desc = "Find open buffers",
},
{
"<leader><leader>",
function()
require("fzf-lua").buffers()
end,
desc = "Find open buffers",
},
{
"<leader>fgf",
function()
require("fzf-lua").git_files()
end,
desc = "Find git files",
},
{
"<leader>fgb",
function()
require("fzf-lua").git_branches()
end,
desc = "Find git branches",
},
{
"<leader>fB",
function()
require("fzf-lua").builtin()
end,
desc = "Find builtin finders",
},
{
"<leader>fr",
function()
require("fzf-lua").resume()
end,
desc = "Resume last search",
},
{
"<leader>fG",
function()
require("fzf-lua").live_grep()
end,
desc = "Grep files live",
},
{
"<leader>fw",
function()
require("fzf-lua").grep_cword()
end,
desc = "Grep current word",
},
{
"<leader>fW",
function()
require("fzf-lua").grep_cWORD()
end,
desc = "Grep current WORD",
},
{
"<leader>/",
function()
require("fzf-lua").lgrep_curbuf()
end,
desc = "Grep current buffer",
},
},
}

View File

@ -6,6 +6,9 @@ return {
"WhoIsSethDaniel/mason-tool-installer.nvim",
"yioneko/nvim-vtsls",
opts = {
format = {
timeout_ms = 10000,
},
settings = {
typescript = {
inlayHints = {

View File

@ -0,0 +1,18 @@
return {
"nvimtools/none-ls.nvim",
dependencies = {
"nvim-lua/plenary.nvim",
"nvimtools/none-ls-extras.nvim",
},
config = function()
local null_ls = require("null-ls")
null_ls.setup({
sources = {
null_ls.builtins.code_actions.gitsigns,
null_ls.builtins.code_actions.refactoring,
null_ls.builtins.formatting.prisma_format,
require("none-ls.diagnostics.eslint"), -- requires none-ls-extras.nvim
},
})
end,
}

View File

@ -0,0 +1,57 @@
return {
"rmagatti/auto-session",
lazy = false,
keys = {
-- Will use Telescope if installed or a vim.ui.select picker otherwise
{ "<leader>wr", "<cmd>AutoSession search<CR>", desc = "Session search" },
{ "<leader>ws", "<cmd>AutoSession save<CR>", desc = "Save session" },
{ "<leader>wa", "<cmd>AutoSession toggle<CR>", desc = "Toggle autosave" },
},
---enables autocomplete for opts
---@module "auto-session"
---@type AutoSession.Config
opts = {
-- The following are already the default values, no need to provide them if these are already the settings you want.
session_lens = {
picker = nil, -- "telescope"|"snacks"|"fzf"|"select"|nil Pickers are detected automatically but you can also manually choose one. Falls back to vim.ui.select
mappings = {
-- Mode can be a string or a table, e.g. {"i", "n"} for both insert and normal mode
delete_session = { "i", "<C-d>" },
alternate_session = { "i", "<C-s>" },
copy_session = { "i", "<C-y>" },
},
picker_opts = {
-- For Telescope, you can set theme options here, see:
-- https://github.com/nvim-telescope/telescope.nvim/blob/master/doc/telescope.txt#L112
-- https://github.com/nvim-telescope/telescope.nvim/blob/master/lua/telescope/themes.lua
--
-- border = true,
-- layout_config = {
-- width = 0.8, -- Can set width and height as percent of window
-- height = 0.5,
-- },
-- For Snacks, you can set layout options here, see:
-- https://github.com/folke/snacks.nvim/blob/main/docs/picker.md#%EF%B8%8F-layouts
--
-- preset = "dropdown",
-- preview = false,
-- layout = {
-- width = 0.4,
-- height = 0.4,
-- },
-- For Fzf-Lua, picker_opts just turns into winopts, see:
-- https://github.com/ibhagwan/fzf-lua#customization
--
-- height = 0.8,
-- width = 0.50,
},
-- Telescope only: If load_on_setup is false, make sure you use `:AutoSession search` to open the picker as it will initialize everything first
load_on_setup = true,
},
},
}