You can get tons of information from the file in many different ways. I think the easiest is with the bash tool MDLS, but that's just a personal favorite.
Unfortunately we have to do some awkward (pun?) output tweaking, but its all relatively straightforward. If you want to see the other info available for MDLS, open terminal and run MDLS /path/to/your/file
- Code: Select all
set theName to do shell script "mdls -name kMDItemFSName \"" & thePOSIX & "\" | awk -F ' = ' '{print $2}' | sed 's/\\\"//g'"
set theKind to do shell script "mdls -name kMDItemKind \"" & thePOSIX & "\" | awk -F ' = ' '{print $2}' | sed 's/\\\"//g'"
tell application "Mail"
set theNewMessage to make new outgoing message with properties {subject:"Google Drive File Change Notification", content:"The Name: " & theName & "
The Type:" & theKind &"
Was updated by the client.", visible:true}
tell theNewMessage
make new to recipient at end of to recipients with properties {address:"email.address@me.com"}
send
end tell
end tell
You'll be able to get your meta tags here too, but you'll have to find the item name first.