This repo contains a few scripts that use git to store snapshot of files.
Simply copy the git-snap* files to a ~/bin or add it to your PATH and git should automatically hook it up.
git snapadd target_file [label]
Take a snapshot of the file
git snaplist target_file
List the snapshot available for the file
git snaprestore target_file <hash>
Restore the hash for the file
The snapshot meta data is stored in .file.snapshot, and all the objects are stored in the same .git folder. Note that all snapshot might be deleted when git does their gc, so this should be used for temporary storage.