• 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
do shell script bug
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

do shell script bug


  • Subject: do shell script bug
  • From: email@hidden
  • Date: Fri, 9 Aug 2002 16:11:33 -0700

open text edit. hold down control and option and hit a few keys. Some
random characters and a lot of random whitespace will appear. Save the file
as Unicode 16.

Run this script:
do shell script "cat /path/to/file"

You get the error:
Can't make some data into the expected type.

I'm guessing that this is because do shell script returns "plain text" and
not "Unicode text", and is therefore confused by anything outside of a
certain limited character set. But the fact that it doesn't just strip them
and provide a way around it is rather annoying.

Now, I'll have to redirect the output to a file, read the file, then use
THAT data. Ug.

Unless someone knows how to get around this (like setting the term's
character set?).
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

Seth A. Roby
Scriptwriter Intern
"Life is like an exploded clown. It's really funny until you figure out
what just happened."
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: Eudora Notify
  • Next by Date: Re: Detach and reattach to shell command
  • Previous by thread: Re: Photoshop 6.0.1 and PDF
  • Next by thread: Re: do shell script bug
  • Index(es):
    • Date
    • Thread