update custom config
This commit is contained in:
parent
dabce46993
commit
713c1ae5cf
35
init.lua
35
init.lua
|
|
@ -271,7 +271,29 @@ require('lazy').setup({
|
||||||
--
|
--
|
||||||
-- Here is a more advanced example where we pass configuration
|
-- Here is a more advanced example where we pass configuration
|
||||||
-- options to `gitsigns.nvim`.
|
-- options to `gitsigns.nvim`.
|
||||||
--
|
-- MY PLUGINS SECTION
|
||||||
|
{ -- auto pair braces { [ (
|
||||||
|
'windwp/nvim-autopairs',
|
||||||
|
event = 'InsertEnter',
|
||||||
|
config = true,
|
||||||
|
},
|
||||||
|
{ -- pr reviews
|
||||||
|
'pwntester/octo.nvim',
|
||||||
|
dependencies = {
|
||||||
|
'nvim-lua/plenary.nvim',
|
||||||
|
'nvim-telescope/telescope.nvim',
|
||||||
|
'nvim-tree/nvim-web-devicons',
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
require('octo').setup {
|
||||||
|
enable_builtin = true,
|
||||||
|
use_local_fs = false,
|
||||||
|
default_remote = { 'upstream', 'origin' },
|
||||||
|
ssh_aliases = {},
|
||||||
|
}
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
-- MY PLUGNS SECTION
|
||||||
-- See `:help gitsigns` to understand what the configuration keys do
|
-- See `:help gitsigns` to understand what the configuration keys do
|
||||||
{ -- Adds git related signs to the gutter, as well as utilities for managing changes
|
{ -- Adds git related signs to the gutter, as well as utilities for managing changes
|
||||||
'lewis6991/gitsigns.nvim',
|
'lewis6991/gitsigns.nvim',
|
||||||
|
|
@ -603,7 +625,8 @@ require('lazy').setup({
|
||||||
-- See `:help lsp-config` for information about keys and how to configure
|
-- See `:help lsp-config` for information about keys and how to configure
|
||||||
---@type table<string, vim.lsp.Config>
|
---@type table<string, vim.lsp.Config>
|
||||||
local servers = {
|
local servers = {
|
||||||
-- clangd = {},
|
clangd = {},
|
||||||
|
elp = {},
|
||||||
-- gopls = {},
|
-- gopls = {},
|
||||||
-- pyright = {},
|
-- pyright = {},
|
||||||
-- rust_analyzer = {},
|
-- rust_analyzer = {},
|
||||||
|
|
@ -612,7 +635,7 @@ require('lazy').setup({
|
||||||
-- https://github.com/pmizio/typescript-tools.nvim
|
-- https://github.com/pmizio/typescript-tools.nvim
|
||||||
--
|
--
|
||||||
-- But for many setups, the LSP (`ts_ls`) will work just fine
|
-- But for many setups, the LSP (`ts_ls`) will work just fine
|
||||||
-- ts_ls = {},
|
ts_ls = {},
|
||||||
|
|
||||||
stylua = {}, -- Used to format Lua code
|
stylua = {}, -- Used to format Lua code
|
||||||
|
|
||||||
|
|
@ -687,7 +710,7 @@ require('lazy').setup({
|
||||||
-- Disable "format_on_save lsp_fallback" for languages that don't
|
-- Disable "format_on_save lsp_fallback" for languages that don't
|
||||||
-- have a well standardized coding style. You can add additional
|
-- have a well standardized coding style. You can add additional
|
||||||
-- languages here or re-enable it for the disabled ones.
|
-- languages here or re-enable it for the disabled ones.
|
||||||
local disable_filetypes = { c = true, cpp = true }
|
local disable_filetypes = { c = false, cpp = false }
|
||||||
if disable_filetypes[vim.bo[bufnr].filetype] then
|
if disable_filetypes[vim.bo[bufnr].filetype] then
|
||||||
return nil
|
return nil
|
||||||
else
|
else
|
||||||
|
|
@ -699,6 +722,9 @@ require('lazy').setup({
|
||||||
end,
|
end,
|
||||||
formatters_by_ft = {
|
formatters_by_ft = {
|
||||||
lua = { 'stylua' },
|
lua = { 'stylua' },
|
||||||
|
c = { 'clang-format' },
|
||||||
|
cpp = { 'clang-format' },
|
||||||
|
erlang = { 'erlfmt', 'elp' },
|
||||||
-- Conform can also run multiple formatters sequentially
|
-- Conform can also run multiple formatters sequentially
|
||||||
-- python = { "isort", "black" },
|
-- python = { "isort", "black" },
|
||||||
--
|
--
|
||||||
|
|
@ -875,6 +901,7 @@ require('lazy').setup({
|
||||||
lazy = false,
|
lazy = false,
|
||||||
build = ':TSUpdate',
|
build = ':TSUpdate',
|
||||||
branch = 'main',
|
branch = 'main',
|
||||||
|
main = 'nvim.treesitter.configs',
|
||||||
-- [[ Configure Treesitter ]] See `:help nvim-treesitter-intro`
|
-- [[ Configure Treesitter ]] See `:help nvim-treesitter-intro`
|
||||||
config = function()
|
config = function()
|
||||||
local parsers = { 'bash', 'c', 'diff', 'html', 'lua', 'luadoc', 'markdown', 'markdown_inline', 'query', 'vim', 'vimdoc' }
|
local parsers = { 'bash', 'c', 'diff', 'html', 'lua', 'luadoc', 'markdown', 'markdown_inline', 'query', 'vim', 'vimdoc' }
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue