mirror of
https://github.com/ViViDboarder/vim-settings.git
synced 2024-11-17 17:26:27 +00:00
Run stylua again
This commit is contained in:
parent
7b3f69cf66
commit
3051f0b294
@ -28,242 +28,253 @@ if vim.fn.has("nvim-0.6.0") ~= 1 then
|
||||
end
|
||||
end
|
||||
|
||||
return require("packer").startup({function(use)
|
||||
-- Load things faster!
|
||||
use({ "lewis6991/impatient.nvim", config = [[require('impatient')]] })
|
||||
return require("packer").startup({
|
||||
function(use)
|
||||
-- Load things faster!
|
||||
use({ "lewis6991/impatient.nvim", config = [[require('impatient')]] })
|
||||
|
||||
-- Let Packer manage and lazyload itself
|
||||
use({
|
||||
"wbthomason/packer.nvim",
|
||||
cmd = {
|
||||
"PackerClean",
|
||||
"PackerCompile",
|
||||
"PackerInstall",
|
||||
"PackerLoad",
|
||||
"PackerProfile",
|
||||
"PackerStatus",
|
||||
"PackerSync",
|
||||
"PackerUpdate",
|
||||
},
|
||||
config = [[require("plugins")]],
|
||||
})
|
||||
-- Let Packer manage and lazyload itself
|
||||
use({
|
||||
"wbthomason/packer.nvim",
|
||||
cmd = {
|
||||
"PackerClean",
|
||||
"PackerCompile",
|
||||
"PackerInstall",
|
||||
"PackerLoad",
|
||||
"PackerProfile",
|
||||
"PackerStatus",
|
||||
"PackerSync",
|
||||
"PackerUpdate",
|
||||
},
|
||||
config = [[require("plugins")]],
|
||||
})
|
||||
|
||||
-- Colorschemes
|
||||
use({
|
||||
"vim-scripts/wombat256.vim",
|
||||
{ "ViViDboarder/wombat.nvim", requires = "rktjmp/lush.nvim" },
|
||||
{ "ViViDboarder/wombuddy.nvim", requires = "tjdevries/colorbuddy.vim" },
|
||||
"ishan9299/nvim-solarized-lua",
|
||||
{
|
||||
"folke/tokyonight.nvim",
|
||||
run = 'fish -c \'echo "set --path --prepend fish_themes_path "(pwd)"/extras" > ~/.config/fish/conf.d/tokyonight.fish\' || true', -- luacheck: no max line length
|
||||
},
|
||||
})
|
||||
-- Colorschemes
|
||||
use({
|
||||
"vim-scripts/wombat256.vim",
|
||||
{ "ViViDboarder/wombat.nvim", requires = "rktjmp/lush.nvim" },
|
||||
{ "ViViDboarder/wombuddy.nvim", requires = "tjdevries/colorbuddy.vim" },
|
||||
"ishan9299/nvim-solarized-lua",
|
||||
{
|
||||
"folke/tokyonight.nvim",
|
||||
run = 'fish -c \'echo "set --path --prepend fish_themes_path "(pwd)"/extras" > ~/.config/fish/conf.d/tokyonight.fish\' || true', -- luacheck: no max line length
|
||||
},
|
||||
})
|
||||
|
||||
-- Auto and ends to some ifs and dos
|
||||
use("tpope/vim-endwise")
|
||||
-- Auto and ends to some ifs and dos
|
||||
use("tpope/vim-endwise")
|
||||
|
||||
-- Unix commands from vim? Yup!
|
||||
use("tpope/vim-eunuch")
|
||||
-- Unix commands from vim? Yup!
|
||||
use("tpope/vim-eunuch")
|
||||
|
||||
-- Adds repeats for custom motions
|
||||
use("tpope/vim-repeat")
|
||||
-- Adds repeats for custom motions
|
||||
use("tpope/vim-repeat")
|
||||
|
||||
-- Readline shortcuts
|
||||
use("tpope/vim-rsi")
|
||||
-- Readline shortcuts
|
||||
use("tpope/vim-rsi")
|
||||
|
||||
-- Surround motions
|
||||
use("tpope/vim-surround")
|
||||
-- Surround motions
|
||||
use("tpope/vim-surround")
|
||||
|
||||
-- Better netrw
|
||||
use("tpope/vim-vinegar")
|
||||
-- Better netrw
|
||||
use("tpope/vim-vinegar")
|
||||
|
||||
-- Easier jumping to lines
|
||||
use("vim-scripts/file-line")
|
||||
-- Easier jumping to lines
|
||||
use("vim-scripts/file-line")
|
||||
|
||||
-- Auto ctags generation
|
||||
use("ludovicchabant/vim-gutentags")
|
||||
-- Auto ctags generation
|
||||
use("ludovicchabant/vim-gutentags")
|
||||
|
||||
-- Make it easier to discover some of my keymaps
|
||||
use({
|
||||
"folke/which-key.nvim",
|
||||
config = function()
|
||||
require("plugins.whichkey").configure()
|
||||
end,
|
||||
})
|
||||
-- Make it easier to discover some of my keymaps
|
||||
use({
|
||||
"folke/which-key.nvim",
|
||||
config = function()
|
||||
require("plugins.whichkey").configure()
|
||||
end,
|
||||
})
|
||||
|
||||
-- Better commenting
|
||||
use({
|
||||
"tomtom/tcomment_vim",
|
||||
config = function()
|
||||
vim.api.nvim_set_keymap("n", "//", ":TComment<CR>", { silent = true, noremap = true })
|
||||
vim.api.nvim_set_keymap("v", "//", ":TCommentBlock<CR>", { silent = true, noremap = true })
|
||||
end,
|
||||
})
|
||||
-- Better commenting
|
||||
use({
|
||||
"tomtom/tcomment_vim",
|
||||
config = function()
|
||||
vim.api.nvim_set_keymap("n", "//", ":TComment<CR>", { silent = true, noremap = true })
|
||||
vim.api.nvim_set_keymap("v", "//", ":TCommentBlock<CR>", { silent = true, noremap = true })
|
||||
end,
|
||||
})
|
||||
|
||||
-- Allow wrapping and joining of arguments across multiple lines
|
||||
use({
|
||||
"FooSoft/vim-argwrap",
|
||||
config = function()
|
||||
vim.api.nvim_set_keymap("n", "<Leader>a", ":ArgWrap<CR>", { silent = true, noremap = true })
|
||||
end,
|
||||
})
|
||||
-- Allow wrapping and joining of arguments across multiple lines
|
||||
use({
|
||||
"FooSoft/vim-argwrap",
|
||||
config = function()
|
||||
vim.api.nvim_set_keymap("n", "<Leader>a", ":ArgWrap<CR>", { silent = true, noremap = true })
|
||||
end,
|
||||
})
|
||||
|
||||
-- Adds git operations to vim
|
||||
use({
|
||||
"tpope/vim-fugitive",
|
||||
})
|
||||
-- Adds git operations to vim
|
||||
use({
|
||||
"tpope/vim-fugitive",
|
||||
})
|
||||
|
||||
-- Quick toggling of Location and Quickfix lists
|
||||
use({
|
||||
"milkypostman/vim-togglelist",
|
||||
config = function()
|
||||
vim.api.nvim_set_keymap("n", "<F6>", ":call ToggleQuickfixList()<CR>", { silent = true, noremap = true })
|
||||
vim.api.nvim_set_keymap("n", "<F7>", ":call ToggleLocationList()<CR>", { silent = true, noremap = true })
|
||||
end,
|
||||
})
|
||||
-- Quick toggling of Location and Quickfix lists
|
||||
use({
|
||||
"milkypostman/vim-togglelist",
|
||||
config = function()
|
||||
vim.api.nvim_set_keymap(
|
||||
"n",
|
||||
"<F6>",
|
||||
":call ToggleQuickfixList()<CR>",
|
||||
{ silent = true, noremap = true }
|
||||
)
|
||||
vim.api.nvim_set_keymap(
|
||||
"n",
|
||||
"<F7>",
|
||||
":call ToggleLocationList()<CR>",
|
||||
{ silent = true, noremap = true }
|
||||
)
|
||||
end,
|
||||
})
|
||||
|
||||
-- Find text everywhere!
|
||||
use({
|
||||
"mhinz/vim-grepper",
|
||||
config = function()
|
||||
require("plugins.grepper")
|
||||
end,
|
||||
})
|
||||
-- Find text everywhere!
|
||||
use({
|
||||
"mhinz/vim-grepper",
|
||||
config = function()
|
||||
require("plugins.grepper")
|
||||
end,
|
||||
})
|
||||
|
||||
-- Highlight inline colors
|
||||
use({
|
||||
"norcalli/nvim-colorizer.lua",
|
||||
config = function()
|
||||
require("colorizer").setup()
|
||||
end,
|
||||
})
|
||||
-- Highlight inline colors
|
||||
use({
|
||||
"norcalli/nvim-colorizer.lua",
|
||||
config = function()
|
||||
require("colorizer").setup()
|
||||
end,
|
||||
})
|
||||
|
||||
-- Custom status line
|
||||
use({ "SmiteshP/nvim-gps", requires = "nvim-treesitter/nvim-treesitter" })
|
||||
use({
|
||||
"nvim-lualine/lualine.nvim",
|
||||
config = function()
|
||||
require("plugins.lualine").config_lualine()
|
||||
end,
|
||||
requires = {
|
||||
-- Show my current location in my status bar
|
||||
-- { "SmiteshP/nvim-gps", requires = "nvim-treesitter/nvim-treesitter" },
|
||||
},
|
||||
after = {
|
||||
"nvim-gps",
|
||||
},
|
||||
})
|
||||
-- Custom status line
|
||||
use({ "SmiteshP/nvim-gps", requires = "nvim-treesitter/nvim-treesitter" })
|
||||
use({
|
||||
"nvim-lualine/lualine.nvim",
|
||||
config = function()
|
||||
require("plugins.lualine").config_lualine()
|
||||
end,
|
||||
requires = {
|
||||
-- Show my current location in my status bar
|
||||
-- { "SmiteshP/nvim-gps", requires = "nvim-treesitter/nvim-treesitter" },
|
||||
},
|
||||
after = {
|
||||
"nvim-gps",
|
||||
},
|
||||
})
|
||||
|
||||
-- On Mac, update colors when dark mode changes
|
||||
use({
|
||||
"cormacrelf/dark-notify",
|
||||
disable = not vim.g.is_mac,
|
||||
-- Download latest release on install
|
||||
run = "curl -s https://api.github.com/repos/cormacrelf/dark-notify/releases/latest | jq '.assets[].browser_download_url' | xargs curl -Ls | tar xz -C ~/.local/bin/", -- luacheck: no max line length
|
||||
config = config_dark_notify,
|
||||
requires = "nvim-lualine/lualine.nvim",
|
||||
})
|
||||
-- On Mac, update colors when dark mode changes
|
||||
use({
|
||||
"cormacrelf/dark-notify",
|
||||
disable = not vim.g.is_mac,
|
||||
-- Download latest release on install
|
||||
run = "curl -s https://api.github.com/repos/cormacrelf/dark-notify/releases/latest | jq '.assets[].browser_download_url' | xargs curl -Ls | tar xz -C ~/.local/bin/", -- luacheck: no max line length
|
||||
config = config_dark_notify,
|
||||
requires = "nvim-lualine/lualine.nvim",
|
||||
})
|
||||
|
||||
-- Custom start screen
|
||||
use({
|
||||
"mhinz/vim-startify",
|
||||
config = function()
|
||||
require("utils").require_with_local("plugins.startify")
|
||||
end,
|
||||
})
|
||||
-- Custom start screen
|
||||
use({
|
||||
"mhinz/vim-startify",
|
||||
config = function()
|
||||
require("utils").require_with_local("plugins.startify")
|
||||
end,
|
||||
})
|
||||
|
||||
-- LSP
|
||||
-- LSP
|
||||
|
||||
-- Configure language servers
|
||||
use("neovim/nvim-lspconfig")
|
||||
-- Configure language servers
|
||||
use("neovim/nvim-lspconfig")
|
||||
|
||||
-- Better display of diagnostics
|
||||
use("folke/trouble.nvim")
|
||||
-- Better display of diagnostics
|
||||
use("folke/trouble.nvim")
|
||||
|
||||
-- Generic linter/formatters in diagnostics API
|
||||
use({
|
||||
"jose-elias-alvarez/null-ls.nvim",
|
||||
requires = { "nvim-lua/plenary.nvim", "neovim/nvim-lspconfig" },
|
||||
})
|
||||
-- Generic linter/formatters in diagnostics API
|
||||
use({
|
||||
"jose-elias-alvarez/null-ls.nvim",
|
||||
requires = { "nvim-lua/plenary.nvim", "neovim/nvim-lspconfig" },
|
||||
})
|
||||
|
||||
-- Fancy LSP UIs
|
||||
use({
|
||||
"glepnir/lspsaga.nvim",
|
||||
requires = "neovim/nvim-lspconfig",
|
||||
-- NOTE: Disabled because it's got issues with Neovim 0.6.0
|
||||
disable = true,
|
||||
})
|
||||
-- Fancy LSP UIs
|
||||
use({
|
||||
"glepnir/lspsaga.nvim",
|
||||
requires = "neovim/nvim-lspconfig",
|
||||
-- NOTE: Disabled because it's got issues with Neovim 0.6.0
|
||||
disable = true,
|
||||
})
|
||||
|
||||
-- Writing
|
||||
-- abolish/pencil
|
||||
use({
|
||||
"preservim/vim-pencil",
|
||||
cmd = { "Pencil" },
|
||||
})
|
||||
use({
|
||||
"preservim/vim-textobj-sentence",
|
||||
requires = "kana/vim-textobj-user",
|
||||
})
|
||||
use({
|
||||
"junegunn/goyo.vim",
|
||||
cmd = { "Goyo", "Zen" },
|
||||
config = [[require("plugins.goyo-limelight")]],
|
||||
requires = { "junegunn/limelight.vim", cmd = "Limelight" },
|
||||
})
|
||||
-- Writing
|
||||
-- abolish/pencil
|
||||
use({
|
||||
"preservim/vim-pencil",
|
||||
cmd = { "Pencil" },
|
||||
})
|
||||
use({
|
||||
"preservim/vim-textobj-sentence",
|
||||
requires = "kana/vim-textobj-user",
|
||||
})
|
||||
use({
|
||||
"junegunn/goyo.vim",
|
||||
cmd = { "Goyo", "Zen" },
|
||||
config = [[require("plugins.goyo-limelight")]],
|
||||
requires = { "junegunn/limelight.vim", cmd = "Limelight" },
|
||||
})
|
||||
|
||||
-- Treesitter
|
||||
use({
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
run = ":TSUpdate",
|
||||
config = function()
|
||||
require("utils").require_with_local("plugins.treesitter")
|
||||
end,
|
||||
})
|
||||
use({
|
||||
"nvim-treesitter/nvim-treesitter-refactor",
|
||||
requires = "nvim-treesitter/nvim-treesitter",
|
||||
})
|
||||
use({
|
||||
"nvim-treesitter/nvim-treesitter-textobjects",
|
||||
requires = "nvim-treesitter/nvim-treesitter",
|
||||
})
|
||||
--[[
|
||||
-- Treesitter
|
||||
use({
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
run = ":TSUpdate",
|
||||
config = function()
|
||||
require("utils").require_with_local("plugins.treesitter")
|
||||
end,
|
||||
})
|
||||
use({
|
||||
"nvim-treesitter/nvim-treesitter-refactor",
|
||||
requires = "nvim-treesitter/nvim-treesitter",
|
||||
})
|
||||
use({
|
||||
"nvim-treesitter/nvim-treesitter-textobjects",
|
||||
requires = "nvim-treesitter/nvim-treesitter",
|
||||
})
|
||||
--[[
|
||||
use {
|
||||
"nvim-treesitter/completion-treesitter",
|
||||
requires = "nvim-treesitter/nvim-treesitter",
|
||||
}
|
||||
--]]
|
||||
|
||||
-- Completion
|
||||
use({
|
||||
"hrsh7th/nvim-cmp",
|
||||
config = function()
|
||||
require("plugins.completion").config_cmp()
|
||||
end,
|
||||
requires = {
|
||||
{ "hrsh7th/cmp-nvim-lsp", after = "nvim-cmp" },
|
||||
{ "hrsh7th/cmp-buffer", after = "nvim-cmp" },
|
||||
{ "f3fora/cmp-spell", after = "nvim-cmp" },
|
||||
{ "saadparwaiz1/cmp_luasnip", after = "nvim-cmp" },
|
||||
"L3MON4D3/LuaSnip",
|
||||
},
|
||||
event = "InsertEnter *",
|
||||
})
|
||||
-- Completion
|
||||
use({
|
||||
"hrsh7th/nvim-cmp",
|
||||
config = function()
|
||||
require("plugins.completion").config_cmp()
|
||||
end,
|
||||
requires = {
|
||||
{ "hrsh7th/cmp-nvim-lsp", after = "nvim-cmp" },
|
||||
{ "hrsh7th/cmp-buffer", after = "nvim-cmp" },
|
||||
{ "f3fora/cmp-spell", after = "nvim-cmp" },
|
||||
{ "saadparwaiz1/cmp_luasnip", after = "nvim-cmp" },
|
||||
"L3MON4D3/LuaSnip",
|
||||
},
|
||||
event = "InsertEnter *",
|
||||
})
|
||||
|
||||
-- Fuzzy Finder
|
||||
use({
|
||||
"nvim-telescope/telescope.nvim",
|
||||
requires = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
"nvim-lua/popup.nvim",
|
||||
},
|
||||
commit = pinned_commits["telescope"],
|
||||
config = function()
|
||||
require("plugins.telescope")
|
||||
end,
|
||||
})
|
||||
--[[
|
||||
-- Fuzzy Finder
|
||||
use({
|
||||
"nvim-telescope/telescope.nvim",
|
||||
requires = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
"nvim-lua/popup.nvim",
|
||||
},
|
||||
commit = pinned_commits["telescope"],
|
||||
config = function()
|
||||
require("plugins.telescope")
|
||||
end,
|
||||
})
|
||||
--[[
|
||||
use {
|
||||
'junegunn/fzf',
|
||||
run = ":call fzf#install()",
|
||||
@ -303,43 +314,44 @@ return require("packer").startup({function(use)
|
||||
}
|
||||
--]]
|
||||
|
||||
-- Filetypes
|
||||
use("ViViDboarder/vim-forcedotcom")
|
||||
use("rust-lang/rust.vim")
|
||||
use("hsanson/vim-android")
|
||||
use({
|
||||
"sheerun/vim-polyglot",
|
||||
config = function()
|
||||
vim.cmd([[
|
||||
-- Filetypes
|
||||
use("ViViDboarder/vim-forcedotcom")
|
||||
use("rust-lang/rust.vim")
|
||||
use("hsanson/vim-android")
|
||||
use({
|
||||
"sheerun/vim-polyglot",
|
||||
config = function()
|
||||
vim.cmd([[
|
||||
augroup ansible_playbook
|
||||
au BufRead,BufNewFile */playbooks/*.yml,*/playbooks/*.yaml set filetype=yaml.ansible
|
||||
augroup end
|
||||
]])
|
||||
end,
|
||||
})
|
||||
end,
|
||||
})
|
||||
|
||||
use({
|
||||
"dense-analysis/ale",
|
||||
config = function()
|
||||
require("plugins.ale")
|
||||
end,
|
||||
})
|
||||
use({
|
||||
"dense-analysis/ale",
|
||||
config = function()
|
||||
require("plugins.ale")
|
||||
end,
|
||||
})
|
||||
|
||||
-- Debuging nvim config
|
||||
use({
|
||||
"tweekmonster/startuptime.vim",
|
||||
cmd = { "StartupTime" },
|
||||
})
|
||||
-- Debuging nvim config
|
||||
use({
|
||||
"tweekmonster/startuptime.vim",
|
||||
cmd = { "StartupTime" },
|
||||
})
|
||||
|
||||
-- Auto sync after bootstrapping on a fresh box
|
||||
if packer_bootstrap then
|
||||
require("packer").sync()
|
||||
end
|
||||
end,
|
||||
config = {
|
||||
display = {
|
||||
open_fn = function()
|
||||
return require("packer.util").float({ border = "single" })
|
||||
end,
|
||||
-- Auto sync after bootstrapping on a fresh box
|
||||
if packer_bootstrap then
|
||||
require("packer").sync()
|
||||
end
|
||||
end,
|
||||
config = {
|
||||
display = {
|
||||
open_fn = function()
|
||||
return require("packer.util").float({ border = "single" })
|
||||
end,
|
||||
},
|
||||
},
|
||||
}})
|
||||
})
|
||||
|
@ -160,50 +160,50 @@ end
|
||||
function M.config_lsp_saga()
|
||||
utils.try_require("lspsaga", function(saga)
|
||||
saga.init_lsp_saga({
|
||||
error_sign = "🔥",
|
||||
warn_sign = "⚠️",
|
||||
hint_sign = "🤔",
|
||||
dianostic_header_icon = " 💬 ",
|
||||
code_action_icon = "💡",
|
||||
code_action_prompt = {
|
||||
enable = false,
|
||||
sign = false,
|
||||
},
|
||||
})
|
||||
error_sign = "🔥",
|
||||
warn_sign = "⚠️",
|
||||
hint_sign = "🤔",
|
||||
dianostic_header_icon = " 💬 ",
|
||||
code_action_icon = "💡",
|
||||
code_action_prompt = {
|
||||
enable = false,
|
||||
sign = false,
|
||||
},
|
||||
})
|
||||
end)
|
||||
end
|
||||
|
||||
function M.config_null_ls()
|
||||
utils.try_require("null-ls", function(null_ls)
|
||||
null_ls.setup({
|
||||
on_attach = default_attach,
|
||||
capabilities = merged_capabilities(),
|
||||
sources = {
|
||||
-- Generic
|
||||
-- null_ls.builtins.formatting.preittier,
|
||||
-- null_ls.builtins.formatting.trim_whitespace,
|
||||
-- null_ls.builtins.formatting.trim_newlines,
|
||||
-- Fish
|
||||
-- null_ls.builtins.formatting.fish_indent,
|
||||
-- Python
|
||||
null_ls.builtins.formatting.reorder_python_imports,
|
||||
null_ls.builtins.formatting.black,
|
||||
null_ls.builtins.diagnostics.mypy,
|
||||
-- Go
|
||||
null_ls.builtins.diagnostics.golangci_lint,
|
||||
-- Text
|
||||
-- null_ls.builtins.code_actions.proselint,
|
||||
-- Ansible
|
||||
-- null_ls.builtins.diagnostics.ansiblelint,
|
||||
-- Shell
|
||||
null_ls.builtins.diagnostics.shellcheck,
|
||||
-- Rust
|
||||
-- null_ls.builtins.formatting.rustfmt,
|
||||
-- Lua
|
||||
null_ls.builtins.diagnostics.luacheck,
|
||||
null_ls.builtins.formatting.stylua,
|
||||
},
|
||||
})
|
||||
end)
|
||||
end
|
||||
on_attach = default_attach,
|
||||
capabilities = merged_capabilities(),
|
||||
sources = {
|
||||
-- Generic
|
||||
-- null_ls.builtins.formatting.preittier,
|
||||
-- null_ls.builtins.formatting.trim_whitespace,
|
||||
-- null_ls.builtins.formatting.trim_newlines,
|
||||
-- Fish
|
||||
-- null_ls.builtins.formatting.fish_indent,
|
||||
-- Python
|
||||
null_ls.builtins.formatting.reorder_python_imports,
|
||||
null_ls.builtins.formatting.black,
|
||||
null_ls.builtins.diagnostics.mypy,
|
||||
-- Go
|
||||
null_ls.builtins.diagnostics.golangci_lint,
|
||||
-- Text
|
||||
-- null_ls.builtins.code_actions.proselint,
|
||||
-- Ansible
|
||||
-- null_ls.builtins.diagnostics.ansiblelint,
|
||||
-- Shell
|
||||
null_ls.builtins.diagnostics.shellcheck,
|
||||
-- Rust
|
||||
-- null_ls.builtins.formatting.rustfmt,
|
||||
-- Lua
|
||||
null_ls.builtins.diagnostics.luacheck,
|
||||
null_ls.builtins.formatting.stylua,
|
||||
},
|
||||
})
|
||||
end)
|
||||
end
|
||||
return M
|
||||
|
@ -114,7 +114,6 @@ function M.try_require(name, on_found, on_notfound)
|
||||
|
||||
return nil
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
return M
|
||||
|
Loading…
Reference in New Issue
Block a user