1#!/bin/bash
2#
3# Copyright 2017 The PDFium Authors. All rights reserved.
4# Use of this source code is governed by a BSD-style license that can be
5# found in the LICENSE file.
6
7set -e
8set -o pipefail
9set -u
10
11REVIEWERS=`paste -s -d, third_party/freetype/OWNERS`
12roll-dep -r "${REVIEWERS}" "$@" pdfium/third_party/freetype/src/
13FTVERSION=`git -C third_party/freetype/src/ describe --long`
14FTCOMMIT=`git -C third_party/freetype/src/ rev-parse HEAD`
15
16# Make sure our copy of pstables.h matches the one in freetype/src.
17cmp third_party/freetype/src/src/psnames/pstables.h \
18  third_party/freetype/include/pstables.h
19
20sed -i "s/^Version: .*\$/Version: ${FTVERSION%-*}/" \
21  third_party/freetype/README.pdfium
22sed -i "s/^Revision: .*\$/Revision: ${FTCOMMIT}/" \
23  third_party/freetype/README.pdfium
24
25git add third_party/freetype/README.pdfium
26git commit --quiet --amend --no-edit
27