[ https://jira.duraspace.org/browse/DS-1528?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=27998#comment-27998 ]
Pascal-Nicolas Becker commented on DS-1528: ------------------------------------------- I think it is obvious that Maven read the properties file as if it is ISO-8859-1 encoded and writes the dspace.cfg UTF-8 encoded. As Maven suppose the properties file is latin-1 encoded and the target should be utf-8 encoded it converts the source files to uft-8. Doing so usual charactes don't get crumbled as there is no difference between ISO-8859-1 and UTF-8. But if you do this with german Umlauts or characters with accents or so on, they get crumbled. Tim took UTF-8 text, told iconv to read it as ISO-8859-1 encoded text and to convert it to UTF-8 and it happend what I just explained. Maven does the same... Just a bold guess: Perhaps Maven has the same problem we had? You can do what ever you want (-Dfile.encoding, ....), if you use java.util.Properties.load(InputStream), it will always reads the InputStream as if it is ISO-8859-1 encoded. I don't have time to look for and in the maven source code, but I can imagine that Maven reads the Properties file like this. The solution would be to use java.util.Properties.load(Reader). In my opinion java.util.Properties.load(InputStream) should be marked deprecated, just my two cents ander perhaps off-topic here. ;-) > build.properties doesn't support UTF-8 encoding > ----------------------------------------------- > > Key: DS-1528 > URL: https://jira.duraspace.org/browse/DS-1528 > Project: DSpace > Issue Type: Bug > Affects Versions: 3.0, 3.1 > Reporter: Tim Donohue > Priority: Major > Fix For: 3.2 > > > This is related to DS-1469 > When UTF-8 characters are placed in the build.properties file, they are > improperly filtered into the final dspace.cfg file. > This seems to be the fault of the maven-resources-plugin. However, according > to it's documentation, it is supposed to support UTF-8 encoding: > http://maven.apache.org/plugins/maven-resources-plugin/examples/encoding.html -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira ------------------------------------------------------------------------------ Try New Relic Now & We'll Send You this Cool Shirt New Relic is the only SaaS-based application performance monitoring service that delivers powerful full stack analytics. Optimize and monitor your browser, app, & servers with just a few lines of code. Try New Relic and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_apr _______________________________________________ Dspace-devel mailing list Dspace-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-devel