summaryrefslogtreecommitdiff
path: root/ftplugin/go.lua
diff options
context:
space:
mode:
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