← All recipes
Moderne licensed

Keep functions short

Recipe IDorg.openrewrite.golang.codequality.KeepFunctionsShortArtifactgithub.com/moderneinc/recipes-go

Find functions with more than 20 statements. Long functions are harder to understand and maintain.

Single recipeProprietary

Usage

This recipe has no required configuration options. You’ll need the Moderne CLI configured before running the command below.

mod run . --recipe org.openrewrite.golang.codequality.KeepFunctionsShort

If the recipe isn’t available locally, install it with:

mod config recipes go install github.com/moderneinc/recipes-go