Finder freezes during a do shell script
Finder freezes during a do shell script
- Subject: Finder freezes during a do shell script
- From: Richard Covert <email@hidden>
- Date: Sun, 25 Apr 2004 20:26:47 -0500
This is part of my Applescript . it is surreounded by an earlier tell
app "Finder"
anyway, I have folder with a bunch of files that I want to add RAR
files to. I use the UNIX command 'rar' to build the rar files. If I
issue the command
rar a -s -v10M -vn $1 *.mp3
from a Terminal window, it takes severals minutes to finish. The rar
command produces a line of output with an incrementing percentage
display.
If I build a shell command string as below, I can execute the command.
But, the Finder freezes until the 'rar' command completes. I also get
an AppleEvent timeout alert in my desktop..
Other Mac OS X apps (such as the Script Editor) still respond. But, I
can not switch back to the Finder and I can not do a Force Quit' to
kill the 'rar' app early.
Other do shell script commands execute as expected and do not appear to
freeze the Finder. The rar command, when executed from a bash shell in
a Terminal window does not freeze the Finder. The Finder freezes only
when I do a 'do shell script' from my Applescript file while running
AppleScript.
My environment is a Pismo G3/500 Powerbook, Mac OS X 10.3.4, etc.
Basically, I build a shell command to cd to the directoy containing the
files to be 'RAR'ed, then perform a RAR command on a file in that
directory. Seems simple enouhg in theory but it freezes the Finder in
application.
RATS!!!
set shell_cmd to "cd " & POSIX_Path & ,
";/usr/local/bin/catsegs.sh " & BaseHostName
display dialog "shell_cmd is " & shell_cmd
do shell script shell_cmd
*)
(* now do the rar command such as
rar a -s -v10M -vn $1 *.mp3
*)
set shell_cmd to "cd " & POSIX_Path & ,
"; /usr/local/bin/rarMP3 " & BaseHostName & ,
" SeanHannity_0423_CommericalFree.mp3 2>&1"
display dialog "shell_cmd is " & shell_cmd
do shell script shell_cmd
_______________________________________________
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.