开发者

How do I check a binary exists in the PATH in a Vim plugin?

I'm writing a Vim plugin. I need to call a binary开发者_运维技巧 which should be in the PATH. But I want to display an error message if its not. Whats the best way to find out if the binary is in the PATH?

I'm hoping to find a solution that is portable across different operating systems. But that doesn't seem very easy and I'll settle for a solution that works on unix/linux/mac.


Check this: :help executable()

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