diff --git a/MAC_build_install.sh b/MAC_build_install.sh index e17f1778..6bfb395e 100644 --- a/MAC_build_install.sh +++ b/MAC_build_install.sh @@ -128,7 +128,7 @@ then exit 1 fi fi -if [ ! -e ~/"Lybrary/Application Support/LogDoctor/help" ] +if [ -e ~/"Lybrary/Application Support/LogDoctor/help" ] then rm -r ~/"Lybrary/Application Support/LogDoctor/help" if [[ "$?" != "0" ]] @@ -145,20 +145,20 @@ then fi -cp -r ./osx_bundle/* ../build/LogDoctor.app/Contents/ +cp -r ./osx_bundle/{bin,doc,Resources,info.plist} ../build/LogDoctor.app/Contents/ if [ -e /Applications/LogDoctor.app ] then sudo rm -r /Applications/LogDoctor.app if [[ "$?" != "0" ]] then - echo "Error: failed to remove old bundle: /Applications/LogDoctor.app" + echo "Error: failed to remove old app bundle: /Applications/LogDoctor.app" exit 1 fi fi sudo mv ../build/LogDoctor.app /Applications/ if [[ "$?" != "0" ]] then - echo "Error: failed to copy the executable" + echo "Error: failed to copy the app bundle" exit 1 fi diff --git a/MAC_build_update.sh b/MAC_build_update.sh index 6e0b6d8d..626039dc 100644 --- a/MAC_build_update.sh +++ b/MAC_build_update.sh @@ -77,7 +77,7 @@ then exit 1 fi fi -if [ ! -e ~/"Lybrary/Application Support/LogDoctor/help" ] +if [ -e ~/"Lybrary/Application Support/LogDoctor/help" ] then rm -r ~/"Lybrary/Application Support/LogDoctor/help" if [[ "$?" != "0" ]] @@ -94,12 +94,17 @@ then fi -cp ./osx_bundle/* ../build/LogDoctor.app/Contents/ +cp ./osx_bundle/{bin,doc,Resources,info.plist} ../build/LogDoctor.app/Contents/ sudo rm -r /Applications/LogDoctor.app +if [[ "$?" != "0" ]] +then + echo "Error: failed to remove the old app bundle" + exit 1 +fi sudo mv ../build/LogDoctor.app /Applications/ if [[ "$?" != "0" ]] then - echo "Error: failed to copy the executable" + echo "Error: failed to copy the app bundle" exit 1 fi diff --git a/WIN_build_install_1.bat b/WIN_build_install_1.bat index 4d96f4f2..a94423bc 100644 --- a/WIN_build_install_1.bat +++ b/WIN_build_install_1.bat @@ -16,6 +16,8 @@ cd %logdocdir% :: Check for a previous installation IF EXIST "C:\Program Files\LogDoctor" ( ECHO Warning: a previous installation exists, please run the 'update' scripts instead + cd "%actual_path%" + PAUSE EXIT /B 0 ) diff --git a/WIN_build_update_1.bat b/WIN_build_update_1.bat index 6acfb8f4..f12afc4b 100644 --- a/WIN_build_update_1.bat +++ b/WIN_build_update_1.bat @@ -16,6 +16,8 @@ cd %logdocdir% :: Check for a previous installation IF NOT EXIST "C:\Program Files\LogDoctor" ( ECHO Warning: no previous installation detected, please run the 'install' scripts instead + cd "%actual_path%" + PAUSE EXIT /B 0 )