(BSD compat) apparently 'wc -l' on BSD adds spaces in front

Larry was right.  It's probably easier to port a shell than a shell
script!
This commit is contained in:
Sitaram Chamarty 2012-05-27 05:56:55 +05:30
parent 8595303c82
commit d623388c9f

View file

@ -32,7 +32,7 @@ nf=
# count files against all the other commits in the system not just $oldsha # count files against all the other commits in the system not just $oldsha
# (why? consider what is $oldtree when you create a new branch, or what is # (why? consider what is $oldtree when you create a new branch, or what is
# $oldsha when you update an old feature branch from master and then push it # $oldsha when you update an old feature branch from master and then push it
count=`git log --name-only $nf --format=%n $newtree --not --all | grep . | sort -u | wc -l` count=`git log --name-only $nf --format=%n $newtree --not --all | grep . | sort -u | perl -ne '}{print "$."'`
[[ $count -gt $max ]] && { [[ $count -gt $max ]] && {
# count has been exceeded. If $9 was NO_SIGNOFF there's still a chance # count has been exceeded. If $9 was NO_SIGNOFF there's still a chance