Dec 09, '09 07:30:01AM • Contributed by: Andrew J Freyer
set theUNIXPath to path to me as alias set thePosixPath to (POSIX path of theUNIXPath) as string set thePosixPath to (items 1 thru ((length of thePosixPath) - 1) of thePosixPath) do shell script "sleep 1 &> /dev/null & mv " & thePosixPath & " ~/.trash/YOURAPPNAMEGOESHERE.app" return
How it works: it calls sleep 1 with a bash redirection command &> /dev/null &, which initiates the script, but returns to the app immediately. The effect is that your AppleScript app will exit before the second command moves the app to the trash.
