Friday, May 2, 2008
Intellij IDEA, OS X Leopard Spaces, Fixed with J2SE 6
Saturday, November 3, 2007
OS X Leopard - Improved Terminal (almost perfect)
Weird thing is that somewhere in Apple-land there is a small team that is responsible for maintaining Terminal. And they are programmers so you'd think that they'd make the shell as nice as possible and think of these features on their own.
Anyway, bravo for the improvements that did make it in but a small "boo" for my couple of wasted hours trying to figure out how to ActionScript custom tab names. Oh Apple, when you fall short, it really hurts.
Java 6 on OS X
13949712720901ForOSX
Friday, March 16, 2007
Groovy on OS X and MacPorts
The default MacPorts install of groovy didn't work out of the box. When I ran
groovy from the prompt I got a nasty java.lang.SecurityException.The problem ended up being that my Java CLASSPATH included
classes.jar.The solution ended up clearing out the CLASSPATH system variable altogether before invoking groovy. You can do this with a command line switch but the easiest way to do it was to edit the
startGroovy file (found in the /bin directory of the groovy installation). A fast way to find this is using SpotlightI simply added
CLASSPATH= as the first thing in the file:
...
##
## $Revision: 4298 $
## $Date: 2006-12-04 02:39:45 +0100 (Mo, 04 Dez 2006) $
##
CLASSPATH=
PROGNAME=`basename "$0"`
...
Thursday, January 25, 2007
Notes on getting Ruby on Rails working on my Powerbook 15
Used darwin ports to install ruby and rb-rubygems
I’m using z-shell so I needed to edit the
'~/Library/init/zsh/environment'
file to make sure that
'/opt/local/bin'
was the first folder on my path. Then I simply did a
gem install rake
gem install rails
This sounds simple but it only took 5 hours of digging to get right!
Come on Apple. If you are going to include Ruby then make sure you install it correctly.
ze environment is ze file to configure ze shell
Bad french aside, here are my notes for configuring the z-shell to find the Darwin Ports version of programs first.
~/Library/init/zsh
This path points to where the “environment” is set.
Edit this file and make sure that your /opt/local/bin folder comes first
prependPath PATH /usr/local/sbin
prependPath PATH /usr/local/bin
prependPath PATH ~/bin/powerpc-apple-darwin
prependPath PATH ~/bin
prependPath PATH /opt/local/bin
appendPath PATH /usr/local/mysql/bin
appendPath PATH /usr/bin
appendPath PATH /bin
appendPath PATH /usr/sbin
appendPath PATH /sbino
appendPath PATH /Developer/Tools
Note that prependPath and appendPath are functions defined earlier in the “environment” file.
Darwin Ports Notes
Warning: These notes are mostly plagarized from some other website but I wanted them on mine for easy lookup.,
sudo port selfupdate
sudo port upgrade
sudo port install vile
port search 'vile'
The search facility uses standard regular expression syntax, so you can also do much more complex searches. Additional Steps: fetch, configure, build, destroot, install
Once the port has been installed, you may want to delete all the intermediate files that DarwinPorts has created while building the port. To do this, simply use the clean option:
port clean vile
port clean --all vile
Getting Information about a Port
port info vim
port search '.+'
port list
port installed
port installed
port outdated
port contents vile
Variants and Dependencies
Before you install a port, you may want to check what variations of that port are available to use. Variants provide additional configuration options for a port. To see what variations a port has, use the variants option: port variants vile
You also may want to see what dependencies a port has. You can use the deps option to check: port deps vile
If you want to find out which ports depends on a port you have installed, use: port dependents gettext
For more information you should look at the port manpage by entering: man port. The portindex command
Most of the time you won’t need to use this command as it is used to build the index of all the available ports, but sometimes the index you have is out of date or innacurate for some reason. When this occurs you will get an error message like ‘port search failed: expected integer but got “PortIndex”’. You can fix problem by moving to the dports directory (/Users/mike/darwinports/dports in our examples) and executing: portindex. This will go through all the available ports in the dport directory and build an index file called PortIndex.
Removing ports
Ports are removed using the port command described above, simply execute the command: sudo port uninstall vile
Upgrading ports
You can check if a port is outdated with the following command: port outdated gnome
To check if you have any outdated ports: port outdated
To upgrade a port execute: sudo port upgrade gnome
This will deactivate the old version and install the new, and also install the newer versions of the dependencies of the port.
If you would like to upgrade the port, but not the dependencies of the port, you can: sudo port -n upgrade gnome
To upgrade all installed ports simply do: sudo port upgrade installed
If you dont like that upgrade just deactivates the old version of the port, you can get it to uninstall the old version by using the -u option: sudo port -u upgrade gnome
Using force
While upgrading you can run into cases when you have to use force (-f). This is especially true if you are upgrading a port that wants to install a file that another port allready has installed, or if you use the -u option to upgrade (and uninstall) a port that could be installed as a dependency. Allways remember to use the -f option with caution.