VSCode 集成终端参数:当前文件名 [英] VSCode integrated terminal argument: current filename
本文介绍了VSCode 集成终端参数:当前文件名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
在VSCode中我想将当前文件名传递给集成终端有一个设置:
In VSCode I want to pass the current file name to the integrated terminal There is a setting:
"terminal.integrated.shell.windows": "C:\\WINDOWS\\System32\\WindowsPowerShell\\v1.0\\powershell.exe",
如何添加当前文件名,例如这会很棒:
How can I add the current file name, for example this would be great:
"terminal.integrated.shell.windows": "C:\\WINDOWS\\System32\\WindowsPowerShell\\v1.0\\powershell.exe %CurrentFileName%",
谢谢.
推荐答案
shell 参数 将在 terminal.integrated.shellArgs.powershell
尝试使用应替换的变量之一按其实际价值
"terminal.integrated.shellArgs.powershell": ["${file}"]
这篇关于VSCode 集成终端参数:当前文件名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文