Skip to content

Instantly share code, notes, and snippets.

View lukeasrodgers's full-sized avatar

Luke Rodgers lukeasrodgers

View GitHub Profile
@lukeasrodgers
lukeasrodgers / mysql_export_import.sh
Last active December 12, 2015 10:18
mysql dumping and importing
mysqldump DB -hHOST > OUTFILE.sql
# copy to local
rsync -avPz --progress USER@HOST:/PATH/TO/OUTFILE.sql .
# import to local db
mysql -uroot -p -DDATABASE < OUTFILE.sql
@lukeasrodgers
lukeasrodgers / DOMSubtreeModified_logger.js
Last active December 12, 2015 10:19
log dom subtree modifications to the console (works in Chrome, not sure of other browsers)
document.body.addEventListener('DOMSubtreeModified', function(e) { console.log(e.target); });
@lukeasrodgers
lukeasrodgers / gnuplot commands
Last active September 27, 2016 08:18
Hacky shell script and gnuplot commands to plot the size of a file across a number of git commits, where the name of the file changes but is pattern-matcheable. y-axis data is unique by date.
set xdata time
set timefmt "%Y%m%d"
set offset graph 0.1, graph 0.1, graph 0.1, graph 0.1
plot "temp.data" using 2:1 with lines