summaryrefslogtreecommitdiff
path: root/ftplugin/go.lua
diff options
context:
space:
mode:
authorJacek Kiedrowski <[email protected]>2021-07-05 23:26:25 +0100
committerGitHub <[email protected]>2021-07-05 23:26:25 +0100
commit5b497747448b3946675f7361c9667bb0dc1da11a (patch)
treef9f08a2729f7f3134675114ac97e128a8be08ee7 /ftplugin/go.lua
parent64e544b56114f7b93a56814067caa28c83cfaec4 (diff)
parenta469c710bfc01f291df68dba40464caaa2b496da (diff)
Merge branch 'ChristianChiarulli:master' into master
Diffstat (limited to 'ftplugin/go.lua')
-rw-r--r--ftplugin/go.lua18
1 files changed, 4 insertions, 14 deletions
diff --git a/ftplugin/go.lua b/ftplugin/go.lua
index 0bee465f..56b9cacc 100644
--- a/ftplugin/go.lua
+++ b/ftplugin/go.lua
@@ -6,17 +6,7 @@ require("lspconfig").gopls.setup {
on_attach = require("lsp").common_on_attach,
}
-if O.lang.go.autoformat then
- require("lv-utils").define_augroups {
- _go_format = {
- { "BufWritePre", "*.go", "lua vim.lsp.buf.formatting_sync(nil,1000)" },
- },
- _go = {
- -- Go generally requires Tabs instead of spaces.
- { "FileType", "go", "setlocal tabstop=4" },
- { "FileType", "go", "setlocal shiftwidth=4" },
- { "FileType", "go", "setlocal softtabstop=4" },
- { "FileType", "go", "setlocal noexpandtab" },
- },
- }
-end
+vim.opt_local.tabstop = 4
+vim.opt_local.shiftwidth = 4
+vim.opt_local.softtabstop = 4
+vim.opt_local.expandtab = false