OS X / Unix & Server Architecture Matt | 20 May 2008
Recursively Remove Files By Extension
I’m finally getting around to cleaning out dreamweaver LCK files from a large website. We have one developer that uses dreamweaver so these files are useless. So we’ve got these LCK files all over the place in this site. I’m just sick of looking at them.
Enter a shell one liner …
find . -name '*.LCK' -type f -print0 | xargs -0 /bin/rm -f
That command recursively looks in and under the directory I’m in for any files with the LCK extension and removes them.
Here’s a shell script you can save that will prompt you for an extension name to remove.
#!/bin/sh echo "Enter Extension" read filepattern echo "Files matching *.$filepattern will be removed." echo "Is this correct? y|n" read confirmation if [ $confirmation = y ]; then find $PWD -name "*.$filepattern" -type f -print0 | xargs -0 /bin/rm -f else echo "quitting" exit; fi
Or if you don’t want any confirmation of the file extensions you’re about to delete.
#!/bin/sh echo "Enter Extension" read filepattern find $PWD -name "*.$filepattern" -type f -print0 | xargs -0 /bin/rm -f
OS X / Unix Matt | 14 Jan 2008
MacHeist Cheap OS X Software Bundle 2008
MacHeist’s software bundle may or may not live up to all the hype it received over the past few months. Either way, I do feel it’s a good deal on software. Pixelmator is an incredibly cool photo editing application. It’s hand down one of the most beautifully crafted software apps out there both in user interface and stability. The fact that it uses your video card’s ram in order to work with images makes things so incredibly responsive. That app in itself makes the bundle’s price of $49 worth it if you’re specific imagery needs are met by Pixelmator. Unfortunately for some of the more mundane stuff I find myself needing to do with images like prepping for the web are a bit cumbersome in Pixelmator if not impossible in some instances, but as a secondary image app for creativity, it’s really cool. I will also find myself using CSSEdit and Snapz Pro X for work. I do already have Xyle Scope for css but CSEdit may work out a little better. And I do not have an app like Snapz pro. 1Password has been interesting for password management and I may use that permanently for my personal passwords. For work, we’ve been using the website http://www.passpack.com as a shared, web based password management system. That’s really worked out well. But I’ve been finding that for two different sets of passwords, it’s handy to have two totally separate systems. As for the rest of the MacHeist apps, I think it’s mostly fluff but I’m sure there’s some useful stuff to be had.
As of the writing of this post, there’s 9 days left to get the bundle at $49. If you check it out at this link, I’ll get some freebies too
Misc & OS X / Unix Matt | 18 Dec 2007
I would watch Darth Vader make hash browns
Random post based on MacBreak ep. 70.
Thanks to Merlin Mann for the title, this should make it into his mannerisms (pdf). If you’re someone who would watch Darth Vader make hash browns, you’ll love the Star Wars Holiday Special from 1978. Holy smokes. This could very well be the most wonderfully horrible bit of video I’ve seen. Wow. Do a search for Star Wars Holiday Special on You Tube for clips. Or you can find the full special floating around usenet. Or if you’re campically challenged but still want to get in on the fun, check out this version from Rifftrax to have the humor explained for you.
Just ran across this list of OSX menu bar items. Great collection. The menu bar app, Caffeine was pointed out to me. This great little app allows you to disable and enable your energy saver settings with a single click. So basically you can be a good little monkey and use efficient energy saver settings most of the time but then if you need it, click the ZZZ in the menu bar to make sure your computer won’t go to sleep. If you give a presentation or watch a movie with your laptop unplugged, you know the annoyance of your screen shutting off or your screen saver coming on. I’ve enjoyed HimmelBar but don’t see a need for it in leopard with the stacks functionality. If you’re still using Tiger, check it out. iDiskMenu looks very cool as well as a menu app to mount and unmount webdav and ftp network shares. Unfortunately this doesn’t fire up in Leopard but it gets me wanting something to easily manage network shares. Also nfs support is a must for me. I’ll need to figure that out. Seems like a perfect job for the RixStep guys.
ColdFusion & OS X / Unix Matt | 05 Dec 2007
ColdFusion 8 JRun Interface for OS X VMware Fusion
I’ve got CF8 running in single server mode on my MacBook. I also recently installed VMware Fusion for virtual machine support. Running virtual machines creates separate lan networks on your system which can raise some networking issues with things like vpn’s and servers you may run that broadcast to all available ip addresses. JRun for running ColdFusion turned out to be one such problem server.
By default JRun tries to broadcast itself to all available ip addresses. You can verify your setup by checking your jrun.xml file around line 385.
<attribute name="deactivated">false</attribute>
<attribute name="interface">*</attribute>
<attribute name="port">51800</attribute>
That star tells jrun to broadcast itself to all ip addresses hooked up on the machine. I’ve even seen it crash trying to broadcast to a fake ip assigned to the firewire port (think that one’s an Apple bug).
Anyway, there’s really no need for most of us to broadcast to anything but 127.0.0.1, your localhost. So change that star to 127.0.0.1 so that the complete line reads:
<attribute name="interface">127.0.0.1</attribute>
Hopefully this will save you a headache, if not now than in the future if you start adding networks to your machine.
OS X / Unix Matt | 18 Oct 2007
Leopard Time
Been under a rock this week? Just woke up from that month long coma? Don’t go back to sleep just yet, OS X Leopard arrives Oct. 26th.
Mac OS X v10.5 Leopard Family Pack $189 only! Order today for delivery on Oct. 26
OS X / Unix Matt | 26 Jul 2007
Reindex message database for Mail.app
If you’ve got a huge mailbox in Apple’s Mail.app program, this line to be used in Terminal may help. It will rebuild the index used by the sqlite database used by the application. There is no need to run this less than every new hundred megs of mail or so … even that’s overkill. And if you don’t have at least 500 megs, I doubt you’d notice any difference. But if you’re one of those folks that Mail.app is just crawling for, this may be the answer:
sqlite3 ~/Library/Mail/Envelope\ Index vacuum;
OS X / Unix Matt | 13 Jun 2007
Camino 1.5 a fast Mac browser plus full form tabbing
The new version of Camino for OS X came out recently. I’ve been using it for a week and am impressed by the speed, thin RAM usage and relaibility. Plus I just noticed something I’ve sorely missed from Linux.
Linux or Windows users switching to OS X on a Mac will probably notice that when using a web from and the tab key to move from one field to the next, you can’t tab to drop down lists. This drove me nuts for the first few weeks I got serious about using a mac. I ended up just re-learning how I’d fill in forms and begrudgingly put up with the speed bump of having to go to the mouse when I got to a drop down.
Not anymore!
Camino has an option in the web features tab of preferences that allows for tab selection of form buttons, pop-up menus and lists. As well there’s a separate option to turn on selection of links and linked images. This small feature alone makes me switching to Camino full time a compelling choice.

