使用 cTags 在 Vim 中浏览 Phoenix 或 Elixir 的代码库

Navigating Phoenix's or Elixir's Codebase in Vim using cTags

这是我的设置:

Mac OS          10.12.1
ViM             8.0.52
Exuberant Ctags 5.8

我的 .vimrc 有:set tags=tags

我在项目根目录中使用 ctags -R . 生成了标签文件,它在同一文件夹中生成了一个名为 tags 的文件。

我自己的项目文件中的 ctags 导航工作得很好。但是每当我试图查看 Phoenix Framework 本身(或其依赖项)的源代码时,我都会得到

E426: Tag not found: Mix

如何解决此问题并浏览 Phoenix 的源代码?

原来我以某种方式破坏了我的项目安装。

在尝试解决标签的具体问题后,我决定放弃并继续前进。尝试 运行 mix phoenix.server 我得到:

Unchecked dependencies for environment test:

(...) 所有依赖项的列表,包括最后一个:

* phoenix_ecto (Hex package)
  the dependency is not available, run "mix deps.get"
** (Mix) Can't continue due to errors on dependencies

我不知道这是怎么发生的。所以我再次 运行 mix deps.get 并且还不得不再次 运行 npm install 。 (凤凰使用b运行ch)

之后,我 运行 $ ctags -R . 在项目的根目录下,一切正常:项目和 ctags 导航,包括 Phoenix 和 Elixir 的源代码。