diff --git a/nix-helpers.psm1 b/nix-helpers.psm1 index 0f00e21..ed50056 100644 --- a/nix-helpers.psm1 +++ b/nix-helpers.psm1 @@ -25,18 +25,15 @@ function Create-TarArchive { ) $arguments = @( - "-c", - "-f", $ArchivePath, - "." + "-c", "--$CompressionType" ) - If ($CompressionType) { - $arguments += "--${CompressionType}" - } if ($DereferenceSymlinks) { $arguments += "-h" } + $arguments += @("-f", $ArchivePath, ".") + Push-Location $SourceFolder Write-Debug "tar $arguments" tar @arguments