Skip to content

Commit

Permalink
Merge pull request #277 from acsone/skip-forks-early-sbi
Browse files Browse the repository at this point in the history
Skip forks early in main branch bot
  • Loading branch information
sbidoul authored Dec 16, 2023
2 parents aac1932 + c8d582e commit 6ee3928
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions newsfragments/277.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Skip fork repos earlier in main branch bot, for better performance in organisations
with a large number of forks.
2 changes: 2 additions & 0 deletions src/oca_github_bot/tasks/main_branch_bot.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,8 @@ def main_branch_bot(org, repo, branch, build_wheels, dry_run=False):
def main_branch_bot_all_repos(org, build_wheels, dry_run=False):
with github.login() as gh:
for repo in gh.repositories_by(org):
if repo.fork:
continue
for branch in repo.branches():
if not is_main_branch_bot_branch(branch):
continue
Expand Down

0 comments on commit 6ee3928

Please sign in to comment.