Marius van Witzenburg We fight for our survival, we fight!

26Jul/100

How to upgrade CakePHP or any other package that is under subversion control with Rsync

Posted by mariusvw

Actually this is more simple than you might think.

First you checkout your current version. Then download and un-tar the new version and simply run the following command on your shell/terminal:

rsync -av --exclude '.svn' --exclude '._*' my/new/cakephp-cakephp-efb6e08/ my-old-cakephp/

This will exclude your Subversion .svn directories and it will also exclude the META-data files created by Mac OS X.

Good luck with upgrading! :-)

23Jul/105

iMac or Macbook (Pro), Self Assigned IP Address problem with Wifi Airport connections

Posted by mariusvw

I was having an issue with my Macbook Pro lately that the DHCP client couldn't get an IP from the DHCP server. This happened on different networks and it didn't happened every time. The message in the network settings was: "Self Assigned IP Address". After a while I really wanted to have a solution for this so I started spitting in the logs first...

I ended with no result at all, but suddenly I remembered that other programs might behave weird when their preference files are corrupted or if there are mistakes in them.

Then I found the following file:

/Library/Preferences/SystemConfiguration/com.apple.airport.preferences.plist

I first turned off my airport before doing any action to this file.

I opened the file to sniff around and there it was, a missing close tag in the XML. I first fixed this, without no result as expected. Then I moved the file to my desktop, compressed it, trashed the original file and cleared my trash. Then I turned back on the Airport and clicked my network... It connected, since then my wireless problems are solved :-)

The error you see in the network preferences reads as follows: AirPort has the self-assigned IP address 169.254.67.44 and will not be able to connect to the internet.. But I'm sure you will notice that as soon you have this problem ;-)

13Jul/101

Update Mac OS X Finder Workflows to Services, rename files to lowercase

Posted by mariusvw

As some of you might have noticed, the folder actions submenu where you could add your own workflows isn't there anymore in Mac OS X 10.6 (Snow Leopard).
Apple decided to move this to the service menu instead, which is in my opinion a good step since you can now add a service action to almost every program on your Mac.

On my Mac I had a workflow to easily rename all selected files form a UpPeRcaseD name to a lowercase name.
The first thing I noticed when I needed this workflow that it wasn't there... So I looked around a bit and when opening the workflow in Automator it gave an error that it was an old workflow that needs to be updated to a new version.

Since the workflow is quite simple I decided to make a new one. While doing this I found the service option.
Fist I thought I didn't need that but after about 2 minutes I noticed that it was the new way of adding your workflows to Finder or other applications.

Well, lets get started... Fire up Automator!

Create a new service

Search for Finder and drag "Get Selected Finder Items" to the right

You might get this warning, simply click Don't Add

Search for "Rename" and drag "Rename Finder items" to the right

In the above image you can also see the right settings. Change case of the Full name to lowercase.

Save the service

You will end up with this screen, quit Automator

Now your ready to test your service.
Goto a folder where you want to lowercase your files and select the items you want to rename to lowercase. Goto the "Finder" menu and click your newly created service.

Good luck :-)

4Jul/100

How to determine the partition sizes of your disk for FreeBSD usage

Posted by mariusvw

Partition sizes

First of all, what I mostly do. I press A for the default partitions and then raise them. Below are some default sizes who are advised.

partition mountpoint size SoftUpdates my size
a / 1GB N 1GB
b SWAP 2-3x RAM size - 2x RAM size
d /var 512MB to 4096MB Y 5GB
e /tmp 1GB Y 1GB
f /usr Rest of disk (at least 8GB) Y Rest

For the root partition it might be smart to keep track of how large the kernel is.

This size was a default of 512MB but this is too small to install 2 kernels (kernel and kernel.old).

Another thing is the /tmp partition, this defaults to 512MB, raise it to 1GB (for tar / gzip etc)

Geëtiketeerd als: , , , , , Geen reacties