Re: A little help with a folder cleanup script
Re: A little help with a folder cleanup script
- Subject: Re: A little help with a folder cleanup script
- From: "J. Stewart" <email@hidden>
- Date: Wed, 9 Aug 2006 05:09:08 -0400
On 8/8/06 at -0400 Rick Davis said this
>This year I want to clean up last years network home directories to
>prepare for a new year. But I want to leave a list of folders alone
>and move everything else into the documents folder.
>
>This is the list of allowed folders:
>
>Desktop
>Documents
>Downloads
>Library
>Movies
>Music
>Pictures
>profile
>Public
>Roaming Media
>Sites
>
<snip>
>
>Any and all suggestions greatly appreciated.
Something like this should do it though it needs a bit of error checking.
Be careful of line wraping.
--> Cut <--
set aList to {"Desktop", "Documents", "Downloads", "Library", "Movies", "Music", "profile", "Public", "Roaming Media", "Sites"}
set usrFold to path to current user folder
set DocFold to path to "docs"
tell application "Finder" to move (get (every item of usrFold whose name is not in aList) as alias list) to DocFold
--> Cut <--
JBS
--
How many of you believe in telekinesis? Raise my hand...
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden