【发布时间】:2014-01-15 23:45:42
【问题描述】:
我有以下批处理文件:
"C:\TapTest\PsExec.exe" /accepteula -i -s "C:\TapTest\tapinstall.exe"
-> install "C:\TapTest\driver\OemWin2k.inf" tap0901
批处理文件的位置是:
c:\TapTest\TapInstall.bat
我希望能够执行以下操作(使用相对路径):
"PsExec.exe" /accepteula -i -s "tapinstall.exe" install "driver\OemWin2k.inf" tap0901
但是 tapinstall.exe 需要一个绝对路径作为参数。如何在不硬编码的情况下让批处理文件给出绝对路径?
【问题讨论】:
标签: windows batch-file relative-path absolute-path