Re: Folder Size Applescript
Re: Folder Size Applescript
- Subject: Re: Folder Size Applescript
- From: "Adam Bell" <email@hidden>
- Date: Sat, 29 Apr 2006 01:03:23 -0300
Something like this (which given the hour, I haven't checked thoroughly) will set the color label of any folder in PodCasts whose size is greater than 600 MB to red:
on adding folder items to PodCasts after receiving theCasts
tell application "Finder"
set fldrs to folders of (PodCasts as alias) as alias list
repeat with aFolder in fldrs
if ((size of (info for aFolder)) div 1048576) > 600 then set label index of aFolder to 2
end repeat
end tell
end adding folder items to
(*
In the AppleScript Utility,
- click "Setup Actions". In the dialog,
- click "Enable Folder Actions".
- click the plus sign on the column labeled "Folders With Actions". Choose your podCasts folder and click Open.
- in the dropdown box, choose the script that you just saved. Click Attach.
- close the AppleScript Utility.
*)
On 4/28/06, Joseph White <
email@hidden> wrote:Hello,
I am a recent switcher and have just discovered AppleScripts. I have
been trying to educate myself a little on using these scripts, it is
a little difficult because I have no coding experience whatsoever.
I would like to wright a script that would allow me label a folder
with a certain color when the folder reaches a certain size.
For example...in my podcast folder I have many subfolders of the
various podcasts that I subscribe to. Once these subfolders reach
700 MB I want to burn them on a CD and remove them from my hard
drive. Since I subscribe to many podcasts, it is a laborious task to
go searching through each subfolder looking for the ones that are
large enough to burn onto a CD. Therefore it would be very nice, I
think, to have a script to search through all of the subfoders
located in my podcast folder and color label only those subfolders
that are the appropriate size.
If anyone knows a script that would allow me to do this, or if
someone could point me in the right direction I would appreciate it.
Thank you in advance.
--JB
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
email@hidden
--
Some minds remain open long enough for a truth to both enter and leave without processing.
_______________________________________________
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