• 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: Copy folder shell scripting
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Copy folder shell scripting


  • Subject: Re: Copy folder shell scripting
  • From: "Mark J. Reed" <email@hidden>
  • Date: Thu, 24 Apr 2008 16:34:57 -0400

>  I tried that like this. I know this particular example is kinda going the
>  long way around but I'm just trying to see how it works. This is on 10.4.11.
>
>
>  #!/bin/sh
>  osascript - "$@" <<EOF
>  do shell script "ls"
>  EOF
>
>  And got this result in Terminal but I don't know what workspacegns means.
>
>  [ip133:~] bruce% /Users/bruce/Desktop/osaText.sh
>  workspacegns

That would be the names of the files output one per line, with the
newlines output by ls converted to returns by AppleScript.   In your
case, I'm guessing the last file in the list was "workspace", and the
"gns" is left over from one or more earlier files.  If you capture the
output and look at it with an editor you should see that.

Try this:

/Users/bruce/Desk/osaText.sh | tr '\r' '\n'



--
Mark J. Reed <email@hidden>
 _______________________________________________
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

References: 
 >Re: Copy folder shell scripting (From: Christopher Nebel <email@hidden>)
 >Re: Copy folder shell scripting (From: Bruce Robertson <email@hidden>)

  • Prev by Date: Re: So simple yet---I need help
  • Next by Date: Re: Copy folder shell scripting
  • Previous by thread: Re: Copy folder shell scripting
  • Next by thread: Re: Copy folder shell scripting
  • Index(es):
    • Date
    • Thread