您的位置:首页 > 编程语言 > Java开发

MyEclipse8.5安装Spket插件(非通过Configuration Center的方式)

2013-07-31 10:36 357 查看
配置环境:
一. 配置环境
MyEclipse8.5 + Spket 1.6.18 + ExtJS 3.2.1。
二.安装 Spket-1.6.8
下载Spket, 地址:http://spket.com/download.html , 选择 Spket IDE 或 Plugin 下载 (CSDN
中有 Spket 1.6.18 的破解版,请自己搜索一下!)
1. 在 CMD 中执行 java -jarspket-1.6.17.jar, 点"Next"
2. 选择 eclipse plugin, 点"Next"
3. 选择MyEclipse8.5 的安装目录的 common 文件夹, 点"Next"!
4. 选择 Spket 的安装目录(6.0 选择MyEclipse 的目录一样, 7.0 以上不要和 MyEclipse 的目录在一起),点"Next",
然后开始安装. 以上步骤4 和 zip 文件解压出来文件的一样.如果是 MyEclipse6.0,则到止步骤已经安 装成功,重启MyEclipse,接着后面步骤(三)的“配置 Spket”就可以。果是 7.0 以上的 MyEclipse版本,就还需要以下步骤(5~7)的配置.
5.下载 CreatePluginsConfig.zip, 把 Java 文件最后面 Spket 的安装路径改成自己的安装路径(以我自己的安装路径“d:\Programs\spket-1.6.18”为例),
编译“.java”件并执行。在控制台中会输出一些信息,如下所示:
com.spket.as.core,1.6.17,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com
.spket.as.core_1.6.17.jar,4,falsecom.spket.awt,1.6.6,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.awt_1.6.6.jar,4,falsecom.spket.core,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.core_1.6.18.jar,4,falsecom.spket.dtd,1.6.6,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.dtd_1.6.6.jar,4,falsecom.spket.extjs,1.6.17,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.extjs_1.6.17.jar,4,falsecom.spket.grammars,1.6.9,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.grammars_1.6.9\,4,falsecom.spket.js.debug,1.6.16,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.js.debug_1.6.16.jar,4,falsecom.spket.js.xpc,1.6.6,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.js.xpc_1.6.6.jar,4,falsecom.spket.js,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.js_1.6.18.jar,4,falsecom.spket.laszlo,1.6.17,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.laszlo_1.6.17.jar,4,falsecom.spket.mime,1.6.8,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.mime_1.6.8.jar,4,falsecom.spket.mxml,1.6.15,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.mxml_1.6.15.jar,4,falsecom.spket.scintilla.win32,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.scintilla.win32_1.6.18.jar,4,falsecom.spket.sted.win32,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.sted.win32_1.6.18.jar,4,falsecom.spket.sted,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.sted_1.6.18.jar,4,falsecom.spket.svg,1.6.6,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spke
t.svg_1.6.6.jar,4,falsecom.spket.swt,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.swt_1.6.18.jar,4,falsecom.spket.theme,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.theme_1.6.18.jar,4,falsecom.spket.ui,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.ui_1.6.18.jar,4,falsecom.spket.widget.win32,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.widget.win32_1.6.18.jar,4,falsecom.spket.widget,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.widget_1.6.18.jar,4,falsecom.spket.wpfe,1.6.6,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.wpfe_1.6.6.jar,4,falsecom.spket.xml,1.6.17,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.xml_1.6.17.jar,4,falsecom.spket.xul,1.6.6,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.xul_1.6.6.jar,4,falsecom.spket.yuic,1.6.18,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.yuic_1.6.18.jar,4,falsecom.spket.ywt,1.6.6,file:/d:\Programs\spket-1.6.18\eclipse\plugins\com.spket.ywt_1.6.6.jar,4,falseorg.apache.xerces,2.8.0.v200705301630,file:/d:\Programs\spket-1.6.18\eclipse\plugins\org.apache.xerces_2.8.0.v200705301630.jar,4,falseorg.apache.xml.resolver,1.1.0.v200705310020,file:/d:\Programs\spket-1.6.18\eclipse\plugins\org.apache.xml.resolver_1.1.0.v200705310020.jar,4,false
6. 把输出的东西追加到 X:\Genuitec\MyEclipse8.5\configuration\org.eclipse.equinox.simpleconfigurator\bundles.info后面.
7. 重启 MyEclipse 8.5 完成 Spket-1.6.18 的安装。在 MyEclipse 8.5 中的菜单Window -> Preferences
中将出现 Spket项目。
注意!! ! 注意!!
通过“SpketIDE”的方式进行安装,选择 MyEclipse8.5 的安装目录的 common 文件夹,会在其中建立一个“links”文件夹,里面建立一个名称为“spket.link”的文件,
内容如下:
path=D\:\\programs\\spket-1.6.18
其中,“D\:\\programs\\spket-1.6.18”即为 Spket 的安装目录! 如果不采用安装包而采用“Plugin”的方式进行 spket-1.6.18
的安装,只需将 spket 解压缩到相应的目录,并手 动在 MyEclipse的 common 文件夹下建立其“links”文件夹和“spket.link”文件即可。 此时, 我本机的 MyEclipse8.5的目录结构如下图所示.
图 1MyEclipse8.5 的目录结构(Genuitec 为根目录)
本人机器上的MyEclipse8.5 安装完 Spket-1.6.18 后的效果图如下所示:
图 2MyEclipse8.5 中成功安装 Spket 插件
三.配置 Spket-1.6.8
Spket的配置过程与以往的 Spket 的配置过程类似.要注意的是,只有高于 Spket-1.6.17 的版本才识别配置文件。
1. 先下载ext-jsb2.zip, 解压到 ExtJS 3.0 的根目录, 就是和 ext-all.js 在同一级 目录.
2. Window→ Preferences → Spket → JavaScript Profiles → New.
3. 输入 ExtJS,点"OK".
4. 选择 ExtJS, 点"Add Library",在弹出窗口中选择"ExtJS".
5.选择 ExtJS, 点"Add File", 找到 ext.jsb2.
6. 选择 ExtJS,点"Default".
OK,Spket 的安装以及 Ext3.2.1 的配置 都就绪了.
新建一个JS 文件, 用 Open With → Spket Javascript Editor 打开, 测试一下效果吧.
附件1: CreatePluginsConfig.java 文件的内容
importjava.io.File;
importjava.util.ArrayList;
importjava.util.List;
publicclass CreatePluginsConfig {
privateString path;
publicCreatePluginsConfig(String path) {
this.path= path;
}
publicvoid print() {
Listlist = getFileList(path);
if(list == null) {
return;
}
intlength = list.size();
for(int i = 0; i < length; i++) {
Stringresult = "";
StringthePath =getFormatPath(getString(list.get(i)));
Filefile = new File(thePath);
if(file.isDirectory()) {
StringfileName = file.getName();
if(fileName.indexOf("_") < 0) {
continue;
}
String[]filenames = fileName.split("_");
Stringfilename1 = filenames[0];
Stringfilename2 = filenames[1];
result= filename1 + "," + filename2 + ",file:/" + path +"\\"
+fileName + "\\,4,false";
System.out.println(result);
}else if (file.isFile()) {
StringfileName = file.getName();
if(fileName.indexOf("_") < 0) {
continue;
}int last = fileName.lastIndexOf("_");//最后一个下划线的位置
Stringfilename1 = fileName.substring(0, last);
Stringfilename2 = fileName.substring(last + 1,fileName
.length()- 4);
result= filename1 + "," + filename2 + ",file:/" + path +"\\"
+fileName + ",4,false";
System.out.println(result);
}
}
}
publicList getFileList(String path) {
path= getFormatPath(path);
path= path + "/";
FilefilePath = new File(path);
if(!filePath.isDirectory()) {
returnnull;
}
String[]filelist = filePath.list();
ListfilelistFilter = new ArrayList();
for(int i = 0; i < filelist.length; i++){
Stringtempfilename = getFormatPath(path +filelist[i]);
filelistFilter.add(tempfilename);
}
returnfilelistFilter;
}
publicString getString(Object object) {
if(object == null) {
return"";
}
returnString.valueOf(object);
}
publicString getFormatPath(String path) {
path= path.replaceAll("\\\\", "/");
path= path.replaceAll("//", "/");
returnpath;
}
publicstatic void main(String[] args) {
newCreatePluginsConfig("d:\\Programs\\spket-1.6.18\\eclipse\\plugins") .print();//------------
修改!!!!
}
}
从配置中心进行网络中心进行网络安装 附件 2: Myeclipse8.5 中从配置中心进行网络安装 Spket插件
1.Myeclipse8.5 安装插件的界面有很大改变,在 help 菜单中,选 MyeclipseConfiguration Center:
2.在Software 面板中点击“add site”:
3.在弹出的Add Site 输入插件的 name & site 点击完成后会看到自己的插件出现在下面的PersonalSites列表中:
4.选中你要添加的插件名称,右键点击Add to Profile,只选择前两项即可,免费使用的:
5.这时就会看到已添加的插件:
6.点击Pending Changes 窗口中的按钮“apply change”即可开始 update 插件了。 Citefrom:http://bjyzxxds.javaeye.com/blog/657552
方法请自己网络上查找一下!!!!! 但中国大陆的 Ip好像被封锁了,要通过代理! 具体
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: