Fix tabs in source (fossil support)

This commit is contained in:
Olivier Mengué 2013-12-04 22:54:03 +01:00
parent 83266cd6a5
commit c5b1c3d705

View File

@ -967,45 +967,45 @@ _lp_fossil_branch_color()
local C2E # Modified files (added or edited)
local C2D # Deleted files
local C2A # Extras files
local C2AA # Added files
local PLUSLINE # Added lines
local MINUSLINE # Deleted lines
local C2AA # Added files
local PLUSLINE # Added lines
local MINUSLINE # Deleted lines
local ret
C2E=$(fossil changes | wc -l)
C2A=$(fossil extras | wc -l)
PLUSLINE=$(fossil diff | egrep '^\+[^+].+$' | wc -l)
MINUSLINE=$(fossil diff | egrep '^-[^-].+$' | wc -l)
PLUSLINE=$(fossil diff | egrep '^\+[^+].+$' | wc -l)
MINUSLINE=$(fossil diff | egrep '^-[^-].+$' | wc -l)
ret=""
C2AA=`fossil changes | grep ADDED | wc -l`
if [[ $C2AA -gt 0 ]] ; then
# We count the line "à la" git
local ADDFILE
local FILE
ADDFILE=`fossil changes | grep ADDED | sed -e 's/\s\{2,\}/ /g' | cut -d" " -f2`
for FILE in $ADDFILE ; do
PLULI=$(wc -l $FILE | cut -d" " -f1)
let PLUSLINE=$PLUSLINE+$PLULI
done
fi
C2AA=`fossil changes | grep ADDED | wc -l`
if [[ $C2AA -gt 0 ]] ; then
# We count the line "à la" git
local ADDFILE
local FILE
ADDFILE=`fossil changes | grep ADDED | sed -e 's/\s\{2,\}/ /g' | cut -d" " -f2`
for FILE in $ADDFILE ; do
PLULI=$(wc -l $FILE | cut -d" " -f1)
let PLUSLINE=$PLUSLINE+$PLULI
done
fi
if [[ $PLUSLINE -gt 0 ]] ; then
ret+="+$PLUSLINE"
fi
ret+="+$PLUSLINE"
fi
C2D=`fossil changes | grep DELETED | wc -l`
if [[ $C2D -gt 0 ]] ; then
# We count the line "à la" git
local DELFILE
local FILE
DELFILE=`fossil changes | grep DELETED | sed -e 's/\s\{2,\}/ /g' | cut -d" " -f2`
for FILE in $DELFILE ; do
MINLI=$(wc -l $FILE | cut -d" " -f1)
let MINUSLINE=$MINUSLINE+$MINLI
done
fi
C2D=`fossil changes | grep DELETED | wc -l`
if [[ $C2D -gt 0 ]] ; then
# We count the line "à la" git
local DELFILE
local FILE
DELFILE=`fossil changes | grep DELETED | sed -e 's/\s\{2,\}/ /g' | cut -d" " -f2`
for FILE in $DELFILE ; do
MINLI=$(wc -l $FILE | cut -d" " -f1)
let MINUSLINE=$MINUSLINE+$MINLI
done
fi
if [[ $MINUSLINE -gt 0 ]] ; then
if [[ $MINUSLINE -gt 0 ]] ; then
if [[ "$ret" = "" ]] ; then
ret+="-$MINUSLINE"
else