Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在寻找使用 % char 捕获当前类名(在 java 中) - 但在 vimscript 我想将此字符串值推送到变量中
let objName = % 当前抛出错误,所以我正在寻求帮助(vimscript 新手)
您正在寻找expand().
expand()
let objName = expand('%:t:r')