diff --git a/sendGFWList.sh b/sendGFWList.sh index f44e611..b491676 100755 --- a/sendGFWList.sh +++ b/sendGFWList.sh @@ -2,14 +2,14 @@ # # A simple script help to maintain AutoProxy gfwList easily. # -# Function: +# Features: # Update local svn repository; # Commit decoded changes(by others in your team) to local git repository # with decoded message and authors name; -# Update "Last Modified" time; -# Update "Checksum"; +# Update "Last Modified" & "Checksum"; # Commit your changes to local git repository; -# Commit your encoded changes to remote svn server with encoded log. +# Commit your encoded changes to remote svn server with encoded log; +# Plus some error handling. # Usage: # Initialize: # $svn checkout https://autoproxy-gfwlist.googlecode.com/svn/trunk/ gfwList --username your-google-user-name @@ -40,7 +40,7 @@ done # get formated author and log information log=$(svn log --xml -r BASE:HEAD) || exit 1; -log=$(echo $log | awk -v RS='' -F '|' '{ for(i=6;i|' '{ for(i=6;i gfwlist.txt && # may be failed because of connection/authentication problems - svn ci gfwlist.txt -m $( echo "$*" | openssl base64 | tr -d '\n') || + svn ci gfwlist.txt -m $( echo "$*" | openssl base64 | tr -d '\r\n' ) || # "svn ci" and "git commit" are atomic operations git reset HEAD^ 1> /dev/null;