This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Dynamically Set Environment Variables | |
$server[] = $_SERVER['HTTP_HOST']; | |
$server[] = $_SERVER['LOCAL_NAME']; | |
$environment->local[] = 'example.dev'; | |
$environment->staging[] = 'staging.example.com'; | |
if ( array_intersect( $environment->local, $server ) ) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ ls -al /tmp/mysql.sock; ls -al /var/mysql/mysql.sock | |
lrwxr-xr-x 1 root wheel 21 Oct 12 13:45 /tmp/mysql.sock -> /var/mysql/mysql.sock | |
srwxrwxrwx 1 _mysql wheel 0 Oct 12 13:51 /var/mysql/mysql.sock | |
ls: /tmp/mysql.sock: No such file or directory | |
srwxrwxrwx 1 _mysql wheel 0 Oct 12 13:51 /var/mysql/mysql.sock |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ xcode-select --install |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd /usr/local/bin | |
sudo curl -Ol https://raw.github.com/major/MySQLTuner-perl/master/mysqltuner.pl | |
sudo chmod 755 mysqltuner.pl |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Display MySQL Query Count and Page Generation Time for Performance Profiling | |
* ------------------------------------------------------------------------------ | |
*/ | |
if ( ! function_exists( 'show_page_generation_stats' ) ) { | |
function show_page_generation_stats() { | |
if ( WP_DEBUG === true && current_user_can('administrator') ) { | |
global $wpdb; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo php /usr/lib/php/install-pear-nozlib.phar | |
pear config-set php_ini /private/etc/php.ini | |
pecl config-set php_ini /private/etc/php.ini | |
sudo pear upgrade-all | |
sudo pecl install apc | |
sudo pecl install xdebug | |
# Install ApiGen | |
sudo pear install pear.apigen.org/apigen |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Download PHP 5.3.15 Source | |
cd /usr/local/src | |
curl -L -O http://us.php.net/get/php-5.3.15.tar.gz/from/us1.php.net/mirror | |
tar -xzvf php-5.3.15.tar.gz | |
# Download libmcrypt | |
cd /usr/local/src | |
curl -O http://iweb.dl.sourceforge.net/project/mcrypt/Libmcrypt/2.5.8/libmcrypt-2.5.8.tar.gz | |
tar -xzvf libmcrypt-2.5.8.tar.gz | |
cd libmcrypt-2.5.8 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd /usr/local/src | |
curl -O http://lynx.isc.org/lynx2.8.7/lynx2.8.7.tar.gz | |
tar -xzvf lynx2.8.7.tar.gz | |
cd lynx2-8-7 | |
./configure --mandir=/usr/share/man | |
make | |
sudo make install |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd /usr/local/src | |
curl -O http://ftp.gnu.org/gnu/wget/wget-1.14.tar.gz | |
tar -xzvf wget-1.14.tar.gz | |
cd wget-1.14 | |
./configure --with-ssl=openssl | |
make | |
sudo make install |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Compile PCRE - Perl Compatible Regular Expressions | |
cd /usr/local/src | |
curl -O ftp://ftp.csx.cam.ac.uk//pub/software/programming/pcre/pcre-8.31.tar.gz | |
tar -xvzf pcre-8.31.tar.gz | |
cd pcre-8.31 | |
./configure | |
make | |
sudo make install | |
# Compile Autoconf |