From 75370e4a75c52bc622d7631749811725910b04a9 Mon Sep 17 00:00:00 2001 From: Zack T Date: Tue, 30 Jan 2018 16:51:16 -0700 Subject: [PATCH] v1.4 = Enable case-insensitive pattern matching for the case statements + Enable case-insensitive pattern matching for the case statements --- Software/Maple/license_Maple.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Software/Maple/license_Maple.sh b/Software/Maple/license_Maple.sh index ee92544..1256463 100755 --- a/Software/Maple/license_Maple.sh +++ b/Software/Maple/license_Maple.sh @@ -3,7 +3,7 @@ ################################################################################################### # Script Name: license_Maple.sh # By: Zack Thompson / Created: 1/8/2018 -# Version: 1.3 / Updated: 1/25/2018 / By: ZT +# Version: 1.4 / Updated: 1/30/2018 / By: ZT # # Description: This script applies the license for Maple applications. # @@ -12,7 +12,8 @@ /usr/bin/logger -s "***** License Maple process: START *****" ################################################## -# Define Variables +# Turn on case-insensitive pattern matching +shopt -s nocasematch # Determine License Mechanism case "${4}" in @@ -29,6 +30,9 @@ ;; esac +# Turn off case-insensitive pattern matching +shopt -u nocasematch + /usr/bin/logger -s "Licensing Mechanism: ${licenseMechanism}" ################################################## @@ -39,7 +43,7 @@ appPaths=$(/usr/bin/find -E /Applications -iregex ".*Maple [0-9]{4}[.]app" -maxd # Verify that a Maple version was found. if [[ -z "${appPaths}" ]]; then - /usr/bin/logger -s "A version of Maple was not located in the expected location!" + /usr/bin/logger -s "A version of Maple was not found in the expected location!" /usr/bin/logger -s "***** License Maple process: FAILED *****" exit 2 else