The main drawback to Camino is the lack extensions available for Firefox. This is due to the user interface being written in OS X native Cocoa rather than Firefox’s XUL. The site PimpMyCamino has a few extensions and enhancements available including a link to Camino builds specific to Intel Core Duo and Intel Core2 Duo machines. These versions don’t contain the extra bloat of the code for the PowerPC chips of old.
ColdFusion & OS X / Unix Matt | 08 Jun 2007
ColdFusion 8 about 15 percent faster on OS X
I’ve been exclusively using CF8 for development, leaving testing environments on CF7. In some rough testing, I’m clocking the new engine to be about 15 percent faster. I’m still using JRun4 and Java 1.4.2 on my
. I expect even further speed increases on Linux where I do not need to use such an old version of Java. When I’ve bothered to time the improvements, I’m get roughly 15%, yet it feels like more. Much of what I’m doing recently involves working with Fusebox, which when set in developer mode basically recompiles the whole site at every hit. This can get pretty heavy when testing out new stuff. I made the switch on my dev machine to CF8 about midway through the project and do really notice the improvement. So even with the boring stuff like speed enhancements and stability, CF8 is looking well worth it. I look forward to a public launch soon, problems with RC1 have been minor.
ColdFusion & OS X / Unix Matt | 31 May 2007
OS X Upgrading ColdFusion 7 to ColdFusion 8 with Apache2, Jrun4, MultiServer Config
I like to have ColdFusion running on OSX as it would on my Linux server using mod_jrun thorough Apache2. The CF8 install process wants me to uninstall Jrun4 but I’ll just move things out of the way. As well Jrun still wants to use my default version of Java. Since I don’t want my entire laptop using Java 1.4.2 which is required for Jrun as far as I know, I’ll need to modify the CF8 startup script. As well, I’ll make sure to clean out my old mod_jrun config entries in my apache2 httpd.conf file.
I’ll include a detailed narrative with command line entries and code. If you have any questions, I’ll monitor the comments on this page. I hope your install goes well!
Continue Reading »
OS X / Unix Matt | 30 May 2007
OS X (FreeBSD) command line : the alias
There’s a great little command line utility that I use on my laptop (OS X) whenever I need to burn an ISO disk image to a disk. Last night I grabbed the MythDora ISO to try out on an old box and today I went to burn it. Problem is, I always forget the name of the program that helps me burn. Knowing that when I search for “burn iso osx” in google it’ll come up as the first result does not help me remember.
First off, here’s the osx iso burning trick:
hdiutil burn image.iso
The only thing that I ever change with this command is the name of the disk image. So I should make an alias to this command with something that I’ll remember. To make an alias in OSX or FreeBSD open up your command line preferences file. In OSX my personal command line preferences file is at ~/.profile (that ~ stands for my home directory). So open up a terminal and type:
edit .profile
This should open up your personal .profile file in your favorite editor. Or if you don’t have a .profile file yet, a new one will be made for you. I’ve decided that the alias “burniso” would be much easier to remember than hdiutil. And with an alias, I can also include the “burn” switch that goes along with hdiutil. So, at the end of my .profile, I add:
alias burniso="hdiutil burn"
Now anytime I type the command “burniso”, my computer interprets that as “hdiutil burn”.







