CFEclipse Features: Local History

 
Nov 15, 2006

by Robert Blackburn

Ever open a file you've been working on and spent the first few minutes just trying to remember what changes you made the night before? Or ever wish you could just undo the last few days' changes? In this installment of CFEclipse Features, we will take a look at a feature that allows you to do just that.

CFEclipse actually automatically stores the history of a file locally. To view this history, simply right click on the file on the Navigator panel, or right click on an open file, and select "Compare With". Then select the "Local History?" option. This will bring up the history window, as shown in figure 1.

Figure1
Figure 1

You can select any moment in time and it will display the differences between that moment in history, and the current version of the file.

Want to replace the current version of the file with a previous version? Simply right click the file and select "Replace With" instead of "Compare With". Once again select the "Local History" option. You will see a window just like the comparison window, except there is not a "Replace" button.

Eclipse will only keep one week's worth of history by default. But you can increase that if you like. To do this, click "Window" > "Preferences". Then select "General" > "Workspace" > "Local History". There are a number of settings that determine how much history is stored and for how long, all of which can be increased.

Figure2
Figure 2

This feature is a great complement to a source control system like CVS or Subversion, and more then once has saved me hours of work. In the next installment of CFEclipse Features, we will take a look at the scribble pad feature.


Robert Blackburn is a developer and team leader of the Internet Application Development team at American Power Conversion Corporation (http://www.apcc.com). He has been using ColdFusion since 1999, and has revived and manages the CFUnit open source project (http://cfunit.sourceforge.net). He currently has a blog at http://www.rbdev.net/devblog for his occasional ramblings.

Add a Comment
(If you subscribe, any new posts to this thread will be sent to your email address.)
  
Privacy | FAQ | Site Map | About | Guidelines | Contact | Advertising | What is ColdFusion?
House of Fusion | ColdFusion Jobs | Blog of Fusion | AHP Hosting