svndiff 0.2

託 A 同事的福,找到了前一版 svndiff 潛在的問題-不加參數時,zenity 顯示出來的檔案比預定的要少。原因是餵給 zenity 的資料錯誤,應該要在實際的資料前多加一行空白,所以我在 awk 裡改用 printf 來輸出。
[bash]
#!/bin/sh
if [ -z $1 ]; then
FILES=`svn status | awk ‘/^[MCA]/{printf “\n%s\n”,$2;}’ | zenity –list –width=600 –height=400 –separator=\ –checklist –title “The files which modified/conflict” –text ‘Please select files’ –column ” –column ‘Files’`
else
FILES=$@
fi
for FILE in $FILES; do
svn diff –diff-cmd /usr/bin/meld $FILE
done
exit 0
[/bash]