personal weblog of a tech addict
Posts tagged Mac
GitX: A git GUI for OSX
Dec 4th
GitX is a git GUI made for OSX. It was created by Pieter de Bie and is a really solid tool for working with git on OSX. I’ve been using it for about 9 months now. I liked it so much when I first began using it that I immediately added the ability to perform remote pushes to Unfuddle.
I was pushing some commits earlier this morning and realized that I never made the changes to GitX public. It was always my goal to share the updates with the community but I always kept getting sidetracked. Well, today I forked the master project and even added GitHub integration.
You’ll need the latest version of Xcode to compile from source. If you just want access to the customized application, you can download a ZIP of the forked project and you’ll find the application in /path/to/download/build/Debug/GitX.app. Hope others find this as useful as I have…

Overlaying the Flex SDK with the AIR 2.0 SDK on OSX
Dec 4th
Since I develop with multiple IDEs, I maintain the latest releases of the Flex and AIR SDKs in a centralized location outside of their default install locations. This made enabling the AIR 2.0 SDK simple for me as all I had to do was the following:
1. Duplicate my Flex 3 SDK path
2. Rename the duplicate to flex_sdk_3.x_air_sdk_2.x
3. Download the latest AIR 2.0 SDK (currently AIR20_mac_sdk_120209.tbz2)
4. Place the AIR SDK zip in the root of the new Flex SDK directory
/flex_sdk_3.x_air_sdk_2.x/AIR20_mac_sdk_120209.tbz2
5. Open up Terminal in the new Flex SDK directory and execute the following command:
tar -xjf AIR20_mac_sdk_120209.tbz2
6. Open Flex Builder and add the new SDK -> Flex Builder > Preferences > Installed Flex SDKs > Add
Now, when I want to create an AIR app that targets the 2.0 SDK all I have to do is
1. Update the project compiler settings to use the new SDK -> Project > Properties > Flex Compiler > Use a Specific SDK
2. Update the application descriptor file to use the AIR 2.0 namespace
<application xmlns="http://ns.adobe.com/air/application/2.0beta">
All of the above steps can be repeated for the Flex 4 SDK as well.
For those interested, these are the items that were updated and added to the SDK for 2.0:
/bin/adl
/bin/adt
/frameworks/libs/air
/frameworks/projects/air
/lib/nai
/lib/adt.jar
/runtimes/air
/samples
/templates/air
/AIR SDK Readme.txt
/SDK license.pdf
CAVEATS:
- There’s a new certificate process started in AIR 1.5.3 that may disrupt your workflow if you’re creating signed applications.
- If you want to utilize the new native process features, you’ll have to implement multi-platform builds (native installers for Win, Mac and Linux) and these must occur on the target platform (ie, can only create DMGs on Mac, etc)
Working with MySQL Doesn’t Have to Suck
Nov 25th
That’s the tag line for Querious, an awesome MySQL database management tool from Araelium Group. It’s like MySQL Administrator combined with Sequel Pro.
Prior to Querious, I would have to use both of those other apps plus some CLI to manage all the data systems I’m responsible for. Now, with Querious I can use one GUI and resort to the CLI only when absolutely necessary. It has a lightweight feel like Sequel Pro plus you get the full administrative capabilities of MySQL Administrator + phpMyAdmin. If you have to import a massive SQL dump, either split it up or prepare for the app to crash (unless you modify max_allowed_packet).
All in all, Querious is a must-have for MySQL DBAs that work exclusively on a Mac and is definitely worth the $25 price tag…
Installing New Snow Leopard Server
Nov 21st
During a super busy week this week the main server on the internal network died. This was bad, really bad. As the Open Directory Master, this machine was responsible for everyone being able to enjoy a smooth workflow. Promoting another server to OD Master just wasn’t an option as there were other critical services running on the now deceased machine. No, for this catastrophe we had to invest in something that we could expect to be more reliable under the constant strain.
Pre-Installation
Surprisingly, the New Mac Mini Server from Apple couldn’t have been released at a better time. With a little under 12 hours until the next day of business, we would have to acquire a server, setup and restore the system data from our latest backup. Based on those requirements, I knew that only one box could rise to the occasion.
So, after receiving purchase approval, I made my way to the nearest Apple Store to snag one of those precious jewels. I knew things would work out too when I made it to Santa Monica and lucked up on a parking space about 40 feet from the Apple Store entrance.
Once in the store, I didn’t waste anytime. I needed to get my server and split. Of course I ended up browsing and didn’t leave until about 20 minutes later. But, I had our new server in hand ready to be welcomed into the fold.
Once I made it back to the office around 9pm, I had to prepare the rack for a new family member. Finally, we could have all of our servers consolidated in 1 area instead of scattered around thanks to the form factor of the Mac Mini. It really takes up very minimal real estate and makes me wonder if I’ll ever deploy Xserve now that the Mini is a viable option. The cost-to-value ratio here is excellent. I mean you get a terabyte server with 4GB of RAM and an unlimited client license to Snow Leopard Server for around $1200 (including Apple Care). To do the same with a new Xserve could easily set you back $3000+. It might not work for a video shop but at these prices it’s a no brainer for powering an expanding network.
Anyways, it’s now time to put this puppy into action. So I roll up my sleeves and get to crackin’.
The Arrival
The box that it comes in adds an additional 1/3 to the dimensions. So you know the footprint on this bad boy is going to be small.
Installation Preparation
After inspecting the package contents, it was time to get to work. About 9 hours later, the new machine was installed into its new home ready to provide core and directory services to the team with overall workflow only slightly bruised…:D
Home, Sweet Home!
The application Finder cannot be opened -10810
Oct 14th
If you have experienced this issue since upgrading your Mac to OSX 10.6, here’s the skinny on what’s going on and what you can do about it. Basically, this occurs when attempting to access external drives (ie, USB, Firewire, iDisk, etc). Symptoms of this error include a missing menubar (unless an application is active and in focus) and no “active” indicator beneath Finder in the Dock. This particular error can prove to be extremely annoying since the majority of Mac GUI applications incorporate the Finder in the UX (ie, Open and Save dialogs). Luckily, it’s not difficult to recover from, just depends on how you’d like to.
If you have running processes that you don’t want to stop by rebooting your machine, open Terminal and issue this command:
killall Finder
press the Return key and Finder will be relaunched for you without a computer restart. If you don’t mind rebooting, I’d suggest issuing the restart command from Terminal vs. using the Apple menu as the latter is prone to be blocked by the current issue. To restart from Terminal, issue the following command:
sudo shutdown -r now
You can replace the -r flag with -h to shutdown instead of reboot. Once restarted, your computer should be back to normal. There are also other options ranging from unmounting the disks, rebuild LaunchServices, applying/reapplying the 10.6.1 combo update and ultimately reinstalling the OS but I believe these two to be the fastest to getting your machine back up and running…:D
Transmit and Amazon S3
Jul 19th
Just discovered that Transmit 3.7 has S3 support. You can manage it using the Advanced Preferences tab which you access by holding down the Option key while clicking on the Transmit application menu. From there you will see an extra preference tab where you can manage server connections and S3 settings. Now if they only added a tab for managing public keys for SCP/SFTP. For this you have to make sure your key is available @ ~/.ssh
TextMate + Flex SDK + Ant
Mar 19th
This is a pretty sweet combination. TextMate has been my favorite text editor on the Mac for a while although I must confess that I hadn’t been taking advantage of all it’s features. Through “bundles”, you can transform TextMate from an ordinary editor into a complete development environment.
Case in point, I recently discovered the stock Subversion bundle and checked out the Ant, AS3 and Flex bundles and now have a viable alternative to Eclipse + Subclipse + FB plugin for those days when Eclipse feels too sluggish.
To add the extra bundles, create a path for them, switch to that new directory then do a SVN checkout:
$ cd /Library/Application\ Suppport $ mkdir TextMate $ cd TextMate $ mkdir Bundles $ cd Bundles $ svn co http://macromates.com/svn/Bundles/trunk/Review/Bundles/#bundleName#.tmbundle
Where #bundleName# is the one you want to check out. If you don’t specify a bundle, you’ll check out the whole lot. Also, as an alternative, you can grab the Open Terminal script which lets you open a terminal from Finder after you’ve created the paths the GUI way. In that case, you just have to run the checkout command.
Happy coding!!
Leopard 1st Thoughts
Oct 30th
I installed 10.5 last night when I got in and so far so good. The upgrade process took, maybe, an hour and after that I started thinking of what new feature I wanted to use 1st. The winner was Spaces. This feature lets you split up your screen real estate by saying, “only open these apps in this space”. I set up spaces for dev, design and everything else. The goal is to reduce the clutter and keep your machine visually beautiful.
With that in mind, my next stop was Stacks. These are folders that you add to your dock that can help you keep your dock lean and mean. Case in point, before today I had like 30 apps on my dock – 98% of which I use on a daily basis. Thanks to Stacks I organized those into these main categories:
- Comm (Mail, Chat, Address Book, etc)
- Des (Fireworks, Photoshop, Illustrator, etc)
- Dev (Flex Builder, Eclipse, Zend Studio, Terminal, etc)
- Tools (Time Machine, Transmit, xScope, etc)
These were in addition to Documents and Downloads, which Apple sets up for you on install. So now my dock is only 8 deep and I feel pretty proud of that (plus it’s cool watching the apps fan out when you click on a Stack). Outside of those, I’ve been hitting Quick Look pretty hard. This let’s you look @ the contents of a file without actually opening the file which is really cool for me since I juggle a lot of files throughout the day.
Last, but not least, Time Machine is pure butter!! Easy, painless backups period. I really could have used this last week as an iPhone sync killed my Address Book. Glad I had a spare thanks to iBackup. Anyways, let me know of any cool ways you use the new OS plus any headaches and I’ll do the same…
The Way It Should Be
Aug 7th
This morning, before work, I remembered that I needed desparately to upgrade the RAM on my MacBook. 1GB just wasn’t going to cut it anymore. Only problem was I didn’t have any spare cash to pick up a couple of memory sticks right now.
No problema. I just swapped out with my iMac which is seeing limited use right now and viola! The whole process took, maybe, 10 minutes and yielded me a pretty productive day (I don’t know why that extra 1GB motivated me so much).
Flex :: Compiling on Mac OSX Panther
Jul 27th
Want to save other developers the headaches of setting up a workflow on OSX. A lot of stuff that’s out is either outdated (alpha release) or only works with Tiger. This series of tidbits is for the Panther faithful (whatever our reasons). So, first we’ll look @ command-line compiling specific to Beta 3 and Final.
OK, on my Mac I’ve got the SDK installed @ /Developer/SDKs/Flex/. And, I compose my MXML @ /hasan/fp/flex/. So, this would be the command to take an MXML file and compile it to a SWF:
java -jar /Developer/SDKs/Flex/lib/mxmlc.jar -load-config /Developer/SDKs/Flex/frameworks/flex-config.xml /hasan/fp/flex/helloworld/helloworld.mxml
Man, that was long-winded. And, it’s a pain to have to retype on every compile. Well, thanks to some inspiration I got from Mike Chambers post on the subject, I came up with the following bash script that minimizes the fuss and works with the latest incarnation of Flex 2. I suggest using pico to create this script and save it as mxmlc.
#!/bin/bash flex='/Developer/SDKs/Flex/' compiler=${flex}'lib/mxmlc.jar' config=${flex}'frameworks/flex-config.xml' classpath='' if [ -n "$ASCLASSPATH" ]; then classpath="-source-path `echo $ASCLASSPATH | sed 's/:/ /'`" fi echo $classpath java -jar $compiler -load-config $config $classpath -incremental=true $@
Basically, this bash script will take our pre-defined variables (flex, compiler, config, classpath) and build our compile command using them and the filename that we’ll pass in from the terminal ($@) then execute the command’s instructions for us. One last thing before we can put this script to use. We have to edit file permissions on it. From the terminal just say:
chmod 755 mxmlc
Then you’ll be able to command-line compile by simply saying:
mxmlc helloworld.mxml
The only part that should be confusing @ first is the conditional statement but, all that says is that if the environmental variable ASCLASSPATH has a non-zero length, set our classpath variable equal to ASCLASSPATH.
So, there you have it. Cool, clean command-line compiling. Next, I’ll post some tips for compiling from Eclipse.

