WHAT'S IN THIS CHAPTER?
Taking snapshots of your entire project
Reviewing snapshots and comparing them with your working files
Managing and restoring snapshots
If you're like me, you hate to throw away code. Most code, especially the stuff that works, is a hard-won commodity that represents time, effort, expertise, and creativity. The best way to improve your code, however, is to experiment with new approaches — which often means abandoning or discarding the code you've already written. Making copies of your source files or saving snippets of old code as comments is both awkward and time consuming. Enter snapshots. Snapshots let you have it both ways: you can keep your existing code while simultaneously replacing it with new, experimental code.
In simple terms, a snapshot is an archived copy of the source files in your project. It quickly preserves their current state so you are free to make changes to your project — even radical ones — secure in the knowledge that you can always revert back to the saved version at any time. You can make as many snapshots as you like. You can easily see what changes you've made, as shown in Figure 11-1, by comparing your working project files to those in a snapshot. You can revert your changes to any previous snapshot on a change-by-change basis, by file, or perform a wholesale restore of the entire project.
Figure 11-1. FIGURE 11-1 ...