matthiasblaesing opened a new pull request #3836:
URL: https://github.com/apache/netbeans/pull/3836


   With JDK 18 the default charset for java was changed. Before this
   change, the default charset (exposed as the system property
   file.encoding) was platform specific. After the change the default
   charset was unified to UTF-8 on all platforms.
   
   Code that interacts with native APIs can use the system property
   native.encoding to query the platform encoding and use that. And related
   to this the same is true for applications interacting with the system
   console.
   
   The primarly affected platform is windows, as both mac OS and Linux
   already default to UTF-8 as file encoding.
   
   In this PR two areas are covered:
   
   - General execution (using "External Execution API"): The module already
     allows users to specify the encoding to use. It used the default
     enconding as a fallback, if none was specified. This fallback was
     enhanced to query the native.encoding system property first. If it is
     present, it will be used as default encoding (JDK 18+), if it is
     missing, the original behavior using the default file encoding is
     activated.
   
   - Maven target execution: maven target execution is basicly an external
     execution, so the same considerations apply. In contrast to the
     general execution API, the encoding for maven execution can't be
     overriden, so both code path (input + output) are configured to use
     the native.enconfig property if present or fallback to the default
     file encoding.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to