@@ -286,7 +286,11 @@ function CreateWriteableDir () {
286286 if [ ! -d " ${path} " ]; then
287287 write " Creating ${desc} folder..." $color_primary
288288 # sudo
289- mkdir -p " ${path} " > /dev/null 2> /dev/null
289+ if [ " ${verbosity} " = " loud" ]; then
290+ mkdir -p " ${path} "
291+ else
292+ mkdir -p " ${path} " > /dev/null 2> /dev/null
293+ fi
290294 if [ $? -eq 0 ]; then
291295 writeLine " done" $color_success
292296 else
@@ -1701,9 +1705,9 @@ function installRequiredPythonPackages () {
17011705 # writeLine "${venvPythonCmdPath} -m pip install $pipFlags -r ${requirementsPath} --target ${packagesDirPath}" $color_info
17021706 write ' Installing Packages into Virtual Environment...' $color_primary
17031707 if [ " ${verbosity} " = " loud" ]; then
1704- " $venvPythonCmdPath " -m pip install $pipFlags -r " ${requirementsPath} " --target ${packagesDirPath}
1708+ " $venvPythonCmdPath " -m pip install $pipFlags -r " ${requirementsPath} " --target " ${packagesDirPath} "
17051709 else
1706- " $venvPythonCmdPath " -m pip install $pipFlags -r " ${requirementsPath} " --target ${packagesDirPath} > /dev/null &
1710+ " $venvPythonCmdPath " -m pip install $pipFlags -r " ${requirementsPath} " --target " ${packagesDirPath} " > /dev/null &
17071711 spin $!
17081712 fi
17091713 writeLine ' Success' $color_success
@@ -1777,9 +1781,9 @@ function installRequiredPythonPackages () {
17771781 if [ " ${os} " = " linux" ] || [ " ${os} " = " macos" ]; then
17781782 # No, I don't know why eval is needed in Linux but not elsewhere
17791783 if [ " ${verbosity} " = " loud" ]; then
1780- eval " ${venvPythonCmdPath} " -m pip install " ${package_name} " --target " ${packagesDirPath} " ${currentOption} ${pipFlags}
1784+ eval " \ $ {venvPythonCmdPath}" -m pip install " ${package_name} " --target " \ $ {packagesDirPath}" ${currentOption} ${pipFlags}
17811785 else
1782- eval " ${venvPythonCmdPath} " -m pip install " ${package_name} " --target " ${packagesDirPath} " ${currentOption} ${pipFlags} > /dev/null 2> /dev/null &
1786+ eval " \ $ {venvPythonCmdPath}" -m pip install " ${package_name} " --target " \ $ {packagesDirPath}" ${currentOption} ${pipFlags} > /dev/null 2> /dev/null &
17831787 spin $!
17841788 fi
17851789 else
@@ -2193,9 +2197,9 @@ function getValueFromModuleSettingsFile () {
21932197 local moduleId=$2
21942198 local property=$3
21952199
2196- # if [ "$verbosity" = "loud" ]; then
2197- # echo "Searching for '${property}' in a suitable modulesettings.json file in ${moduleDirPath}" >&3
2198- # fi
2200+ if [ " $verbosity " = " loud" ] && [ " $debug_json_parse " == " true " ]; then
2201+ echo " Searching for '${property} ' in a suitable modulesettings.json file in ${moduleDirPath} " >&3
2202+ fi
21992203
22002204 # Module settings files are loaded in this order. Each file will overwrite (but not delete)
22012205 # settings of the previous file. Becuase of this, we're going to search the files in REVERSE
@@ -2250,7 +2254,7 @@ function getValueFromModuleSettingsFile () {
22502254 if [ " ${moduleSettingValue} " != " " ]; then settings_file_used=" modulesettings.json" ; fi
22512255 fi
22522256
2253- if [ false ] && [ " $verbosity " = " loud " ]; then
2257+ if [ " $verbosity " = " loud " ] && [ " $debug_json_parse " == " true " ]; then
22542258 if [ " ${moduleSettingValue} " = " " ]; then
22552259 echo " Cannot find ${moduleId} .${property} in modulesettings in ${moduleDirPath} " >&3
22562260 else
@@ -2303,7 +2307,10 @@ function getValueFromModuleSettings () {
23032307 key=$" .Modules.${moduleId} .${property} "
23042308 fi
23052309
2306- # echo jsonFile is $json_file >&3
2310+ if [ " $verbosity " = " loud" ] && [ " $debug_json_parse " == " true" ]; then
2311+ echo jsonFile is $json_file >&3
2312+ echo parse_mode is $parse_mode >&3
2313+ fi
23072314
23082315 if [ -f " $json_file " ]; then
23092316 if [ " $parse_mode " = " jq" ]; then
@@ -2332,9 +2339,7 @@ function getValueFromModuleSettings () {
23322339
23332340 # Do the extraction
23342341 jsonValue=$( echo " $file_contents " | jq -r " $key " )
2335- # echo "jsonValue = $jsonValue" >&3
2336- # quit
2337-
2342+
23382343 elif [ " $parse_mode " = " parsejson" ]; then
23392344
23402345 # Let's back in this huge earth mover to plant my flower pots. Even
@@ -2366,9 +2371,10 @@ function getValueFromModuleSettings () {
23662371 # Really??
23672372 if [ " $jsonValue " == " null" ]; then jsonValue=" " ; fi
23682373
2369- # debug
2370- # if [ "$verbosity" = "loud" ]; then echo "${key} = $jsonValue" >&3; fi
2371-
2374+ if [ " $verbosity " = " loud" ] && [ " $debug_json_parse " == " true" ]; then
2375+ echo " ${key} = $jsonValue " >&3 ;
2376+ fi
2377+
23722378 echo $jsonValue
23732379}
23742380
@@ -2516,23 +2522,34 @@ function displayMacOSDirCreatePermissionError () {
25162522
25172523 haveDisplayedMacOSDirCreatePermissionError=true
25182524
2525+ writeLine ' '
25192526 writeLine ' '
25202527 writeLine ' We may be able to suggest something:' $color_info
25212528
2522- # Note that will appear as the Apple symbol on macOS, but probably not on Windows or Linux
2523- writeLine ' 1. Pull down the Apple menu and choose "System Preferences"'
2524- writeLine ' 2. Choose “Security & Privacy” control panel'
2525- writeLine ' 3. Now select the “Privacy” tab, then from the left-side menu select'
2526- writeLine ' “Full Disk Access”'
2527- writeLine ' 4. Click the lock icon in the lower left corner of the preference '
2528- writeLine ' panel and authenticate with an admin level login'
2529- writeLine ' 5. Now click the [+] plus button so we can full disk access to Terminal'
2530- writeLine " 6. Navigate to the /Applications/Utilities/ folder and choose 'Terminal'"
2531- writeLine ' to grant Terminal Full Disk Access privileges'
2532- writeLine ' 7. Relaunch Terminal, the “Operation not permitted” error messages should'
2533- writeLine ' be gone'
2534- writeLine
2535- writeLine ' Thanks to https://osxdaily.com/2018/10/09/fix-operation-not-permitted-terminal-error-macos/'
2529+ if [ " $os_name " = " Sonoma" ]; then # macOS 14 / Kernal 23
2530+ # Note that will appear as the Apple symbol on macOS, but probably not on Windows or Linux
2531+ writeLine ' 1. Pull down the Apple menu and choose "System Settings"'
2532+ writeLine ' 2. Choose “Privacy & Security"'
2533+ writeLine ' 3. Scroll down to “Full Disk Access” and click the right arrow >'
2534+ writeLine ' 4. Click the [+] plus button, and in the popup, navigate to the'
2535+ writeLine ' /Applications/Utilities/ folder and choose "Terminal"'
2536+ writeLine ' 5. Relaunch Terminal. The “Operation not permitted” error messages should'
2537+ writeLine ' be gone'
2538+ else
2539+ writeLine ' 1. Pull down the Apple menu and choose "System Preferences"'
2540+ writeLine ' 2. Choose “Security & Privacy” control panel'
2541+ writeLine ' 3. Now select the “Privacy” tab, then from the left-side menu select'
2542+ writeLine ' “Full Disk Access”'
2543+ writeLine ' 4. Click the lock icon in the lower left corner of the preference '
2544+ writeLine ' panel and authenticate with an admin level login'
2545+ writeLine ' 5. Now click the [+] plus button so we can full disk access to Terminal'
2546+ writeLine " 6. Navigate to the /Applications/Utilities/ folder and choose 'Terminal'"
2547+ writeLine ' to grant Terminal Full Disk Access privileges'
2548+ writeLine ' 7. Relaunch Terminal, the “Operation not permitted” error messages should'
2549+ writeLine ' be gone'
2550+ fi
2551+
2552+ writeLine ' '
25362553 fi
25372554
25382555 # quit 8 # unable to create file or directory
0 commit comments