• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How to put logs in console using AppleScript
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to put logs in console using AppleScript


  • Subject: Re: How to put logs in console using AppleScript
  • From: Tim Mansour <email@hidden>
  • Date: Fri, 9 Oct 2009 17:41:03 +1100

2009/10/9 Infosys Deepak <email@hidden>
>
> I am trying to put logs in console using the below command:
> tell application "Mail" to log "Test"
> I am not seeing this message in the console. Please let me know if the above script is correct ?

Deepak I think you'll find that Mail does not have a "log" command.
Script Editor does, so perhaps that's where you got it from. In any
case, I usually use something like this:

set log_text to "test"
do shell script "echo \"" & log_text & "\" >> $HOME/Library/Logs/myfile.log"

--
Tim Mansour <email@hidden>

"How vain it is to sit down to write when you have not stood up to
live." -- Henry David Thoreau
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: How to put logs in console using AppleScript
      • From: Tom Robinson <email@hidden>
References: 
 >How to put logs in console using AppleScript (From: Infosys Deepak <email@hidden>)

  • Prev by Date: How to put logs in console using AppleScript
  • Next by Date: Re: Snow Leopard and (old) AppleScript applications
  • Previous by thread: How to put logs in console using AppleScript
  • Next by thread: Re: How to put logs in console using AppleScript
  • Index(es):
    • Date
    • Thread