Bug 1342212 - Add the commit date to the cubeb README_MOZILLA file to allow automated tooling to detect too-old libraries. r=kinetik
authorTom Ritter <tom@mozilla.com>
Mon, 27 Feb 2017 13:53:41 -0600
changeset 490317 9a9362c9fcd9cf626b6107b571a469a8e47d2cb4
parent 490316 5dc23fac58010d61efe9733da71177afcaa2e0e8
child 490318 5a989a69ea61d7b945d8b454b49c5ae2ed545edb
push id47063
push userbmo:rail@mozilla.com
push dateTue, 28 Feb 2017 03:41:15 +0000
reviewerskinetik
bugs1342212
milestone54.0a1
Bug 1342212 - Add the commit date to the cubeb README_MOZILLA file to allow automated tooling to detect too-old libraries. r=kinetik MozReview-Commit-ID: CbBlmy1jZU
media/libcubeb/README_MOZILLA
media/libcubeb/update.sh
--- a/media/libcubeb/README_MOZILLA
+++ b/media/libcubeb/README_MOZILLA
@@ -1,8 +1,8 @@
 The source from this directory was copied from the cubeb 
 git repository using the update.sh script.  The only changes
 made were those applied by update.sh and the addition of
 Makefile.in build files for the Mozilla build system.
 
 The cubeb git repository is: git://github.com/kinetiknz/cubeb.git
 
-The git commit ID used was 25b593fa59d0c284ff2de54b10db927d48579f5e.
+The git commit ID used was 25b593fa59d0c284ff2de54b10db927d48579f5e (2017-02-23 14:05:03 +0200)
--- a/media/libcubeb/update.sh
+++ b/media/libcubeb/update.sh
@@ -43,22 +43,23 @@ cp $1/test/test_resampler.cpp gtest
 cp $1/test/test_ring_array.cpp gtest
 cp $1/test/test_sanity.cpp gtest
 cp $1/test/test_tone.cpp gtest
 cp $1/test/test_utils.cpp gtest
 cp $1/test/test_mixer.cpp gtest
 
 if [ -d $1/.git ]; then
   rev=$(cd $1 && git rev-parse --verify HEAD)
+  date=$(cd $1 && git show -s --format=%ci HEAD)
   dirty=$(cd $1 && git diff-index --name-only HEAD)
 fi
 
 if [ -n "$rev" ]; then
   version=$rev
   if [ -n "$dirty" ]; then
     version=$version-dirty
     echo "WARNING: updating from a dirty git repository."
   fi
-  sed -i.bak -e "/The git commit ID used was/ s/[0-9a-f]\{40\}\(-dirty\)\{0,1\}\./$version./" README_MOZILLA
+  sed -i.bak -e "/The git commit ID used was/ s/[0-9a-f]\{40\}\(-dirty\)\{0,1\} .\{1,100\}/$version ($date)/" README_MOZILLA
   rm README_MOZILLA.bak
 else
   echo "Remember to update README_MOZILLA with the version details."
 fi