openrewrite / rewrite-github-actions

OpenRewrite recipes for performing GitHub action hygiene and migration tasks.
Apache License 2.0
9 stars 10 forks source link

Change the version of a GitHub Action #95

Closed timtebeek closed 11 months ago

timtebeek commented 11 months ago

What's changed?

Added ChangeActionVersion recipe.

What's your motivation?

Fixes #23

Anything in particular you'd like reviewers to focus on?

Deliberately did not make workflow file customizable; folks can use yaml preconditions. Nor did I check for existing values before overriding; we're changing, not updating here.

Have you considered any alternatives or workarounds?

Folks could already call ChangeValue with declarative yaml recipes + preconditions, but not yet via the platform (soon), and not very easy to discover for folks. This recipe can then serve as a template for some of the other suggested recipes here.

Any additional context

timtebeek commented 11 months ago

Works: https://github.com/openrewrite/rewrite-recipe-markdown-generator/commit/ae9c610e2141f628413ed8bf6b0dd693710360d3