Checking your Maintenance runs

I occasionally want to see if the daily, weekly, and monthly maintenance scripts have been running. Although the shell script embedded in the first statement will tell you, I just run this to get a neat dialog.

-- Check daily, weekly, monthlies
set maintain to paragraphs of (do shell script "ls -al /var/log/*.out")
set tRuns to {}
set tid to AppleScript's text item delimiters
repeat with P in maintain
	set AppleScript's text item delimiters to "root  wheel  "
	set tPart to text item 2 of P
	set AppleScript's text item delimiters to "/log/"
	set tTask to word 1 of text item 2 of tPart
	set AppleScript's text item delimiters to " /var/"
	set tDate to words 2 thru -1 of text item 1 of tPart
	tell tDate to set end of tRuns to tTask & " done on " & item 1 & " " & item 2 & " at " & item 3 & ":" & item 4
end repeat
set AppleScript's text item delimiters to return
display dialog tRuns as text
set AppleScript's text item delimiters to tid