Re: Scripting OS X Preferences
Re: Scripting OS X Preferences
- Subject: Re: Scripting OS X Preferences
- From: bill <email@hidden>
- Date: Mon, 17 Feb 2003 12:13:40 +0800
>
defaults read com.apple.preference.screensaver
>
>
I get an error: "Domain com.apple.preference.screensaver does not
>
exist."
In Terminal.app, try this one:
defaults -currentHost read com.apple.screensaver
Then, wrap it in do shell script:
do shell script "defaults -currentHost read com.apple.screensaver"
-- "{
askForPassword = 1;
hotCorners = ((0, 1, 0, 0));
idleTime = 300;
moduleName = Flurry;
modulePath = \"/System/Library/Screen Savers/Flurry.saver\";
}"
If you need the module name only:
do shell script "defaults -currentHost read com.apple.screensaver
moduleName"
-- "Flurry"
To change the module, you only need to change the value of modulePath,
however, to avoid confusing, change the moduleName all together:
do shell script "defaults -currentHost write com.apple.screensaver
moduleName Cosmos"
do shell script "defaults -currentHost write com.apple.screensaver
modulePath '/System/Library/Screen Savers/Cosmos.slideSaver'"
Have fun :)
bill
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.