Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Github Actionsで同じジョブを2つ同時に実行していて冗長な印象がある #8

Open
imaxyz opened this issue Mar 11, 2022 · 1 comment

Comments

@imaxyz
Copy link
Contributor

imaxyz commented Mar 11, 2022

#7 で、Github Actionsのワークフローを新規作成しましたが、同じジョブを複数同時に実行していて冗長にも見えます。

↓Python3.6で、Test_with_toxのジョブを2つ同時に実行している

image

参考

https://github.com/beproud/bpmappers/pull/7/files#r823398611

@tokibito
Copy link
Collaborator

@imaxyz
この件、ベストプラクティスというのがなくて、運用も少し考慮が必要そうです。
結構みんな悩む問題なのかな。
https://github.community/t/how-to-trigger-an-action-on-push-or-pull-request-but-not-both/16662/16

masterにpushしたときと、PR作ったときにしておいて、開発ブランチでCIを実行したいときはDraft PRを作る、という運用にして、以下のような設定にしてみるとか?(コミュニティのほうのスレッドにあった例)

on:
  push:
    branches:
      - master
  pull_request:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants