aboutsummaryrefslogtreecommitdiffstats
path: root/global-functions
diff options
context:
space:
mode:
Diffstat (limited to 'global-functions')
-rw-r--r--global-functions6
1 files changed, 6 insertions, 0 deletions
diff --git a/global-functions b/global-functions
index 2163f73..4ff2a7a 100644
--- a/global-functions
+++ b/global-functions
@@ -251,6 +251,7 @@
:global CertificateAvailable;
:global CleanFilePath;
:global LogPrintExit2;
+ :global MkDir;
:global WaitForFile;
:if ([ :len $PkgName ] = 0) do={ :return false; }
@@ -263,6 +264,11 @@
}
:local PkgDest [ $CleanFilePath ($PkgDir . "/" . $PkgFile) ];
+ :if ([ $MkDir $PkgDir ] = false) do={
+ $LogPrintExit2 warning $0 ("Failed creating directory, not downloading package.") false;
+ :return false;
+ }
+
:if ([ :len [ / file find where name=$PkgDest type="package" ] ] > 0) do={
$LogPrintExit2 info $0 ("Package file " . $PkgName . " already exists.") false;
:return true;