Starting Eclipse from the OS X Terminal

Technical

The other night I had a need to restart Eclipse with the -clean flag. No big deal, I've done this a thousand times. Except - and didn't you just know there'd be one of those?...I've never done it on OS X (have I mentioned that I'm a new Mac user?). Hmmm.

OS X stores applications as bundles. Eclipse.app is essentially a single bundled file (think zip, jar, tar, xpi, etc.) that contains all of the Eclipse goodness you'd expect to find in the c:\eclipse\ (replace with your path, as required) directory of a Windows machine. I had no idea how to start the actual executable from the command line.

Google is your friend.

Sage advice. After a bit of digging, I found out that in the /Applications/eclipse/ folder (again, insert the path of your choice) is an alias (think symbolic link or shorcut) to the Eclipse executable within the bundle that accepts all of the same arguments. Fired off

$ /Applications/eclipse/eclipse -clean

And my environment loaded happily. And cleanly, I presume.


Search

Rob  Wilkerson