1
0
Fork 0

Compare commits

..

No commits in common. "2927afe3e2c50ea22b02209945cf25d5e8ae1f68" and "77504f4af04c91aa3a7552975a05bb28b3fcb1b2" have entirely different histories.

16 changed files with 48 additions and 47 deletions

3
.gitmodules vendored
View file

@ -149,6 +149,3 @@
[submodule "pack/general/start/playground"]
path = pack/general/start/playground
url = https://github.com/nvim-treesitter/playground
[submodule "pack/general/start/conform.nvim"]
path = pack/general/start/conform.nvim
url = https://github.com/stevearc/conform.nvim

View file

@ -221,12 +221,17 @@ vim.api.nvim_create_autocmd({ "FileType" }, {
end,
})
---- conform.nvim ----
require("conform").setup({
format_on_save = {
-- These options will be passed to conform.format()
timeout_ms = 500,
lsp_format = "fallback",
---- formatter.nvim ----
require("formatter").setup({
filetype = {
terraform = {
require("formatter.filetypes.terraform").terraformfmt,
},
},
["*"] = {
-- "formatter.filetypes.any" defines default configurations for any
-- filetype
require("formatter.filetypes.any").remove_trailing_whitespace,
},
})
@ -327,9 +332,9 @@ vim.api.nvim_create_autocmd({ "FileType" }, {
vim.keymap.set("n", "[d", vim.diagnostic.goto_prev)
vim.keymap.set("n", "]d", vim.diagnostic.goto_next)
vim.keymap.set("n", "<Leader>q", vim.diagnostic.setloclist)
-- vim.keymap.segcjk("n", "<F3>", function()
-- vim.lsp.buf.format({ async = true })
-- end)
vim.keymap.set("n", "<F3>", function()
vim.lsp.buf.format({ async = true })
end)
end
-- Use a loop to conveniently call 'setup' on multiple servers and
@ -411,26 +416,26 @@ vim.api.nvim_create_autocmd({ "FileType" }, {
end,
})
-- -- Auto format on save
-- vim.api.nvim_create_autocmd({ "BufWritePre" }, {
-- callback = function()
-- if vim.b.disable_format then
-- return
-- end
-- local lsp_format = false
-- for _, client in pairs(vim.lsp.get_clients()) do
-- if client.server_capabilities.documentFormattingProvider then
-- lsp_format = true
-- break
-- end
-- end
-- if lsp_format then
-- vim.lsp.buf.format({ async = false })
-- else
-- vim.cmd("Format")
-- end
-- end,
-- })
-- Auto format on save
vim.api.nvim_create_autocmd({ "BufWritePre" }, {
callback = function()
if vim.b.disable_format then
return
end
local lsp_format = false
for _, client in pairs(vim.lsp.buf_get_clients()) do
if client.server_capabilities.documentFormattingProvider then
lsp_format = true
break
end
end
if lsp_format then
vim.lsp.buf.format({ async = false })
else
vim.cmd("Format")
end
end,
})
---- nvim-lint ----
local lint = require("lint")
@ -675,7 +680,7 @@ vim.api.nvim_create_autocmd({ "BufEnter" }, {
vim.cmd("packadd crates.nvim")
local crates = require("crates")
crates.setup({})
crates.setup()
vim.keymap.set("n", "<leader>cv", crates.show_versions_popup)
vim.keymap.set("n", "<leader>cf", crates.show_features_popup)
vim.keymap.set("n", "<leader>cd", crates.show_dependencies_popup)

@ -1 +1 @@
Subproject commit eecd13449945ee2c064e00c618dfec9b2d856ea3
Subproject commit 0c8436cb10e9ac62354baa5874a4a3413f2432c1

@ -1 +1 @@
Subproject commit 26ed90509c377d10dbdebd25b7094a886323b32b
Subproject commit 6f35d797882c6ce0ab7c87dc86561512dc3d7aba

@ -1 +1 @@
Subproject commit 9c9eb07fecc578e25e28db8dc9002b43fff2ed79
Subproject commit 92166b89ab4b3d60f24e58170cac53b7141fd032

@ -1 +1 @@
Subproject commit e30b7f2008e52442154b66f7c519bfd2f1e32acb
Subproject commit 0236521ea582747b58869cb72f70ccfa967d2e89

@ -1 +1 @@
Subproject commit 50fcf17db7c75af80e6b6109acfbfb4504768780
Subproject commit 2b6860d15aaab01d3fb90859c0ba97f20ad7bc5f

@ -1 +0,0 @@
Subproject commit 9a06e83527407a7600a2fe4e0d10adf432b6215e

@ -1 +1 @@
Subproject commit 8df63f2ddc615feb71fd4aee45a4cee022876df1
Subproject commit 379a5a915aea3e9ba0d4a778e8478584ac0f9011

@ -1 +1 @@
Subproject commit a110e12d0b58eefcf5b771f533fc2cf3050680ac
Subproject commit 5260e5e8ecadaf13e6b82cf867a909f54e15fd07

@ -1 +1 @@
Subproject commit 941fa1220a61797a51f3af9ec6b7d74c8c7367ce
Subproject commit 1a3a8d047bc01f1760ae4a0f5e80f111ea222e67

@ -1 +1 @@
Subproject commit b36bf49d097a09781ad6ac0cfea28b40b74570a3
Subproject commit f1f0699a1d49f28e607ffa4361f1bbe757ac5ebc

@ -1 +1 @@
Subproject commit 9d80c1497ec343f81c0c5800b65f2e73ca569025
Subproject commit 3a74b5831058d0daf8952a5b8c556c61b30a3f46

@ -1 +1 @@
Subproject commit c0cfc1738361b5da1cd0a962dd6f774cc444f856
Subproject commit b77921fdc44833c994fdb389d658ccbce5490c16

@ -1 +1 @@
Subproject commit 11668478677de360dea45cf2b090d34f21b8ae07
Subproject commit 2ef7da3a363890686dbaad18ddbf59177cfe4f78

@ -1 +1 @@
Subproject commit f2bfde705ac752c52544d5cfa8b0aee0a766c1ed
Subproject commit dfa230be84a044e7f546a6c2b0a403c739732b86