Both these protocols normally use the SSH (Secure Shell) protocol to communicate with the CVS server, meaning that your passwords and data are safe from eavesdroppers (although :ext: can be configured to use other protocols as well).
The difference is that :ssh: uses an SSH client built into CVSNT, while :ext: relies on an external SSH client.
If you use CVS from the command line, :ssh: has the advantage that you do not need any other software. Since TortoiseCVS already comes with its own SSH client, there is nothing gained from preferring :ssh:. Additionally, at least some versions of CVSNT have problems communicating with non-CVSNT servers, such as those used on the majority of UNIX servers.
Another important point is that it is not possible to configure :ssh: to use another port etc. in the Preferences dialog of TortoiseCVS. That dialog applies only to :ext:. Therefore, we recommend that you always use :ext: instead of :ssh:.
How do I tell if my computer can run a 64-bit version of Windows?
How do I tell if my computer can run a 64-bit version of Windows?
To run a 64-bit version of Windows, your computer must have a 64-bit-capable processor. To find out if your processor is 64-bit-capable, do the following:
- Open Performance Information and Tools by clicking the Start button , clickingControl Panel, clicking System and Maintenance, and then clickingPerformance Information and Tools.
- Click View and print details.
- In the System section, you can see what type of operating system you're currently running under System type. Under 64-bit capable, you can see whether you can run a 64-bit version of Windows. (If your computer is already running a 64-bit version of Windows, you won't see the 64-bit capable listing.)
Labels:
Windows7
How to make a bootable Windows 7 USB installer with CMD:
How to make a bootable Windows 7 USB installer with CMD:
ThinkPad T400S, hit F1 enter BIOS.
Make sure put USB HDD as the first priority of start up.
- Open and run CMD as Administrator.
- Type Diskpart, press Enter.
- Type List Disk, press Enter.
- Type Select Disk # (where # is the number your USB drive shows up as), press Enter.
- Type Clean, press Enter.
- Type Create Partition Primary, press Enter.
- Type Active, press Enter.
- Type Format Quick FS=FAT32, press Enter.
- Type Assign, press Enter.
- Type Exit, press Enter.
- Copy everything from the Windows 7 installation DVD onto the USB key (a simple drag and drop will do; if you have an .iso extract or mount first).
Make sure put USB HDD as the first priority of start up.
Labels:
Windows7
Base 64 Encoidng and Decoding
import sun.misc.BASE64Decoder; import sun.misc.BASE64Encoder; import org.apache.commons.codec.binary.Base64; String strTobeEncoded = "This is message body which will be 64 encoded"; String strTobeDecoded = "VGhpcyBpcyBtZXNzYWdlIGJvZHkgd2hpY2ggd2lsbCBiZSA2NCBlbmNvZGVk"; String encodedResult = ""; String decodedResult = ""; try { // encoding using sun.misc.BASE64Encoder; BASE64Encoder encoder = new BASE64Encoder(); encodedResult = encoder.encode(strTobeEncoded.getBytes()); System.out.println("Encoded by Sun's encoder: " + encodedResult); // decoding using sun.misc.BASE64Encoder; BASE64Decoder decoder = new BASE64Decoder(); decodedResult = new String(decoder.decodeBuffer(strTobeDecoded)); System.out.println("Decoded by Sun's decoder: " + decodedResult); // encoding using org.apache.commons.codec.binary.Base64; encodedResult = new String(Base64.encodeBase64(strTobeEncoded.getBytes())); System.out.println("Encoded by Apache's encoder: " + encodedResult); // encoding using org.apache.commons.codec.binary.Base64; decodedResult = new String(Base64.decodeBase64(strTobeDecoded.getBytes())); System.out.println("Decoded by Apache's decoder: " + decodedResult); } catch (Exception e) { }
Target runtime SpringSource tc Server Developer Edition (Runtime) v2.1 is not defined.
Solutions:
1. Delete the server
2. Recreate the server: create new instance, choose template insight.
3. Right click the project, find "Targeted Runtimes", removed the old one.
1. Delete the server
2. Recreate the server: create new instance, choose template insight.
3. Right click the project, find "Targeted Runtimes", removed the old one.
Eclipse SSH and extssh
A couple of days ago, I found I could not use Tortoise CVS to work with CVS repository, after I replacing all "extssh" with "ext" in all Root, it's working.
Today, I found Eclipse is not working with CVS repository, and here is the fix:
Preferences->Team->CVS->Ext connection Method->Choose "Use another connection method type to connect", and select Connection type as "extssh".
Today, I found Eclipse is not working with CVS repository, and here is the fix:
Preferences->Team->CVS->Ext connection Method->Choose "Use another connection method type to connect", and select Connection type as "extssh".
Using DropBox to Host Your Code
I wrote some Flex applications, and would like to post them into my Blog. First, I tried to use Google Docs, there is no problem to upload the folder, but Google Docs seems not let you have the link to the file. Then I tried DropBox's Public folder, wow, it's unbelievably easy, just drag and drop the release version of the Flex application to Public folder, then select the main html file, and right click, DropBox->Copy Public Link, now you have the web link to that file.
Next, just copy the following to my blog, and I am all set.
Next, just copy the following to my blog, and I am all set.
Get Lapsed Time in Java
long startTime = System.currentTimeMillis(); System.out.println("start getting super session: " + startTime); long endTime = System.currentTimeMillis(); System.out.println("end getting super session: " + endTime); System.out.println("time taken in seconds: " + (endTime - startTime)/1000); System.out.println("time taken in mill seconds: " + (endTime - startTime));
Labels:
Java
SimpleDateFormat
Letter | Date or Time Component | Presentation | Examples |
---|---|---|---|
G | Era designator | Text | AD |
y | Year | Year | 1996 ; 96 |
M | Month in year | Month | July ; Jul ; 07 |
w | Week in year | Number | 27 |
W | Week in month | Number | 2 |
D | Day in year | Number | 189 |
d | Day in month | Number | 10 |
F | Day of week in month | Number | 2 |
E | Day in week | Text | Tuesday ; Tue |
a | Am/pm marker | Text | PM |
H | Hour in day (0-23) | Number | 0 |
k | Hour in day (1-24) | Number | 24 |
K | Hour in am/pm (0-11) | Number | 0 |
h | Hour in am/pm (1-12) | Number | 12 |
m | Minute in hour | Number | 30 |
s | Second in minute | Number | 55 |
S | Millisecond | Number | 978 |
z | Time zone | General time zone | Pacific Standard Time ; PST ; GMT-08:00 |
Z | Time zone | RFC 822 time zone | -0800 |
Labels:
Java
must override a superclass method
I just did an update from Mercurial, and I found one of the class having compilation error on one of the method.
XXXXX must override a superclass method
I do notice that method has an annotation called "@Override". A quick search, I found that's because my Eclipse's compilation level is set as 1.5.
Preferences->Java->Compiler
Make sure Compiler compliance level set as 1.6
XXXXX must override a superclass method
I do notice that method has an annotation called "@Override". A quick search, I found that's because my Eclipse's compilation level is set as 1.5.
Preferences->Java->Compiler
Make sure Compiler compliance level set as 1.6
DropBox + Mercurial: A perfect solution for code development
Ever had the problem copying codes over from one machine to another, most likely, home vs work? DropBox solved the problem syncing the codes between different machines, while Mercurial (without Push) provides version control abilities.
Labels:
Mercurial
Changes between different Java JDK
Last week, one of my colleague told me that there is some compilation error in his project, while I checked mine, I have no problem, then quickly I found the problem: I am using JDK 1.6, while he is using 1.5. The culprit is a method from String class isEmpty(), which is a total new method at JDK 1.6, this incident prompts me to think if there is way to quickly find out the changes between different JDK.
I found this link , which shows differences between between 5.0 fcs and 6 Beta.
1.6
1.7
I found this link , which shows differences between between 5.0 fcs and 6 Beta.
1.6
1.7
Labels:
Java
DBVisualizer
I just found something that I didn't know about DBVisualizer
1. For selected table, we could sort the order of columns by clicking "Grid Column Chooser", and we could also customized which columns to be visible or not. And the customized columns will be kept until we close DBVisualizer, it would be really nice if the customized columns could be saved even if we close the application.
2. DBVisualizer also provides type as search function in many aspects.
3. We could also filter on table name in DBVisualizer, but it would be really nice if this is could be done by type as search.
1. For selected table, we could sort the order of columns by clicking "Grid Column Chooser", and we could also customized which columns to be visible or not. And the customized columns will be kept until we close DBVisualizer, it would be really nice if the customized columns could be saved even if we close the application.
2. DBVisualizer also provides type as search function in many aspects.
3. We could also filter on table name in DBVisualizer, but it would be really nice if this is could be done by type as search.
Labels:
DBVisualizer
Get current user name in Flex
package { import flash.filesystem.File; public class UserUtil { public static function get currentOSUser():String { var userDir:String = File.userDirectory.nativePath; var userName:String = userDir.substr(userDir.lastIndexOf(File.separator) + 1); return userName; } } }
Labels:
Flex
Get current user name and machine name in Java
System.out.println(System.getProperty("user.name")); java.net.InetAddress localMachine = java.net.InetAddress.getLocalHost(); System.out.println(localMachine.getHostName());
Labels:
Java
Cannot load 64-bit SWT libraries on 32-bit JVM in Eclipse
Let's end this once for all.
You got this problem is because you are using 64bits Eclipse, but your ant target is using 32bit JDK.
It's OK to use 32bit JDK in Eclipse, but you'll have problem when your ant need some GUI prompt, at this point, it will call Eclipse to generate this GUI prompt which is 64 bits, and now we'll have problem.
Solutions:
1. Use 32bit Eclipse
2. For those ant targets which require GUI prompt, change JRE to 64bits JDK.
You got this problem is because you are using 64bits Eclipse, but your ant target is using 32bit JDK.
It's OK to use 32bit JDK in Eclipse, but you'll have problem when your ant need some GUI prompt, at this point, it will call Eclipse to generate this GUI prompt which is 64 bits, and now we'll have problem.
Solutions:
1. Use 32bit Eclipse
2. For those ant targets which require GUI prompt, change JRE to 64bits JDK.
Labels:
Java
XStream Notes
Using xstream-1.4.2.jar, and got the following problem:
Exception in thread "main" java.lang.NoClassDefFoundError: org/xmlpull/v1/XmlPullParserException
at com.thoughtworks.xstream.XStream.<init>(XStream.java:336)
at com.hempire.xstream.Writer.main(Writer.java:22)
The XML Pull Parser API defines an own mechanism to load the factory for the available XPP (XML Pull Parser) implementation. XStream's XppDriver never used this lookup mechanism automatically before version 1.4, now it will. Therefore you will have to add a dependency to xmlpull if the XPP implementation does not deliver the classes on its own. This dependency is necessary for Xpp3 in contrast to kXML2 that contains the classes. Use the Xpp3Driver or the KXml2Driver if you want to select one of the directly supported XPP implementation on your own without using the XPP factory. Note, that the minimal version of kXML2 does not support the XPP factory, but can be used by the KXml2Driver.
I honestly don't understand what the above means, but the bottom line is if we include any of the following jars, you should be fine:
kxml2-2.3.0.jar
kxml2-min-2.3.0.jar
xmlpull-1.1.3.1.jar
xpp3_min-1.1.4c.jar
kXML2 is recommend for use as it will greatly improve the performance of XStream.
Supported XML parsers and packages:
Exception in thread "main" java.lang.NoClassDefFoundError: org/xmlpull/v1/XmlPullParserException
at com.thoughtworks.xstream.XStream.<init>(XStream.java:336)
at com.hempire.xstream.Writer.main(Writer.java:22)
The XML Pull Parser API defines an own mechanism to load the factory for the available XPP (XML Pull Parser) implementation. XStream's XppDriver never used this lookup mechanism automatically before version 1.4, now it will. Therefore you will have to add a dependency to xmlpull if the XPP implementation does not deliver the classes on its own. This dependency is necessary for Xpp3 in contrast to kXML2 that contains the classes. Use the Xpp3Driver or the KXml2Driver if you want to select one of the directly supported XPP implementation on your own without using the XPP factory. Note, that the minimal version of kXML2 does not support the XPP factory, but can be used by the KXml2Driver.
I honestly don't understand what the above means, but the bottom line is if we include any of the following jars, you should be fine:
kxml2-2.3.0.jar
kxml2-min-2.3.0.jar
xmlpull-1.1.3.1.jar
xpp3_min-1.1.4c.jar
kXML2 is recommend for use as it will greatly improve the performance of XStream.
Supported XML parsers and packages:
- XmlPull, the XML pull parser API and factory to detect available implementations.
- Xpp3, an XML pull parser (recommended).
- kXML2 or kXML2-min, an XML pull parser.
- DOM4J, easy XML representation and manipulation framework.
- JDOM, easy XML representation and manipulation.
- StaX, the reference implementation of the Streaming API for XML.
- Woodstox, an alternate open source StaX implementation.
- XOM, another alternative XML API.
Labels:
xstream
Get to Jira (or any web) quick from cygwin
1. Put the following in .bashrc:
export jira="https://jira.dovetail.net/browse/BUG-"2. Make it effective:
source .bashrc3. under /home/hliu/bin, create file named as "jira":
cygstart "$jira$1"4. Make it executable:
dos2unix jira chmod 755 jira5. Now from cygwin, you could type:
Labels:
Cygwin
Subscribe to:
Posts (Atom)