Use $() instead of ticks

This commit is contained in:
Frédéric Mahé 2014-01-18 16:33:05 +01:00 committed by Olivier Mengué
parent 83a2215163
commit df26c49ff9

View File

@ -955,12 +955,12 @@ _lp_fossil_branch_color()
MINUSLINE=$(fossil diff | egrep -c '^-[^-].+$')
ret=""
C2AA=`fossil changes | grep -c "ADDED"`
C2AA=$(fossil changes | grep -c "ADDED")
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`
ADDFILE=$(fossil changes | grep ADDED | sed -e 's/\s\{2,\}/ /g' | cut -d" " -f2)
for FILE in $ADDFILE ; do
PLULI=$(wc -l < $FILE)
let PLUSLINE=$PLUSLINE+$PLULI
@ -971,12 +971,12 @@ _lp_fossil_branch_color()
ret+="+$PLUSLINE"
fi
C2D=`fossil changes | grep -c "DELETED"`
C2D=$(fossil changes | grep -c "DELETED")
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`
DELFILE=$(fossil changes | grep DELETED | sed -e 's/\s\{2,\}/ /g' | cut -d" " -f2)
for FILE in $DELFILE ; do
MINLI=$(wc -l < $FILE)
let MINUSLINE=$MINUSLINE+$MINLI