When running unit tests, xdebug will slow things down quite a bit. Most of the time we run tests we don’t need xdebug because we are not doing code coverage, or actually debugging. Here is how I quickly toggle xdebug
Setting fully qualified domain name for Apache server
Edit /etc/apache2/httpd.conf Search, using ctrl-w, for ServerName Uncomment this line: #ServerName www.example.com:80 and then change the last part to “localhost” ServerName localhost
Stopped jobs in linux
When using CTRL-Z to “exit” a program, you really are not exiting it. You are suspending it. (Multitasking, remember?) To see the list of stopped jobs, type jobs To bring the last stopped job up again, and resume its execution, type fg
Proper way to set file permissions
For each parent directory leading to your web root (e.g. ~/my, ~/my/web, ~/my/web/root): chmod go-rwx DIR (nobody other than owner can access content) chmod go+x DIR (to allow “users” including _www to “enter” the dir) sudo chgrp -R _www ~/my/web/root (all web content is now group
Adding vhosts in Apache
On a native install on Mac, to add a vhost: If you haven’t done this one time step, do this first to enable vhosts: sudo nano /etc/apache2/httpd.conf Then uncomment the line that includes the vhost config file: # Virtual hosts
Restarting Apache on Mac OS X
The command to restart apache on Mac OS X is: sudo apachectl -k restart