sbt-github-actions icon indicating copy to clipboard operation
sbt-github-actions copied to clipboard

Support for beta feature Concurrency

Open jlprat opened this issue 4 years ago • 3 comments

GitHub workflows have now a feature in beta, concurrency. One can read more in here: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#concurrency

The feature enables to stop an already running workflow when a new one is enqueued. Enabling this would save lots of time on CI servers for jobs that are already obsolete. To configure it, this should be added to the continuous integration yml file:

concurrency:
  group: ci-${{ github.ref }}
  cancel-in-progress: true

@djspiewak Would you consider adding this feature even though is still in Beta on GitHub side? I would be willing to contribute it.

jlprat avatar Aug 16 '21 08:08 jlprat

@jlprat Finally got around to this! This looks really awesome honestly, and feels like something that should definitely be well integrated into this plugin. Would love to have it as a feature!

In particular, I think we should ensure that it's configurable, but the default should be to group based on Pull Request specifier (I believe that is what github.ref covers) or upstream branch if not on a PR.

djspiewak avatar Nov 29 '21 05:11 djspiewak

@mdedetrich this is useful. sbt-typelevel's equivalent plugin to this supports it.

pjfanning avatar Oct 18 '23 15:10 pjfanning

There are plans to upstream this

mdedetrich avatar Oct 18 '23 15:10 mdedetrich