2007年10月16日
http://ubuntu.dormforce.net/使用說明
打開Software Manager,點擊Edit⇒Software Sources
在Download from中選擇Other
選擇China⇒mirrors.ustc.edu.cn
點擊Choose Server
a wonderful Eclipse plugin:
WindowBuilder, which can be used to develope Swing/SWT UI:
WindowBuilder is built as a plug-in to Eclipse and the various Eclipse-based IDEs (RAD, RSA, MyEclipse, JBuilder, etc.). The plug-in builds an abstract syntax tree (AST) to navigate the source code and uses GEF to display and manage the visual presentation.
Develop Java graphical user interfaces in minutes for Swing, SWT, RCP and XWT with WindowBuilder Pro's WYSIWYG, drag-and-drop interface. Use wizards, editors and intelligent layout assist to automatically generate clean Java code, with the visual design and source always in sync.
The project website: http://www.eclipse.org/windowbuilder/
To install the plugin in Eclipse: http://www.eclipse.org/windowbuilder/download.php
Example:
abc 1000 3452 2463 2343 2176 7654 3452 8765 5643 3452
abc 1000 3452 2463 2343 2176 7654 3452 8765 5643 3452
tas 3420 3562 2123 1343 2176 7654 3252 8765 5643 3452
aer 1000 3452 2463 2343 2176 7654 3452 8765 5643 3452
tas 3420 3562 2123 1343 2176 7654 3252 8765 5643 3452
UNIX:display the no of occurance and the record
> sort f1.txt|uniq -c
2 abc 1000 3452 2463 2343 2176 7654 3452 8765 5643 3452
1 aer 1000 3452 2463 2343 2176 7654 3452 8765 5643 3452
2 tas 3420 3562 2123 1343 2176 7654 3252 8765 5643 3452
display only the duplicate records
> sort f1.txt|uniq -dabc 1000 3452 2463 2343 2176 7654 3452 8765 5643 3452
tas 3420 3562 2123 1343 2176 7654 3252 8765 5643 3452
display distinct records
> sort f1.txt|uniqabc 1000 3452 2463 2343 2176 7654 3452 8765 5643 3452
aer 1000 3452 2463 2343 2176 7654 3452 8765 5643 3452
tas 3420 3562 2123 1343 2176 7654 3252 8765 5643 3452
Reference:
Shell: How To Remove Duplicate Text Lines
Windows:
Notepad++ can sort by line, and remove the duplicate lines at the same time.
- Open the menu under: TextFX-->TextFX Tools
Make sure "sort outputs only unique..." is checked
select a block of text (ctrl-a to select the entire document).
click "sort lines case sensitive" or "sort lines case insensitive"
1.安裝JAVA環境
sudo apt-get install sun-java5-jre
2.下載tomcat: http://tomcat.apache.org/
3.解壓tomcat
$sudo tar zxvf apache-tomcat-7.0.26.tar.gz -C /opt
$sudo mv /opt/apache-tomcat-7.0.26.tar.gz /opt/tomcat
4.啟動tomcat
$sudo /opt/tomcat/bin/startup.sh
如果能看到下列提示,就表明啟動成功了!
>Using CATALINA_BASE: /opt/tomcat
>Using CATALINA_HOME: /opt/tomcat
>Using CATALINA_TMPDIR: /opt/tomcat/temp
>Using JRE_HOME: /usr/lib/j2sdk1.5-sun
打開Firefox,在地址欄中輸入http://localhost:8080,如果出來Tomcat的缺省界面,說明測試通過!
5.停止Tomcat服務
$sudo /opt/tomcat/bin/shutdown.sh
1.下載安裝 RubyInstaller: http://rubyforge.org/frs/?group_id=167&release_id=46588
2. 檢查 RubyGems 版本,須高于 1.3.6
gem -v
3.如果版本不是最新,可以通過下面的命令更新至最新版本:
gem update --system
gem uninstall rubygems-update
4.安裝 Rails:
gem install rails
1.按照github上的指南配置(
http://help.github.com/win-set-up-git/)基礎的git環境。
2.在github上創建一個Repository。
3.在Eclipse中通過“Eclipse Marketplaces”,在Market Places里安裝egit。
4.在Eclipse中生public key, 并添加到GitHub Repository中。
Eclipse中通過:performance -> SSH2 -> Key Management -> Gernerate RSA Key 生成 SSH 的 public key。
在GitHub中通過:edit your profile -> ssh key -> Add SSH Key 添加SSH Key, 把上面生成的 public key 拷貝到這里,保存。
5.Eclipse里File菜單,Import,即可從git導入剛添加到git的項目了。
6.修改,并提交。在項目上點右鍵–>team–>commit。commit是commit到本機的git庫,而push才是同步到github。
1.下載最新版 Eclipse:
官方下載:http://www.eclipse.org/downloads/
2.解壓下載的壓縮包:
$sudo tar xvfz eclipse-SDK-3.1.2-linux-gtk.tar.gz -C /opt
這個時候,就可以在 /opt 文件夾中看到出現了一個eclipse的文件夾,雙擊其中的eclipse文件就可以運行eclipse了。
3.在菜單設置Eclipse選項: $gedit ~/.local/share/applications/eclipse-user.desktop
插入一下內容:
[Desktop Entry]
Comment=Java IDE
Name=Eclipse
Exec=/opt/eclipse/eclipse
Encoding=UTF-8
Terminal=false
Type=Application
Categories=Application;Development;
Icon=/opt/eclipse/icon.xpm
方法1: 用SET PASSWORD命令
mysql -u root
mysql> SET PASSWORD FOR 'root'@'localhost' = PASSWORD('newpass');
方法2:用mysqladmin
mysqladmin -u root password "newpass"
如果root已經設置過密碼,采用如下方法
mysqladmin -u root password oldpass "newpass"
方法3: 用UPDATE直接編輯user表
mysql -u root
mysql> use mysql;
mysql> UPDATE user SET Password = PASSWORD('newpass') WHERE user = 'root';
mysql> FLUSH PRIVILEGES;
方法4: 在丟失root密碼的時候,可以這樣
mysqld_safe --skip-grant-tables&
mysql -u root mysql
mysql> UPDATE user SET password=PASSWORD("new password") WHERE user='root';
mysql> FLUSH PRIVILEGES;
---------------------------------------
經測試,方法三修改成功,其他三種方法沒有測試。
一.問題環境:
Eclipse3.4 + Tomcat6.0.20
二.問題現象:
在Eclipse下啟動Tomcat6時,控制臺會有下面警告信息
警告: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:...' did not find a matching property.
三.詳細解決辦法:
1.打開服務器視圖:窗口 > 顯示視圖 > 服務器 > 服務器
2.雙擊服務器列表中的Tomcat,打開“服務器概述”窗口
3.選中"Publish module contexts to separate XML files"選項。
小提示:如果Tomcat處于啟動狀態,請先停止,否則,在保存服務器設置時,提示不能保存。
Here is a simple way to generate a analyze report by using FindBugs plugins in RSA:
- Using FindBugs to scan the code and save the result as XML file
- the XML report is in a bad format for reading, we can use XSL file to make it easy and clear to read:
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="summary.xsl"?>
- Use Internet Explore to open the XML report, now we get a report:
Note: FindBugs provided following xsl files for different format: 1、default.xsl;
2、fancy.xsl;
3、fancy-hist.xsl;
4、plain.xsl;
5、summary.xsl;
摘要: GZIP
1. Compressing a File in the GZIP Format
2. Uncompressing a File in the GZIP Format
ZIP
1. Creating a ZIP File
2. Listing the Contents of a ZIP File
3. Retrieving a Compressed File from a ZIP File
閱讀全文
摘要: 使用 JSEclipse,JavaScript 程序員現在有了自己的 Eclipse 插件,該插件將提供許多重要功能來輔助開發 JavaScript 應用程序。像 Eclipse 多年來為 Java? 語言和其他語言提供了易用性一樣,JSEclipse 為 JavaScript 開發人員提供了同樣的優點。
閱讀全文
分享一個不錯的編寫properties文件的Eclipse插件(plugin),有了它我們在編輯一些簡體中文、繁體中文等
Unicode文本時,就不必再使用native2ascii編碼了。您可以通過Eclipse中的軟件升級(Software
Update)安裝此插件,步驟如下:
1、展開Eclipse的Help菜單,將鼠標移到Software Update子項,在出現的子菜單中點擊Find and Install;
2、在Install/Update對話框中選擇Search for new features to install,點擊Next;
3、在Install對話框中點擊New Remote Site;
4、在New Update Site對話框的Name填入“PropEdit”或其它任意非空字符串,在URL中填入http://propedit.sourceforge.jp/eclipse/updates/;
5、在Site to include to search列表中,除上一步加入的site外的其它選項去掉,點擊Finsih;
6、在彈出的Updates對話框中的Select the features to install列表中將所有結尾為“3.1.x”的選項去掉(適用于Eclipse 3.2版本的朋友);
7、點擊Finish關閉對話框;
8、在下載后,同意安裝,再按提示重啟Eclipse,在工具條看到形似vi的按鈕表示安裝成功,插件可用。此時,Eclpise中所有properties文件的文件名前有綠色的P的圖標作為標識。
摘要: 在Eclipse中遇到The type XXX cannot be resolved. It is indirectly referenced from required .class files錯誤.....,查找的解決辦法如下:
閱讀全文