在 mac capitan 上为 vim 设置应用程序路径

Set path to applications for vim on mac capitan

我已经使用 vim 在 python 中制作小脚本并在 LaTeX 中排版。因此,通过键入 :!python:!pdflatex 等,对来自 vim 的 运行 应用程序非常有用。但是在升级到 el capitan 之后,这似乎不再起作用了,收到类似 /bin/bash: pdflatex: command not found 的消息。但有趣的是,可以直接从终端 运行 应用程序。任何人都知道如何为 vim 设置正确的吗?

$PATH variable not properly set in gvim/MacVim when it is opened from the finder 首先检查 :!echo $SHELL 并查看 SHELL 是否设置为 bash 或

然后尝试在 ~/.bash_profile?

中设置路径
export PATH=<dir_contains_pdflatex>:$PATH