Advertisement
flypip

FlyMail(GeekTool)

Jul 9th, 2012
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. tell application "System Events"
  2.     set processList to (name of every process)
  3. end tell
  4. if processList contains "Mail" then
  5.     tell application "Mail"
  6.         if (unread count of inbox) > 0 then
  7.             set messageList to (messages of inbox) whose read status is false
  8.             set output to ""
  9.             repeat with itemNum from 1 to (unread count of inbox)
  10.                 set output to output & (extract name from sender of item itemNum of messageList) & ": " & subject of item itemNum of messageList & return
  11.             end repeat
  12.         end if
  13.     end tell
  14. else
  15.     set output to "Mail nest pas ouvert"
  16. end if
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement