Skip to content

Instantly share code, notes, and snippets.

View andy-cline's full-sized avatar

Andy Cline andy-cline

View GitHub Profile
@andy-cline
andy-cline / update_svn_author.sh
Created June 13, 2011 21:08
Change the author on a local Subversion repository.
#!/bin/sh
AUTHOR=$1
FIRSTREV=$2
LASTREV=$3
for (( i = $FIRSTREV ; i <= $LASTREV; i++ ))
do
svn propset --revprop -r $i svn:author $AUTHOR
done
@andy-cline
andy-cline / upgrade_svn_library.sh
Created June 14, 2011 22:32
Update/Upgrade a Subversion library to a new version in a nested directory structure.
rsync -r -t -v --exclude=.svn /Users/me/Downloads/ckeditor/ /Users/me/Sites/site_name/working/httpdocs/js/ckeditor/
@andy-cline
andy-cline / gist:6780cc0ea4afffca4b79f6856e60e0f5
Created October 23, 2016 13:20
Generate random seating assignments for a multi-session meeting.
$personTableAssignments = generateTableAssignments(8, 8);
foreach ($personTableAssignments as $personTableAssignment) {
echo (implode(', ', $personTableAssignment) . '<br />');
}
function generateTableAssignments($numSessions, $numTables)
{
$numPeople = $numSessions * $numTables;