2
我在Powerhell腳本中有一個函數,它應該解開我的CppUnit.tar.bz2文件。我已經安裝了7-ZIP,並在我的功能我有以下幾點:在Windows命令行上使用7-zip的Untar * .tar.bz2
Function untar ($targetFile) {
$z ="7z.exe"
$defaultDestinationFolder = 'C:\Program Files\'
$destinationFolder = (Get-Item $defaultDesitantionFolder).fullname
$tarbz2Source = $targetFile
& "$z" x -y $tarbz2Source
$tarSource = (get-item $targetFile).basename
& "$z" x -y $tarSource -o $destinationFolder
Remove-Item $tarSource
}
運行此提取所有,我想他們的文件,但所有文件獲得「V」作爲自己的結局:
...
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\estring.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestSuite.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\Test.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestCase.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TextTestResult.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\Makefile.am,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestSuite.cpp,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\Exception.cpp,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\cppunit.dsw,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestFailure.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestCaller.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestResult.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TextTestResult.cpp,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestRegistry.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestFailure.cpp,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\Exception.h,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestRegistry.cpp,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\cppunit.dsp,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestResult.cpp,v
Extracting cppunit-cvs-repo-archive\cppunit\cppunit\Attic\TestCase.cpp,v
Everything is Ok
Folders: 149
Files: 1128
Size: 20671974
Compressed: 21626880
誰能告訴我怎麼解決這個問題?
啊哈,謝謝。這確實是解決方案! –
下載正確的cppunit軟件包,運行該功能,它都很好。 :) –