Lines Matching +full:rev +full:- +full:parse
1 #!/bin/bash -eu
3 # Use of this source code is governed by a BSD-style license that can be
7 # on their copy of toolchain-utils, this script will do all of the necessary
8 # merging/branch creation/etc. to make keeping things up-to-date trivial.
11 # https://android-review.googlesource.com/c/platform/external/toolchain-utils/+/1132504/1
16 remote_branch="${remote}/upstream-main" # nocheck
18 my_dir="$(dirname "$(readlink -m "$0")")"
23 current_rev="$(git rev-parse HEAD)"
24 main_rev="$(git rev-parse "${local_upstream}")"
32 if ! git rev-parse "${local_branch_name}" >& /dev/null; then
36 echo -n "${local_branch_name} is a valid branch already. Delete? [y/N] " >&2
39 read -r line
46 git checkout --detach || return
47 git branch -D "${local_branch_name}"
52 merge_base="$(git merge-base HEAD "${remote_branch}")"
53 git log --oneline "${merge_base}..${remote_branch}"
59 echo "Ensuring repository is up-to-date..."
64 num_commits="$(wc -l <<< "${commit_list}")"
68 commit_message="Merging ${num_commits} commit(s) from Chromium's toolchain-utils
74 git merge "${remote_branch}" -m "${commit_message}"