开发者

Setting Encoding format to java in shell Script

开发者 https://www.devze.com 2023-01-30 10:41 出处:网络
I have a shell script which runs My Java Application.Now i want to specify encoding format \"UTF8\" 开发者_如何学JAVAto my java application using shell script can any one help.I am using mac os.

I have a shell script which runs My Java Application.Now i want to specify encoding format "UTF8" 开发者_如何学JAVAto my java application using shell script can any one help.I am using mac os.

Thanks

Ganesh


Try

//invoking the compiler when your source code contains naked UTF-8 characters.
javac.exe -encoding UTF-8  MyClass.java

and

//setting the default encoding on the command line
java.exe "-Dfile.encoding=UTF-8" -jar myprog.jar

source: http://mindprod.com/jgloss/encoding.html

0

精彩评论

暂无评论...
验证码 换一张
取 消