Mac系统中,Eclipse无法导入含中文路径的工程(Project Explorer栏文件名乱码)

Ladys & Gentlemen:

1.打开eclipse安装目录,显示eclipse.app包内容

2.修改Contents/info.plist 文件,增加内容:

<?xml version="1.0" encoding="UTF-8"?>  
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">  
<plist version="1.0">  
    <dict>  
        <key>LSEnvironment</key>  
        <dict>  
            <key>JAVA_TOOL_OPTIONS</key>  
            <string>-Dfile.encoding=UTF-8</string>  
            <key>LANG</key>  
            <string>zh_CN.UTF-8</string>  
 
        </dict>  
        <key>CFBundleExecutable<key>

<dict>

<key>LSEnvironment</key>  

     <dict>  

         <key>JAVA_TOOL_OPTIONS</key>  

         <string>-Dfile.encoding=UTF-8</string>  

         <key>LANG</key>  

         <string>zh_CN.UTF-8</string>  

     </dict>

        //此处是默认文件的开始,加上面一段xml即可。

<key>CFBundleExecutable</key>

<string>eclipse</string>

3.修改Contents/MacOS/eclipse.ini文件

在末尾加上 -Dfile.encoding=UTF-8

4.执行/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -v -f /Applications/eclipse/eclipse.app

5、如果不生效,将/Applications/eclipse/eclipse.app改名为eclipse.app的绝对路径,再次启动(方法来源于:https://blog.csdn.net/dreajay/article/details/25796511

  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值