Eclipse使用External Tools定位class文件目录路径

Mac 版本:

http://www.cnblogs.com/stevenlii/p/8513410.html 

project_loc=$1
echo "project_loc:"$project_loc
class_root_loc="$project_loc"/bin/
echo "class_root_loc:"$class_root_loc

java_type_name=$2
echo "java_type_name:"$java_type_name
package_loc=${java_type_name//./\/}
echo "package_loc:"$package_loc

class_loc="$class_root_loc""$package_loc".class
echo "class_loc:"$class_loc

open -R "$class_loc"

找到工程目录,然后我的class文件都在bin下面,替换包路径的“.”变成“/”,凑成class全路径,使用open命令定位文件。

Eclipse配置

 

 Windows版本:

http://www.cnblogs.com/stevenlii/p/8513410.html 

 

@echo off  
set calssdir=%1
set package=%2
echo %calssdir%\%package%.class
set package=%package:.=\%
echo %calssdir%\%package%.class
start explorer /select,  %calssdir%\%package%.class

 

  

 

Eclipse使用External Tools定位java 源文件目录路径 - stevenlii - 博客园
http://www.cnblogs.com/stevenlii/p/8513611.html

posted @ 2018-03-06 11:30  stevenlii  阅读(309)  评论(0编辑  收藏  举报