我試圖使用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