gofmt formatter doesn't clear quickfix list when all errors are fixed
- 主要语言
- Vim Script
- 星标
- 1.1k
- 派生
- 102
- PR 合并指标
- 30 天内没有已合并 PR
描述
(Forwarding a report from someone else)
I am using the codefmt plugin for Go, by including:
``` vim
Glug codefmt gofmt_executable="goimports"
Glug codefmt-google
autocmd FileType go AutoFormatBuffer gofmt
```
And it looks like it doesn't clear the quick fix list when all errors are fixed. E.g.:
I have 3 errors, and if I save, the quick fix window shows the three of them.
If I fix 1, and save, the quick fix window correctly shows only two of them.
If now I fix the 2 remaining ones, and save, the quick fix window doesn't update at all.
It looks like we only call "setqflist" in the case of errors:
https://github.com/google/vim-codefmt/blob/master/autoload/codefmt.vim#L320
but never clear it if there are no errors.
贡献指南
调研方向
从 autoload/codefmt.vim 中大约第 320 行的位置开始,issue 报告称只有存在错误时才会调用 setqflist。使用 gofmt 或 goimports 重现保存流程,然后验证修复最后一个错误后,quickfix 列表也会被清除,而在仍有错误时列表会继续更新。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- go, vim
- 领域
- tooling
- Issue 类型
- 缺陷
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 活跃度
- 停滞
- 描述清晰度
- 描述清楚
- 新手友好度
- 45/100