incu6us / goimports-reviser

Right imports sorting & code formatting tool (goimports alternative)
MIT License
586 stars 75 forks source link

Add option to avoid modifying generated code #81

Closed sgtsquiggs closed 1 year ago

sgtsquiggs commented 2 years ago

Currently we loop through all go files, grep to see if "^// Code generated .* DO NOT EDIT\.$" matches, and skip those files when applying goimports-reviser. An option to avoid these files would be preferable!

starfishs commented 2 years ago

+1

incu6us commented 1 year ago

All generated files will be skipped by default. If you need to format generated file you can use -apply-to-generated-files-option. version: v3.3.0