You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Elliotte Rusty Harold (Jira)" <ji...@apache.org> on 2023/05/17 22:47:00 UTC

[jira] [Commented] (MSOURCES-113) Store source encoding info in a standard file

    [ https://issues.apache.org/jira/browse/MSOURCES-113?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17723746#comment-17723746 ] 

Elliotte Rusty Harold commented on MSOURCES-113:
------------------------------------------------

There's an assumption here that there's only one source encoding for the archive. That's not necessarily true. In particular, I've seen test files that are deliberately encoded in various encodings precisely to test the handling of those encodings. This is quite common when you're writing XML tooling, for example. However, maybe that's only going to show up in resources, not in test sources?

Also, what happens when shading a project? The shaded project and the shading project might not have the same encoding. 


> Store source encoding info in a standard file
> ---------------------------------------------
>
>                 Key: MSOURCES-113
>                 URL: https://issues.apache.org/jira/browse/MSOURCES-113
>             Project: Maven Source Plugin
>          Issue Type: New Feature
>            Reporter: Fred Bricon
>            Priority: Major
>              Labels: intern
>
> It'd be nice if IDEs were able to automatically set proper source encoding when attaching sources to project dependencies. 
> In eclipse/m2e, we tried to automatically detect encoding but it didn't work out [https://git.eclipse.org/r/#/c/116390/]
> A more reliable way would be to ensure the encoding info was stored inside the source archive, so that IDEs could peek into it and ensure proper settings.
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)