diff --git a/google-bazel-bot/bazel-bot/utils.py b/google-bazel-bot/bazel-bot/utils.py index 4fcec80e5..33fc33fec 100644 --- a/google-bazel-bot/bazel-bot/utils.py +++ b/google-bazel-bot/bazel-bot/utils.py @@ -341,6 +341,12 @@ def __init__(self, repo_path: str, creds: CredentialManager, can_create_pr): self.remote_name = "origin" self.author_name = os.getenv("GIT_AUTHOR_NAME", "Google Bazel Bot") self.author_email = os.getenv("GIT_AUTHOR_EMAIL", "google-bazel-bot@google.com") + self.repo.git.update_environment( + GIT_AUTHOR_NAME=self.author_name, + GIT_AUTHOR_EMAIL=self.author_email, + GIT_COMMITTER_NAME=self.author_name, + GIT_COMMITTER_EMAIL=self.author_email, + ) self.branch_prefix = "bazel-" def get_branch_name(self, commit_hash: str) -> str: