node-versions/helpers/nix-helpers.psm1

16 lines
336 B
PowerShell
Raw Normal View History

2020-04-23 02:51:34 +00:00
<#
.SYNOPSIS
Unpack *.tar file
#>
2020-04-23 03:01:40 +00:00
function Extract-TarArchive {
2020-04-23 02:51:34 +00:00
param(
[Parameter(Mandatory=$true)]
[String]$ArchivePath,
[Parameter(Mandatory=$true)]
[String]$OutputDirectory
)
2020-04-23 03:01:40 +00:00
Write-Debug "Extract $ArchivePath to $OutputDirectory"
tar -C $OutputDirectory -xzf $ArchivePath --strip 1
2020-04-23 02:51:34 +00:00
}