SQL extension for coc.nvim
- Format by sql-formatter
- Lint by node-sql-parser
:CocInstall coc-sql
sql.Format
for current file
sql.lintOnOpen
: Lint sql file on opening, defaulttrue
sql.lintOnChange
: Lint sql file on change, defaulttrue
sql.lintOnSave
: Lint sql file on save, defaulttrue
sql.database
: Choose the database syntax flavor, default toguess
sql.formatOptions
: Format options passed tosql-formatter
, checkout https://github.com/zeroturnaround/sql-formatter
:call CocAction('format')
:CocCommand sql.Format
xmap <leader>f <Plug>(coc-format-selected)
nmap <leader>f <Plug>(coc-format-selected)
MIT