Use package-level error sentinel
ProprietaryMove inline errors.New("...") calls to package-level sentinel variables so they can be compared with errors.Is. Each distinct message becomes one sentinel per package, declared in the first file that uses it and referenced from every other.
org. openrewrite. golang. codequality. UsePackageLevelErrorSentinelmod run . --recipe= org. openrewrite. golang. codequality. UsePackageLevelErrorSentinelInstall it once, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.