rewrite icon indicating copy to clipboard operation
rewrite copied to clipboard

LST SourceFile for file encoded as ISO-8859 produced with encoding set to UTF-8

Open natedanner opened this issue 1 year ago • 0 comments

LST produced for rewrite-kubernetes had wrong encoding for the gradlew file @ commit has 331ae5dfe53950c69aac341b7ae0cc060216ba6e Related to: https://github.com/moderneinc/moderne-scm/issues/724

How are you running OpenRewrite?

Through the Moderne SaaS.

Is your project public? If so, can you share a link to it? https://github.com/openrewrite/rewrite-kubernetes @ this commit hash 331ae5dfe53950c69aac341b7ae0cc060216ba6e This file was changed back to UTF-8 with this commit https://github.com/openrewrite/rewrite-kubernetes/commit/d335ee6f9c618f1635a5c3373798ff0e25949d7c

What is the smallest, simplest way to reproduce the problem?

  • Build an LST for https://github.com/openrewrite/rewrite-kubernetes @ this commit hash 331ae5dfe53950c69aac341b7ae0cc060216ba6e
  • Read the LSTs SourceFiles and check the charsetName property. It should match the file on disk

What did you expect to see?

charsetName property equal to ISO-8859

What did you see instead?

charsetName property equal to UTF-8 Screenshot 2024-06-07 at 11 20 03 AM

natedanner avatar Jun 07 '24 18:06 natedanner