Skip to content

Commit 6f4fd6a

Browse files
jeplerdpgeorge
authored andcommitted
tools/ci.sh: Use a better default reference ref in code_size_build.
Now the default reference commit is the first parent of the selected commit, instead of the first parent of HEAD. Signed-off-by: Jeff Epler <[email protected]>
1 parent 3bea897 commit 6f4fd6a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/ci.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,8 @@ function ci_code_size_build {
9898
# the code size impact would be if we merged this PR. During CI we are at a merge commit,
9999
# so this tests the merged PR against its merge base.
100100
# Override the refs by setting REFERENCE and/or COMPARISON in the environment before invoking ci.
101-
: ${REFERENCE:=$(git rev-parse --short HEAD^1)}
102101
: ${COMPARISON:=$(git rev-parse --short HEAD)}
102+
: ${REFERENCE:=$(git rev-parse --short ${COMPARISON}^1)}
103103

104104
echo "Comparing sizes of reference ${REFERENCE} to ${COMPARISON}..."
105105
git log --oneline $REFERENCE..$COMPARISON

0 commit comments

Comments
 (0)