Skip to content

Add guide for running Rewrite on Infrastructure-as-Code projects#507

Open
timtebeek wants to merge 5 commits into
masterfrom
tim/hcl-local-parser
Open

Add guide for running Rewrite on Infrastructure-as-Code projects#507
timtebeek wants to merge 5 commits into
masterfrom
tim/hcl-local-parser

Conversation

@timtebeek
Copy link
Copy Markdown
Member

@timtebeek timtebeek commented May 18, 2026

Summary

  • New guide at docs/running-recipes/running-rewrite-on-an-infrastructure-as-code-project.md covering three ways to apply OpenRewrite recipes to IaC repos that have no Maven or Gradle build: the Moderne CLI, a host Gradle project (with a step-by-step walkthrough in a collapsible block), and a standalone Java runner.
  • Frames the page around the general "no pom.xml / build.gradle" problem, with Terraform as the running example and a source-type table at the top covering YAML/Kubernetes/Helm, Dockerfiles, GitHub Actions / GitLab CI workflows, and Protobuf.
  • Authoring section points to the per-module LST tree and test directories so readers can adapt examples from any language module, and links the Moderne Terraform recipe catalog alongside community HCL recipe libraries.
  • Adds the new page to the running-recipes sidebar in sidebars.ts.

Test plan

  • Build the docs site locally and verify the new page renders, the sidebar entry appears in the right group, the source-type and authoring tables render, and the collapsible <details> blocks under Options 2 and 3 work.

Documents three approaches (Moderne CLI, host Gradle project, standalone
runner) for applying OpenRewrite recipes to repositories without a Maven
or Gradle build, and links the same pattern over to YAML, Docker, GitHub
Actions/GitLab CI, and Protobuf sources.
@github-project-automation github-project-automation Bot moved this to In Progress in OpenRewrite May 18, 2026
@timtebeek timtebeek added the documentation Improvements or additions to documentation label May 18, 2026
@timtebeek timtebeek requested a review from mike-solomon May 18, 2026 20:22
timtebeek added 4 commits May 18, 2026 22:25
Reframe Option 2 around Moderne CLI availability rather than OSS
preference, and add a stability warning to the Option 3 standalone
runner since the embedded parser/recipe APIs may change across releases.
Rename the page to "Running Rewrite on an Infrastructure-as-Code project"
and lead with the general "no Maven/Gradle build" problem. Terraform
remains the running example throughout; the source-type table moves the
YAML, Docker, CI workflow, and Protobuf alternatives from a tip aside
into the page's structure so they are discoverable up front.
The reviewer asked the authoring section to do more to illustrate that
other IaC languages follow the same approach. Add a table listing the
LST and test directories for each language module, and fix two broken
references found while verifying paths: the live Dockerfile module
lives under openrewrite/rewrite (the standalone rewrite-docker repo is
archived), and the protobuf package is `protobuf`, not `proto`.
@timtebeek timtebeek marked this pull request as ready for review May 20, 2026 09:53
@timtebeek timtebeek changed the title Add guide for running Rewrite on HCL/Terraform projects Add guide for running Rewrite on Infrastructure-as-Code projects May 20, 2026
@timtebeek timtebeek moved this from In Progress to Ready to Review in OpenRewrite May 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

Status: Ready to Review

Development

Successfully merging this pull request may close these issues.

1 participant