File tree Expand file tree Collapse file tree 4 files changed +6
-5
lines changed Expand file tree Collapse file tree 4 files changed +6
-5
lines changed Original file line number Diff line number Diff line change 3131
3232URL=$1
3333
34- function error {
34+ error () {
3535 echo $*
3636 exit 1
3737}
3838
39- if [[ ! $URL ] ]; then
39+ if [ ! $URL ]; then
4040 error $0 URL
4141fi
4242
Original file line number Diff line number Diff line change 1212fi
1313
1414commit=` for i in $all ; do
15- echo -n " $i "
15+ printf ' %s\n ' " $i "
1616 # why is there no git diff --shortnumstat ?
1717 git diff -M $spec $i | wc -l
1818done | sort -k 2 -n | head -n 1 | cut -f 1 -d ' ' `
1919if [ " $mode " = diff ]; then
2020 git log --no-walk $commit | cat -
2121 git diff -M $spec $commit | cat -
2222else
23- echo -n " $commit : "
23+ printf ' %s\n ' " $commit : "
2424 git diff -M $spec $commit | wc -l
2525fi
Original file line number Diff line number Diff line change 77for ref in " $@ " ; do
88 for sha1 in $( git rev-list " $@ " )
99 do
10+ :
1011 done
1112done
Original file line number Diff line number Diff line change 1515
1616MODIFIED=$( git status | grep modified | cut -d " " -f 3-)
1717
18- if [ " x $MODIFIED " == x ]; then
18+ if [ -n " $MODIFIED " ]; then
1919 echo no changes
2020else
2121 git add -f $MODIFIED \
You can’t perform that action at this time.
0 commit comments