Wednesday, April 11, 2012

maven build error: unmappable character for encoding Cp1252

I've just encountered this strange error when I use maven to build my project:
[ERROR] c:\w\_lgl\rythm\src\main\java\com\greenlaw110\rythm\utils\S.java:[125,1279] unmappable character for encoding Cp1252
The solution is open the pom.xml file and add one line into the maven-compiler-plugin section:

 org.apache.maven.plugins
 maven-compiler-plugin
 2.0.2
 
  1.6
  1.6
  UTF-8