One of the precautions for using gradle to package and compile the project (coding)
In the window development environment:
The console of window has only two encoding formats available, gbk, english.
1. We set the output encoding format of gradle in the console as: GBK;
The setting place is (see the decompression path of gradle (the path environment variable is the same)):
2. Set the encoding format of the java file at compile time (applicable to gradle2.0+, the lower version changed JavaCompile to Compile: the reason was renamed after 2.0)