如何在PowerShell中打开文件夹?我不是在谈论如何在特定文件夹中启动PowerShell.
我的意思是在powershell的命令行中我想打开一个文件夹,例如:"打开文档"
Sha*_*evy 66
使用Invoke-Itemcmdlet或其别名:ii.
PS> ii c:\windows # open the windows directory in windows explorer
PS> ii c:\book.xls # open book.xls in Excel
PS> ii . # open the current directory in windows explorer
Run Code Online (Sandbox Code Playgroud)
man*_*lds 14
对于Powershell和cmd兼容的方式(我认为最常见的方式):
start .
start c:\
Run Code Online (Sandbox Code Playgroud)
您可以使用explorer.exe打开该文件夹:
explorer.exe c:\temp\
explorer.exe <YourFolderPathHere>
Run Code Online (Sandbox Code Playgroud)