Re: linebreak in a shell script; was Re: What's wrong with this call to zip?
Re: linebreak in a shell script; was Re: What's wrong with this call to zip?
- Subject: Re: linebreak in a shell script; was Re: What's wrong with this call to zip?
- From: Dmitry Markman <email@hidden>
- Date: Wed, 27 Feb 2008 20:54:58 -0500
AFAIK
by default do shell converts unix style eoln (0x0A) to mac style (0x0D)
linefeed constant is 10 not (13)
so I'd use something like that
set eoln to ASCII character 13
if you want you do shell to return unix style eoln (e.g. linefeed)
set altering line endings parameter to false
do shell script commandString ¬
[ as returnValueClass ] ¬
[ administrator privileges Boolean ] ¬
[ password passwordString ] ¬
[ altering line endings Boolean ]
On Feb 27, 2008, at 7:05 PM, tom wible wrote:
do shell script "cd ~/Desktop" & return &" zip -r test.rtfd.zip
test.rtfd"
> which failed
return is not newline
do shell script "cd ~/Desktop
zip -r test.rtfd.zip test.rtfd"
and it worked
i understand leopard has a newline already defined...i use this on
tiger:
property newline : "
"
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (applescript-
email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden
Dmitry Markman
_______________________________________________
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