Last active
October 30, 2015 14:02
Revisions
-
jcfr revised this gist
Oct 30, 2015 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -12,4 +12,4 @@ echo "" > $logfile echo "$NOW - Updating [$giturl] using [$svnurl]" >> $logfile echo "HOME: $HOME - USER: $USER - LOGNAME:$LOGNAME - SSH_AGENT_PID:$SSH_AGENT_PID - SSH_AUTH_SOCK:$SSH_AUTH_SOCK" >> $logfile cd $clonedir (/usr/bin/git checkout master && /usr/bin/git reset --hard git-svn && /usr/bin/git svn rebase && /usr/bin/git push $remote master --force) >> $logfile 2>&1 -
jcfr created this gist
Oct 19, 2015 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,15 @@ #! /bin/sh remote=origin logfile=/Volumes/Dashboards/SVN2Github/Slicer-SVN2GitHub-$remote-lastupdate-log.txt clonedir=/Volumes/Dashboards/SVN2Github/Slicer-SVN2GitHub giturl=git@github-slicerbot:Slicer/Slicer.git svnurl=http://svn.slicer.org/Slicer4/trunk NOW=$(date +'%T %D') echo "" > $logfile echo "$NOW - Updating [$giturl] using [$svnurl]" >> $logfile echo "HOME: $HOME - USER: $USER - LOGNAME:$LOGNAME - SSH_AGENT_PID:$SSH_AGENT_PID - SSH_AUTH_SOCK:$SSH_AUTH_SOCK" >> $logfile cd $clonedir (/usr/bin/git checkout master && /usr/bin/git reset --hard HEAD && /usr/bin/git svn rebase && /usr/bin/git push $remote master --force) >> $logfile 2>&1 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,9 @@ #! /bin/sh # Adapted from http://linuxrhino.blogspot.com/2010/03/follow-up-to-using-passphrase-protected.html # and http://stackoverflow.com/questions/11546765/how-to-get-the-pid-of-a-process-by-giving-the-process-name-in-mac-os-x export SSH_AGENT_PID=`ps -A | grep -m1 ssh-agent | awk '{print $1}'` export SSH_AUTH_SOCK=`find /tmp/ -name 'Listeners' -print 2>/dev/null` cd /Volumes/Dashboards/SVN2Github ./Slicer-SVN2GitHub-slicerbot.sh