Browse Source

👷 Update github-actions user for GitHub Actions workflows (#14528)

pull/14529/head
Sebastián Ramírez 6 months ago
committed by GitHub
parent
commit
c548348386
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 5
      scripts/contributors.py
  2. 5
      scripts/people.py
  3. 5
      scripts/sponsors.py
  4. 5
      scripts/topic_repos.py
  5. 5
      scripts/translate.py

5
scripts/contributors.py

@ -282,9 +282,10 @@ def main() -> None:
return return
logging.info("Setting up GitHub Actions git user") logging.info("Setting up GitHub Actions git user")
subprocess.run(["git", "config", "user.name", "github-actions"], check=True) subprocess.run(["git", "config", "user.name", "github-actions[bot]"], check=True)
subprocess.run( subprocess.run(
["git", "config", "user.email", "[email protected]"], check=True ["git", "config", "user.email", "github-actions[bot]@users.noreply.github.com"],
check=True,
) )
branch_name = f"fastapi-people-contributors-{secrets.token_hex(4)}" branch_name = f"fastapi-people-contributors-{secrets.token_hex(4)}"
logging.info(f"Creating a new branch {branch_name}") logging.info(f"Creating a new branch {branch_name}")

5
scripts/people.py

@ -378,9 +378,10 @@ def main() -> None:
return return
logging.info("Setting up GitHub Actions git user") logging.info("Setting up GitHub Actions git user")
subprocess.run(["git", "config", "user.name", "github-actions"], check=True) subprocess.run(["git", "config", "user.name", "github-actions[bot]"], check=True)
subprocess.run( subprocess.run(
["git", "config", "user.email", "[email protected]"], check=True ["git", "config", "user.email", "github-actions[bot]@users.noreply.github.com"],
check=True,
) )
branch_name = f"fastapi-people-experts-{secrets.token_hex(4)}" branch_name = f"fastapi-people-experts-{secrets.token_hex(4)}"
logging.info(f"Creating a new branch {branch_name}") logging.info(f"Creating a new branch {branch_name}")

5
scripts/sponsors.py

@ -190,9 +190,10 @@ def main() -> None:
return return
logging.info("Setting up GitHub Actions git user") logging.info("Setting up GitHub Actions git user")
subprocess.run(["git", "config", "user.name", "github-actions"], check=True) subprocess.run(["git", "config", "user.name", "github-actions[bot]"], check=True)
subprocess.run( subprocess.run(
["git", "config", "user.email", "[email protected]"], check=True ["git", "config", "user.email", "github-actions[bot]@users.noreply.github.com"],
check=True,
) )
branch_name = f"fastapi-people-sponsors-{secrets.token_hex(4)}" branch_name = f"fastapi-people-sponsors-{secrets.token_hex(4)}"
logging.info(f"Creating a new branch {branch_name}") logging.info(f"Creating a new branch {branch_name}")

5
scripts/topic_repos.py

@ -56,9 +56,10 @@ def main() -> None:
return return
repos_path.write_text(new_repos_content, encoding="utf-8") repos_path.write_text(new_repos_content, encoding="utf-8")
logging.info("Setting up GitHub Actions git user") logging.info("Setting up GitHub Actions git user")
subprocess.run(["git", "config", "user.name", "github-actions"], check=True) subprocess.run(["git", "config", "user.name", "github-actions[bot]"], check=True)
subprocess.run( subprocess.run(
["git", "config", "user.email", "[email protected]"], check=True ["git", "config", "user.email", "github-actions[bot]@users.noreply.github.com"],
check=True,
) )
branch_name = f"fastapi-topic-repos-{secrets.token_hex(4)}" branch_name = f"fastapi-topic-repos-{secrets.token_hex(4)}"
logging.info(f"Creating a new branch {branch_name}") logging.info(f"Creating a new branch {branch_name}")

5
scripts/translate.py

@ -947,9 +947,10 @@ def make_pr(
if not repo.is_dirty(untracked_files=True): if not repo.is_dirty(untracked_files=True):
print("Repository is clean, no changes to commit") print("Repository is clean, no changes to commit")
return return
subprocess.run(["git", "config", "user.name", "github-actions"], check=True) subprocess.run(["git", "config", "user.name", "github-actions[bot]"], check=True)
subprocess.run( subprocess.run(
["git", "config", "user.email", "[email protected]"], check=True ["git", "config", "user.email", "github-actions[bot]@users.noreply.github.com"],
check=True,
) )
branch_name = "translate" branch_name = "translate"
if language: if language:

Loading…
Cancel
Save