我试图使用PowerShell下面的命令来解压缩解压缩 -无法使用PowerShell
powershell.exe -nologo -noprofile -command "& { Add-Type -A 'System.IO.Compression.FileSystem'; [IO.Compression.ZipFile]::ExtractToDirectory('E:\test.zip', 'E:\'); }"
我得到下面登录
'E:\test1.txt'
already exists."
At line:1 char:53
+ & { Add-Type -A 'System.IO.Compression.FileSystem';
[IO.Compression.ZipFile]::Ex ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : IOException
===============================
我没有看到正在解压缩存档。
更新1
E:\ test1.txt的已经存在的目的地。如何更改命令以覆盖文件。
更新2
提供的PowerShell版本不支持Expand-Archive
没有E:\ test1.txt的存在? – ArcSet
是的,E:\ test1.txt存在。我想在解压缩过程中覆盖此文件。 – Apurv
这就是你的问题....我如何用解压文件覆盖文件....我想你应该编辑你的问题 – ArcSet