image

Disable AppNap system wide on 10.9.x

[<Back>] [<Edit>]

Force Mavericks to exclude everything from AppNap

## “App Nap” - Nasty feature in Mavericks which suppose to save energy (puts services in a hang state).
## Current workaround is to check the “Prevent App Nap” from the Application app info.
## but that only disable appnap for the specific App. Most of the application ( or at least the one i use)
## uses background services which is completely in a separate application

# Run in sudo mode

for service0 in ~/Library/Preferences/*.plist
do
service1=$( echo $service0 | sed -e 's/.plist//' )
service2=$( eval basename $service1 )
defaults write "${service2}" NSAppSleepDisabled -bool YES
done
for service0 in ~/Library/Preferences/*.plist
do
service1=$( echo $service0 | sed -e 's/.plist//' )
service2=$( eval basename $service1 )
defaults read "${service2}" NSAppSleepDisabled
done
##verify everything returns true##
for service0 in /Library/Preferences/*.plist
do
service1=$( echo $service0 | sed -e 's/.plist//' )
service2=$( eval basename $service1 )
defaults write "${service2}" NSAppSleepDisabled -bool YES
done

for service0 in /Library/Preferences/*.plist
do
service1=$( echo $service0 | sed -e 's/.plist//' )
service2=$( eval basename $service1 )
defaults read "${service2}" NSAppSleepDisabled
Done



By: Ted Butler





 
Instagram Stats
pinoy
my Kung Fu