Hi

Will likely not work until done on the jvm with line.separator system prop
directly due to a lot of things or means you limit the plugins you use a
lot so I think jvm.config is the way to go or you hack wrapper commited
launcher scripts to force it in MAVEN_OPTS.

Le ven. 10 févr. 2023 à 19:42, Piotr P. Karwasz <[email protected]> a
écrit :

> Hi,
>
> At Log4j we have solved all the reproducibility problems mentioned on
> the wiki page[1] and we are approaching the problem of reproducibility
> between different OSes.
>
> My goal is for the following procedure to work regardless of the
> operating system of the user:
>
> 1. a user checks out a tagged release from the Git repository,
> 2. the user runs the Maven Wrapper: 'mvn package'
> 3. the user checks the SHA256 of the resulting JAR file with the one
> from Maven Central.
>
> The only problem I have encountered so far is the difference between
> line endings on Windows and UNIX systems.
>
> The line endings of static resources can be easily fixed using a
> `.gitattributes` file, but the line endings of resources generated by
> plugins may vary. Many plugins respect `System.lineSeparator()`, but
> setting the `line.separator` Java system property on the command line
> is no trivial task and it can not certainly be done in
> `.mvn/jvm.config`.
>
> What do you think about introducing a POM-like system property (e.g.
> `project.build.lineSeparator`) that would allow setting
> `line.separator` using a simple `-Dproject.build.lineSeparator=LF` or
> `-Dproject.build.lineSeparator=CRLF`? Ideally this could be a real POM
> property, but I am afraid that by the time the POM is resolved,
> `System.lineSeparator()` is already initialized.
>
> Piotr
>
> [1]
> https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=74682318
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

Reply via email to