Skip to content

Commit 2cac684

Browse files
authored
Universal Packages: Ensure tar destination dir exists (#623)
1 parent daa6c75 commit 2cac684

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/UniversalPackages/DownloadUniversalPackages.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -759,6 +759,8 @@ private bool DownloadAndExtractArchive(string displayName, string downloadUri, s
759759
else
760760
{
761761
// There is no built-in support for extracting tar.gz files, so fall back to the tar command.
762+
// Note: the tar command requires that the destination directory already exist.
763+
Directory.CreateDirectory(archiveExtractPath);
762764
int exitCode = ProcessHelper.Execute(
763765
"/bin/bash",
764766
$"-c \"tar -xzf \\\"{archiveDownloadPath}\\\" -C \\\"{archiveExtractPath}\\\"\"",

0 commit comments

Comments
 (0)