mirror of
https://github.com/golang/go.git
synced 2025-05-05 15:43:04 +00:00
Add auto import and formatting recommendation for coc.nvim
parent
c63b5b097a
commit
030daa5355
6
gopls.md
6
gopls.md
@ -146,6 +146,12 @@ Use [coc.nvim](https://github.com/neoclide/coc.nvim/), with the following `coc-s
|
||||
}
|
||||
```
|
||||
|
||||
To get automatic formatting and imports on save, add the following line to your `init.vim`:
|
||||
|
||||
```vim
|
||||
autocmd BufWritePre *.go :call CocAction("format")
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
#### Vim (classic only)
|
||||
|
Loading…
x
Reference in New Issue
Block a user