Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e84a65c0 authored by Brad Ebinger's avatar Brad Ebinger Committed by Automerger Merge Worker
Browse files

Fix repo hook error upon upload am: 85af7f48 am: 3412b048 am: ea5ea335

Original change: https://android-review.googlesource.com/c/platform/packages/services/Telecomm/+/1691445

Change-Id: I5ba84200ce595971e5704df4f8c7a4636a85a917
parents 6c8d16d3 ea5ea335
Loading
Loading
Loading
Loading
+8 −4
Original line number Diff line number Diff line
@@ -41,11 +41,14 @@ def main():
  commit_msg = subprocess.check_output(["git", "show",
                                        sys.argv[1], "--no-notes"])
  for commit_line in commit_msg.splitlines():
    if re.search(AOSP_COMMIT_TAG_REGEX, commit_line, re.IGNORECASE):
      _check_aosp_message(commit_line)
    # Some lines in the commit message will be given to us as bytes
    commit_line_str = str(commit_line)
    if re.search(AOSP_COMMIT_TAG_REGEX, str(commit_line_str), re.IGNORECASE):
      _check_aosp_message(commit_line_str)

  print(ERROR_MESSAGE)
  sys.exit(0)
  # Print the warning, but do not fail the presubmit check.
  sys.exit(77)

def _is_in_aosp():
  branch_info = subprocess.check_output(["git", "branch", "-vv"])
@@ -59,7 +62,8 @@ def _check_aosp_message(aosp_line):
    sys.exit(0)

  print(ERROR_MESSAGE)
  sys.exit(0)
  # Print the warning, but do not fail the presubmit check.
  sys.exit(77)

if __name__ == '__main__':
  main()