This file contains 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
# For all configuration | |
chrome://about | |
Slow DNS lookups - For some reason site.local is a really slow lookup | |
chrome://net-internals/#dns | |
chrome://net-internals/#events | |
This file contains 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
// Copy big file from somewhere else | |
$src_filepath = 'http://example.com/all_the_things.txt'; $src = fopen($src_filepath, 'r'); | |
$tmp_filepath = '...'; $tmp = fopen($tmp_filepath, 'w'); | |
$buffer_size = 1024; | |
while (!feof($src)) { | |
$buffer = fread($src, $buffer_size); // Read big file/data source/etc. in small chunks | |
fwrite($tmp, $buffer); // Write in small chunks | |
} |
This file contains 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
nano ~/.bash_aliases | |
alias mysql_turn_on_query_logging = "mysql -h localhost -uroot -p -e \"SET GLOBAL log_output = 'FILE'; SET GLOBAL general_log_file='/tmp/mysql_general.log'; SET GLOBAL general_log = 1;\"" | |
alias mysql_turn_off_query_logging = "mysql -h localhost -uroot -p -e \"SET GLOBAL general_log = 0;\"" |
This file contains 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
[Desktop Entry] | |
Version=1.0 | |
Type=Application | |
Terminal=false | |
Icon[en_GB]=bash | |
Name[en_GB]=PhpStorm 9 - EAP | |
Exec=/bin/bash /home/carlton/programs/PhpStorm-141.1224/bin/phpstorm.sh | |
Name=PHPStorm | |
Icon=/home/carlton/programs/webide.png |
This file contains 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
# http://stackoverflow.com/a/5816177/682754 | |
git log -S <whatever> --source --all |
This file contains 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
# Search text strings in all files in a folder | |
grep "test" /var/www/ | |
# Recursively | |
grep -R "test" /var/www/ |
This file contains 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
# Install Java 7 JDK and create an alias if needed | |
alias selenium_start='java -jar ./selenium-server-standalone-2.48.2.jar' | |
# Useful notes "codeception/codeception": "~2.0" | |
The AcceptanceTester parameter passed into the tests is a class that is generated dynamically, if web driver is used as a module then the web driver functions will be available in the auto complete | |
# Running tests in general | |
http://codeception.com/docs/02-GettingStarted#Running-Tests | |
# Running tests for specific environments |
This file contains 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
composer require "foo/bar:1.0.0" |
This file contains 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
# IP address | |
ip.addr == 10.43.54.65 | |
ip.src == 10.43.54.65 or ip.dst == 10.43.54.65 |
This file contains 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
find /tmp/brightcove-cache/ -type f | wc -l |