From 3f1a9968fc643bb94c557f5641e0e65abfcb7b84 Mon Sep 17 00:00:00 2001 From: PrincessPi3 Date: Tue, 12 Nov 2024 11:45:09 -0700 Subject: [PATCH] 60-rc1.2 --- add-to-export-sh.txt | 6 +++--- reinstall-esp-idf.sh | 33 ++++++++++++++++++--------------- version.txt | 2 +- 3 files changed, 22 insertions(+), 19 deletions(-) diff --git a/add-to-export-sh.txt b/add-to-export-sh.txt index 27c0df5..7ea844d 100644 --- a/add-to-export-sh.txt +++ b/add-to-export-sh.txt @@ -7,9 +7,9 @@ echo "\n=======CUSTOM=======\n" -versionData="versionTAG" -commitHash="commitTagTAG" -installDate="installDateTAG" +versionData=versionTAG +commitHash=commitTAG +installDate=installDateTAG if [ -z $ESPIDF_INSTALLDIR ]; then echo "\nFAIL: ESPIDF_INSTALLDIR environment variable not found!\nReinstall via script or manually add to ~/.zshrc\n" diff --git a/reinstall-esp-idf.sh b/reinstall-esp-idf.sh index 39cc1f6..0eca422 100644 --- a/reinstall-esp-idf.sh +++ b/reinstall-esp-idf.sh @@ -28,7 +28,7 @@ gitCmd="git clone --jobs $gitJobs --branch $gitBranch --single-branch https://gi installCmd="$idfDir/install.sh all" -toolsInstallCmd="python $idfDir/tools/idf_tools.py install all" +toolsInstallCmd="$idfDir/tools/idf_tools.py install all" # full order: # set action string variable @@ -91,23 +91,25 @@ function handleExport() { writeToLog "Handling export.sh (function ran)" writeToLog "backing up ${idfDir}/export.sh to ${idfDir}/export.sh.bak" - cp $idfDir/export.sh $idfDir/export.sh.bakno - returnStatus - - writeToLog "editing ${idfDir}/export.sh" - sed -i 's/return 0/# return 0/g' $idfDir/export.sh + cp $idfDir/export.sh $idfDir/export.sh.bak returnStatus writeToLog "adding ${runningDir}/add-to-export-sh.txt to ${idfDir}/export.sh" cat $runningDir/add-to-export-sh.txt >> $idfDir/export.sh returnStatus - writeToLog "editing $idfDir/export.sh with version information" - sed -i "s/versionTAG/${versionData}/g" $idfDir/export.sh + writeToLog "editing ${idfDir}/export.sh" + sed -i 's/return 0/# return 0/g' $idfDir/export.sh returnStatus + writeToLog "editing $idfDir/export.sh with version information" + sed -i "s/versionTAG/'$versionData'/g" $idfDir/export.sh + returnStatus + + dateStampInstall=$(date '+%d/%m/%Y %H:%M:%S %Z (%s)') + writeToLog "editing $idfDir/export.sh with install date information" - sed -i "s/versionTAG/$(date '+%d/%m/%Y %H:%M:%S %Z (%s)')/g" $idfDir/export.sh + sed -i "s/installDateTAG/'$dateStampInstall'/g" $idfDir/export.sh returnStatus } @@ -158,7 +160,7 @@ function handleDownloadInstall() { eval "$gitCmd" returnStatus - writeToLog "installing with ${idfDir}/install.sh all" + writeToLog "installing with \`eval \"${idfDir}/install.sh all\"\`" eval "$installCmd" returnStatus @@ -168,12 +170,13 @@ function handleDownloadInstall() { return else writeToLog "IDF_PYTHON_ENV_PATH: $IDF_PYTHON_ENV_PATH" - ls -lah $IDF_PYTHON_ENV_PATH/bin/python + idfPython=$IDF_PYTHON_ENV_PATH/bin/python + ls $idfPython returnStatus fi - writeToLog "installing tools with python ${idfDir}/tools/idf_tools.py install all" - eval "$toolsInstallCmd" + writeToLog "installing tools with \`eval \"$idfPython $toolsInstallCmd\"\`" + eval "$idfPython $toolsInstallCmd" returnStatus writeToLog "getting the commit hash" @@ -181,7 +184,7 @@ function handleDownloadInstall() { returnStatus writeToLog "editing $idfDir/export.sh with git commit hash data" - sed -i "s/commitTagTAG/${commitHash}/g" $idfDir/export.sh + sed -i "s/commitTAG/'commitHash'/g" $idfDir/export.sh returnStatus gitDataLog="installed esp-idf from commit $commitHash from branch $gitBranch using $scriptVers" @@ -294,7 +297,7 @@ elif [ "$arg" == "test" -o "$arg" == "t" ]; then # minimal actions taken, echo t installCmd="echo $idfDir/install.sh all" - toolsInstallCmd="echo python $idfDir/tools/idf_tools.py install all" + toolsInstallCmd="echo $idfDir/tools/idf_tools.py install all" sleepMins=0 diff --git a/version.txt b/version.txt index 4c3a007..8a3b906 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -60-rc1.1 \ No newline at end of file +60-rc1.2 \ No newline at end of file