Skip to content

Commit

Permalink
feat(compress): Allow 'Expand-InnoArchive -ExtractDir' to accept '{xx…
Browse files Browse the repository at this point in the history
  • Loading branch information
niheaven authored and r15ch13 committed Jun 24, 2019
1 parent e12a7da commit 1caaed8
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/decompress.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,12 @@ function Expand-InnoArchive {
$Removal
)
$LogPath = "$(Split-Path $Path)\innounp.log"
$ArgList = @('-x', "-d`"$DestinationPath`"", "-c`{app`}\$ExtractDir", "`"$Path`"", '-y')
$ArgList = @('-x', "-d`"$DestinationPath`"", "`"$Path`"", '-y')
switch -Regex ($ExtractDir) {
"^[^{].*" { $ArgList += "-c{app}\$ExtractDir" }
"^{.*" { $ArgList += "-c$ExtractDir" }
Default { $ArgList += "-c{app}" }
}
if ($Switches) {
$ArgList += (-split $Switches)
}
Expand Down

0 comments on commit 1caaed8

Please sign in to comment.