modules/woff2/update.sh
author Seth Fowler <mark.seth.fowler@gmail.com>
Tue, 02 Aug 2016 15:43:47 -0700
changeset 349754 5ce50dc53516af734f52c5eff598e8f171623040
parent 342789 c9ee3b0069e4841323c512d563ea84df73e5c313
child 457529 a35f1b78fd2ac5743dc8242f13b137a2d590b490
permissions -rwxr-xr-x
Bug 1291071 (Part 1) - Pass ImageMetadata explicitly to FinalizeDecoder. r=edwin

#!/bin/sh

# Script to update the mozilla in-tree copy of the woff2 library.
# Run this within the /modules/woff2 directory of the source tree.

MY_TEMP_DIR=`mktemp -d -t woff2_update.XXXXXX` || exit 1

git clone https://github.com/google/woff2 ${MY_TEMP_DIR}/woff2

COMMIT=`(cd ${MY_TEMP_DIR}/woff2 && git log | head -n 1)`
perl -p -i -e "s/\[commit [0-9a-f]{40}\]/[${COMMIT}]/" README.mozilla;

rm -rf src
mv ${MY_TEMP_DIR}/woff2/src src
patch -p3 < redefine-unique_ptr.patch
rm -rf ${MY_TEMP_DIR}
hg add src

echo "###"
echo "### Updated woff2/src to $COMMIT."
echo "### Remember to verify and commit the changes to source control!"
echo "###"