Applescripts
Here are some Applescripts that I thought I could show off. Feel free to use and modify them as you please. If you'd like to contribute your improvements — great! Just drop me a line.
Skype users, you are probably looking for Peek-O-Matic.
Make Nifty Box Note
- Make Nifty Box Note is an Applescript that inserts a note into the tagging application Nifty Box, a feature I really needed Nifty Box to support.
- This Script is best used with Quicksilver: Enter a string for a note title in Quicksilver, Tab, process string with..., Tab, Make Nifty Box Note.
- What the script really does is create an RTF file in the Folder ~/Library/Application Support/Nifty Box and insert that file into your Nifty Box.
Download Make Nifty Box Note
Launch as User
- Launch as User is an Applescript droplet that launches applications as another user and was inspired by this hint on MacOSXHints.com.
- Why would anyone want to do that? For example if you want to access your "normal" user's Mail or iCal from the administrator account you're currently working in.
- Launch the script to set the target user. Then, drag the application to launch onto Launch as User. You will be prompted for the target user's password and the application will be launched (this script is essentially a wrapper for su).
Download Launch as User
Version 1.1 of Launch as User also works with Mac OS X Leopard and doesn't require the admin password, only the target user's password. My thanks go – again – to Ben for reporting the Leopard incompatibility.
Peek-O-Matic
A note to Skype users: If you experience problems with sound input or output, try logging out the background user before launching Skype through Peek-O-Matic. Thanks, Michael, for reporting this problem and its fix.
- Peek-O-Matic is very similar to Launch as User in that it allows you to run an application as another user. The only difference is that you bind an app permanently to the script by drag-and-drop. It then asks for a user name and remembers that, too. Henceforth, launching Peek-O-Matic launches above app as above user. Re-configure it by dropping a different app.
- Apart from its use, it's just like Launch as User above.
- I found that a significant number of users are using Launch as User to run two instances of an application at the same time, e.g. Skype.
Download Peek-O-Matic
Version 0.4 of Launch as User also works with Mac OS X Leopard and doesn't require the admin password, only the target user's password. Many thanks to Ben for reporting the Leopard incompatibility.
I'm trying to come up with a better name for this script. All suggestions are welcome.
Process with…
- Process with… is an Applescript droplet that allows you to feed files to a shell command by drag & drop.
- On its first launch, Process with… asks for a shell command (can be a binary or a script or anything) and remembers it. You can then drag one or more files or folders onto the Process with… icon and Process with… will call the remembered shell command with those files as parameters.
For example, when in a text editor, save your document, then drag the icon from your editor's window title bar onto Process with….
- Process with… does not yet support command line switches, but please feel free to modify the script to fit your requirements. If you think your enhancements should be included, contact me.
Download Process with…
QuickMount
- There are people who think that the checksum verification of DMG disk images is nothing but a waste of time. If you're one of those poor deluded souls, QuickMount is for you.
- QuickMount is an Applescript droplet (a mere shell wrapper to be precise) that mounts one or more disk images with the -noverify switch. Drag one or more disk images on the QuickMount icon and QuickMount will mount them, skipping the checksum verification.
- The nifty thing is: QuickMount will remember what disk images you mounted with it last time. So if you just double-click on QuickMount the next time, the last-mounted disk images will be mounted automagically.
Useful e.g. for your Startup Items
- If you're like me and actually want checksum verification, edit the QuickMount script and scrap the -noverify in the line starting with do shell script.
Download QuickMount (In German, but I'm sure you'll handle)