找不到配置文件:/path/to/rubocop.yml

Configuration file not found: /path/to/rubocop.yml

我在 ~/.vim/plugin/ 中保存了文件 rubocop.vim,当我在 Vim 中 运行 :Rubocop 时,我得到

Configuration file not found: /path/to/rubocop.yml.

我找不到 rubocop.yml 的路径。

我使用的是 MacOS Mojave。

谢谢。

从 Vim8 开始,使用新的 "package" 功能更加方便。此处已经涵盖了该主题: vi.stackexchange.com/questions/9522/what-is-the-vim8-package-feature-and-how-should-i-use-it

.rubocop.yml 包含在 Rubocop public 存储库中。

git clone git@github.com:rubocop-hq/rubocop.git