VIM:如何获取当前函数名称

问题描述 投票:0回答:1

在我的vim配置中,我映射了,pt以运行phpunit测试。

map <leader>pt :!clear && vendor/bin/phpunit % --testdox<cr>

但是有时候我想通过使用phpunit --filter运行特定的测试>

map <leader>pt :!clear && vendor/bin/phpunit --filter {FUNCTION_NAME_HERE} % --testdox<cr>

反正我们可以在vim中自动填写函数名称吗?

在我的vim配置中,我映射了pt来运行phpunit测试。映射pt:!clear && vendor / bin / phpunit%--testdox 但有时我想通过使用...

vim vi
1个回答
0
投票

作为文本编辑器

,Vim对底层源代码的结构只有有限的了解。
© www.soinside.com 2019 - 2024. All rights reserved.