Merge branch 'main' of labs.scarif.space:chris/nvim

This commit is contained in:
Chris
2025-07-24 14:31:25 +01:00
2 changed files with 65 additions and 60 deletions

View File

@@ -124,65 +124,19 @@ return {
local mason_registry = require 'mason-registry'
local vue_language_server_path = vim.fn.expand '$MASON/packages/vue-language-server/node_modules/@vue/language-server'
local servers = {
-- -- clangd = {},
-- -- gopls = {},
-- -- pyright = {},
-- -- rust_analyzer = {},
-- -- ... etc. See `:help lspconfig-all` for a list of all the pre-configured LSPs
-- --
-- -- Some languages (like typescript) have entire language plugins that can be useful:
-- -- https://github.com/pmizio/typescript-tools.nvim
-- --
-- -- But for many setups, the LSP (`ts_ls`) will work just fine
-- -- ts_ls = {},
-- --
--
-- lua_ls = {
-- -- cmd = { ... },
-- -- filetypes = { ... },
-- -- capabilities = {},
-- settings = {
-- Lua = {
-- completion = {
-- callSnippet = 'Replace',
-- },
-- -- You can toggle below to ignore Lua_LS's noisy `missing-fields` warnings
-- -- diagnostics = { disable = { 'missing-fields' } },
-- },
-- },
-- },
-- ts_ls = {
-- init_options = {
-- plugins = {
-- {
-- name = '@vue/typescript-plugin',
-- location = vue_language_server_path,
-- languages = { 'vue' },
-- },
-- },
-- preferences = {
-- importModuleSpecifierEnding = 'js',
-- importModuleSpecifierPreference = 'project-relative',
-- },
-- },
-- filetypes = { 'typescript', 'javascript', 'javascriptreact', 'typescriptreact', 'vue' },
-- capabilities = {
-- documentFormattingProvider = true,
-- documentRangeFormattingProvider = true,
-- },
-- },
--
-- phpactor = {
-- on_attach = function(client, bufnr)
-- client.server_capabilities.documentFormattingProvider = false
-- end,
-- init_options = {
-- ['language_server_phpstan.enabled'] = false,
-- ['language_server_psalm.enabled'] = false,
-- ['language_server_php_cs_fixer.enabled'] = false,
-- ['language_server_php_cs_fixer.bin'] = vim.fn.expand '~/.local/share/composer/vendor/bin/php-cs-fixer',
-- },
-- },
clangd = {},
gopls = {},
pyright = {},
rust_analyzer = {},
lua_ls = {
settings = {
Lua = {
completion = {
callSnippet = 'Replace',
},
},
},
},
phpactor = {
init_options = {
['language_server_phpstan.enabled'] = false,

View File

@@ -8,7 +8,58 @@ return {
-- or leave it empty to use the default settings
-- refer to the configuration section below
bigfile = { enabled = true },
dashboard = { enabled = true },
dashboard = {
enabled = true,
preset = {
keys = {
{ icon = '', key = 'f', desc = 'Find File', action = ":lua Snacks.dashboard.pick('files')" },
{ icon = '', key = 'n', desc = 'New File', action = ':ene | startinsert' },
{ icon = '', key = 'g', desc = 'Find Text', action = ":lua Snacks.dashboard.pick('live_grep')" },
{ icon = '', key = 'r', desc = 'Recent Files', action = ":lua Snacks.dashboard.pick('oldfiles')" },
{ icon = '', key = 'c', desc = 'Config', action = ":lua Snacks.dashboard.pick('files', {cwd = vim.fn.stdpath('config')})" },
-- { icon = " ", key = "s", desc = "Restore Session", section = "session" },
{ icon = '󰒲 ', key = 'L', desc = 'Lazy', action = ':Lazy', enabled = package.loaded.lazy ~= nil },
{ icon = '', key = 'q', desc = 'Quit', action = ':qa' },
},
},
sections = {
{ section = 'header' },
{ section = 'keys', gap = 1, padding = 1 },
{
pane = 2,
icon = '',
title = 'Projects',
section = 'projects',
indent = 2,
padding = 1,
session = false,
dirs = function()
return {
vim.fn.expand '~/Code/Sites/runcats',
vim.fn.expand '~/Code/Sites/moovaza',
vim.fn.expand '~/Code/Sites/tuxtoolkit',
vim.fn.expand '~/Code/Sites/chrisstarling',
vim.fn.stdpath 'config',
}
end,
},
{ pane = 2, icon = '', title = 'Recent Files', section = 'recent_files', indent = 2, padding = 1 },
{
pane = 2,
icon = '',
title = 'Git Status',
section = 'terminal',
enabled = function()
return Snacks.git.get_root() ~= nil
end,
cmd = 'git status --short --branch --renames',
height = 5,
padding = 1,
ttl = 5 * 60,
indent = 3,
},
},
},
indent = { enabled = true },
input = { enabled = true },
notifier = { enabled = true },