# Directories And Download
# ----------------------------------------
# Create Directories
%TEST_CMD% ! -z %EPICSBASE_MYHOMEDIR% && %MKDIR_CMD% %EPICSBASE_MYHOMEDIR% || %DIE_CMD%
%TEST_CMD% ! -z %EPICSBASE_DOWNLOADPATH% && %MKDIR_CMD% %EPICSBASE_DOWNLOADPATH% || %DIE_CMD%
# Download source
%CD_CMD% %EPICSBASE_DOWNLOADPATH% &&
%WGET_CMD% %EPICSBASE_DIRECTDOWNLOADADRESS%/%EPICSBASE_TARFILENAME% || %DIE_CMD%
# Check and change file permissions [ and group settings (if you are in ==%UNIXGROUP%) ]
%CD_CMD% %EPICSBASE_DOWNLOADPATH% && %CHECK_GROUPSSETTING% %UNIXGROUP% && %CHANGEGRP_CMD% %UNIXGROUP% %EPICSBASE_DOWNLOADPATH%
%CHANGEMOD_FIND_CMD_BEGIN% %EPICSBASE_DOWNLOADPATH% %CHANGEMOD_FIND_CMD_END%
# Extract code and link
%CD_CMD% %EPICSBASE_INSTALLDIR%
&& %UNTAR_CMD% %EPICSBASE_DOWNLOADPATH%/%EPICSBASE_TARFILENAME% || %DIE_CMD%
%CD_CMD% %EPICSBASE_INSTALLDIR% && %LN_CMD% base-* base || %DIE_CMD%