Moderne OnlyThis recipe is proprietary to Moderne and runs on the Moderne platform or CLI — it isn’t part of the open-source catalog. Available with a Moderne subscription.
Naming code quality
Recipe ID
OpenRewrite.Recipes.CSharp.CodeQuality.Naming.NamingCodeQualityArtifact
OpenRewrite.Recipes.CSharp.CodeQualityDefinition
Recipes10
- Async method name should end with Async
- Non-async method should not end with Async
- Use nameof operator
- Rename private field according to _camelCase convention
- Rename parameter to camelCase
- Parameter name should match base definition
- Attribute name should end with 'Attribute'
- Exception name should end with 'Exception'
- EventArgs name should end with 'EventArgs'
- Find TODO/HACK/FIXME comments
Usage
Run this recipe
In order to run C# recipes, you will need to use the Moderne CLI.
Once the CLI is installed, you can install this C# recipe package by running the following command:
Install the recipe package
mod config recipes nuget install OpenRewrite.Recipes.CSharp.CodeQuality
Then, you can run the recipe via:
Run the recipe
mod run . --recipe OpenRewrite.Recipes.CSharp.CodeQuality.Naming.NamingCodeQuality