Use Collections.singleton(..) for a single recipe tag
MSALReplace new HashSet<>(Arrays.asList(tag)) and similar copies of a one-element list, optionally wrapped in Collections.unmodifiableSet(..), with Collections.singleton(tag) for recipe tags. Tags are only read, so the immutable singleton set is safe on Java 8.
org. openrewrite. java. recipes. UseCollectionsSingletonForSingleTagmod run . --recipe= org. openrewrite. java. recipes. UseCollectionsSingletonForSingleTagInstall it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.