8214710: Fix hg log in update_copyright_year.sh
authorihse
Mon, 03 Dec 2018 18:44:45 +0100
changeset 52803 0402d381135d
parent 52802 7b757120a053
child 52804 28094715ae71
8214710: Fix hg log in update_copyright_year.sh Reviewed-by: alanb, tbell, erikj
make/scripts/update_copyright_year.sh
--- a/make/scripts/update_copyright_year.sh	Mon Dec 03 18:43:24 2018 +0100
+++ b/make/scripts/update_copyright_year.sh	Mon Dec 03 18:44:45 2018 +0100
@@ -98,7 +98,7 @@
   count=0
   files=${tmp}/files.$1
   rm -f ${files}
-  hg log --rev $1 -v --template '{files}\n' | expand \
+  hg log -l1 --rev $1 -v --template '{files}\n' | expand \
     | ${awk} -F' ' '{for(i=1;i<=NF;i++)print $i}' \
     > ${files}
   if [ -f "${files}" -a -s "${files}" ] ; then
@@ -120,8 +120,8 @@
     printf "  ERROR: No files changed in the changeset? Must be a mistake.\n"
     set -x
     ls -al ${files}
-    hg log --rev $1 -v --template '{files}\n'
-    hg log --rev $1 -v --template '{files}\n' | expand \
+    hg log -l1 --rev $1 -v --template '{files}\n'
+    hg log -l1 --rev $1 -v --template '{files}\n' | expand \
       | ${awk} -F' ' '{for(i=1;i<=NF;i++)print $i}'
     set +x
     exit 1
@@ -150,7 +150,7 @@
     desc=${tmp}/desc.${changeset}
     rm -f ${desc}
     echo "------------------------------------------------"
-    hg log --rev ${changeset} --template '{desc}\n' > ${desc}
+    hg log -l1 --rev ${changeset} --template '{desc}\n' > ${desc}
     printf "%d: %s\n%s\n" ${index} "${changeset}" "`cat ${desc}|head -1`"
     if [ "${year}" = "2010" ] ; then
       if cat ${desc} | fgrep -i "Added tag" > /dev/null ; then