From 19edc0df5df7aec6ef3a8420c414da845a61e00d Mon Sep 17 00:00:00 2001 From: Greg Neagle Date: Tue, 13 Oct 2009 22:06:31 +0000 Subject: [PATCH] Managed Software Update.app Fixed typo in "Logout Recommended" message Made sure if AppleUpdates required a restart that logout was required. git-svn-id: http://munki.googlecode.com/svn/trunk@251 a4e17f2e-e282-11dd-95e1-755cbddbdd66 --- code/ManagedSoftwareUpdate/Info.plist | 4 ++-- .../ManagedSoftwareUpdate.applescript | 7 +++++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/code/ManagedSoftwareUpdate/Info.plist b/code/ManagedSoftwareUpdate/Info.plist index 6bfb29cc..f54631bc 100644 --- a/code/ManagedSoftwareUpdate/Info.plist +++ b/code/ManagedSoftwareUpdate/Info.plist @@ -17,11 +17,11 @@ CFBundlePackageType APPL CFBundleShortVersionString - 1.2 + 1.3 CFBundleSignature mMSU CFBundleVersion - 1.2 + 1.3 NSAppleScriptEnabled YES NSMainNibFile diff --git a/code/ManagedSoftwareUpdate/ManagedSoftwareUpdate.applescript b/code/ManagedSoftwareUpdate/ManagedSoftwareUpdate.applescript index 31838840..763cd400 100755 --- a/code/ManagedSoftwareUpdate/ManagedSoftwareUpdate.applescript +++ b/code/ManagedSoftwareUpdate/ManagedSoftwareUpdate.applescript @@ -22,6 +22,7 @@ property restartRequired : false property installitems : {} property activationCount : 0 property ManagedInstallPrefs : "/Library/Preferences/ManagedInstalls.plist" +property AppleUpdatesAvailable : false on getRemovalDetailPrefs() set ShowRemovalDetail to false @@ -118,6 +119,8 @@ on itemstoinstall() --set end of installlist to AppleUpdatesHeader repeat with installitem in appleupdatelist set end of installlist to (installitem as item) + set restartRequired to true + set AppleUpdatesAvailable to true end repeat end try end if @@ -190,7 +193,7 @@ on installAll() "A restart is required after updating. Log out and update now?" alternate button "Cancel" default button ¬ "Log out and update" as warning attached to window 1 else - display alert "Logout Recommeded" message ¬ + display alert "Logout Recommended" message ¬ "A logout is recommeded before updating. Log out and update now?" alternate button "Cancel" other button "Update without logging out" default button ¬ "Log out and update" as warning attached to window 1 end if @@ -238,7 +241,7 @@ end selection changed on alert ended theObject with reply withReply if button returned of withReply is "Log out and update" then -- touch a flag so the process that runs after - -- logout knows it's OK to install everything + -- logout knows it's OK to install everything do shell script "/usr/bin/touch /private/tmp/com.googlecode.munki.installatlogout" ignoring application responses tell application "loginwindow"