Example #1
0
 public void TarCopyToFile()
 {
     using (var file = File.OpenRead("ITest.zip"))
         using (var archive = new ZipArchive(file))
             using (var outputFile = File.OpenWrite("outputZip.tar"))
             {
                 var zipConverted = new ZipConverter(archive);
                 var output       = new TarFile(zipConverted.NextEntry);
                 output.CopyTo(outputFile);
             }
 }
Example #2
0
 public void EmptyZipCopyToTar()
 {
     using (var newFile = File.OpenRead("empty.zip"))
         using (var emptyZip = new ZipArchive(newFile))
             using (var outputFile = File.OpenWrite("emptyTarOutput.tar"))
             {
                 var zipConverted = new ZipConverter(emptyZip);
                 var output       = new TarFile(zipConverted.NextEntry);
                 output.CopyTo(outputFile);
             }
 }