appswitch 1.0.1 [16 May 2004] =============== A command-line interface to the Mac OS X process manager. Written by Nicholas Riley . Obtain updates from . WHAT IS IT? ----------- If you use shell scripts to automate Mac OS X applications, you may need to switch between applications. You could use AppleScript via osascript(1), but that would take several seconds for the script to compile and execute - or you could use appswitch, which works almost instantly. Say you're launching an X11 application from Terminal but the X server isn't in front when you need it. Use appswitch to fix the problem. Or, if you'd like a version of the ps(1) utility which understands the concept of OS X applications, appswitch can help. INSTALLATION ------------ The commands below install the 'appswitch' tool in /usr/local/bin, which is in the default path. You should subsequently be able to use 'appswitch' by typing its name. If you wish to install it somewhere else, modify the install line as appropriate. % sudo /usr/bin/install -d /usr/local/bin /usr/local/man/man1 % sudo /usr/bin/install -c build/appswitch /usr/local/bin % sudo /usr/bin/install -c appswitch.1 /usr/local/man/man1 % rehash Uninstallation: % sudo rm -f /usr/local/bin/appswitch /usr/local/man/man1/appswitch.1 COMPILATION ----------- An Xcode project, 'appswitch.xcode', is included. A precompiled binary is also provided. 'appswitch' was developed and tested under Mac OS 10.3.3 with the April 2004 Developer Tools, and does not require any additional software to build. USAGE ----- Just type 'appswitch' by itself to receive usage information. See the manual page (man appswitch) for more information. If you're curious about the speed difference between appswitch and other methods, this should give you some indication. appswitch -a Emacs 0.00s user 0.02s system 55% cpu 0.054 total appswitch -i com.gnu.Emacs 0.00s user 0.04s system 63% cpu 0.063 total open -a Emacs 0.32s user 0.12s system 50% cpu 0.876 total launch -a Emacs 0.00s user 0.03s system 35% cpu 0.085 total osascript -e 'tell application "Emacs" to activate' 0.41s user 0.23s system 67% cpu 0.949 total The above tests were performed on a PowerBook G4/800; slower systems should show more dramatic differences. COMMENTS, SUGGESTIONS, BUG REPORTS, ETC. ---------------------------------------- Please send to the author, Nicholas Riley, at . VERSION HISTORY --------------- 1.0.1 - 16 May 2004 - fixed crash matching applications with no bundle identifier - fixed process listing PSN column width 1.0 - 19 February 2003 - added description of -q delay bug (no workaround) 1.0b3 - 13 February 2003 - display spaces instead of ? characters when unprintable - properly handle very narrow window width with -l - further revised and clarified man page - added -q, -K, -L options 1.0b2 - 11 February 2003 - display ? characters for unprintable creator code characters (e.g. java) - fixed -P/-p error in man page - revised and clarified man page 1.0b1 - 10 February 2003 - added -S, -S, -h, -H, -k, -P, -l, -F options - fixed reference to bogus -u option - fixed bug where unknown match type was silently discarded - added man page and this README 1.0d1 - 4 February 2003 - initial release