treecomp.py compares two directory trees and identifies differences between them. It is designed with a single purpose in mind, and this is comparing the PhoneBook template tree to the re-motion template tree.

Modifying/debugging templates is usually done in the PhoneBook template tree and migrated to the re-motion
template tree after completion. With treecomp.py you can

Assumptions

treecomp.py is based on the following assumptions:

In the future, these assumptions might break. treecomp.py is not very useful if you want to migrate files in the other direction – from the re-motion template tree to the PhoneBook template tree.

Workings

treecomp.py reports only two types of differences:

It does not report

If treecomp.py finds files in the old template tree that are not present in the new template tree, it will throw an exception with the list of files not found in the first directory where this is the case.

treecomp.py prints a batch (.cmd) file of copy-commands to stdout. You can pipe this output to a batch file, inspect and change it with your favorite editor or not, and run that batch file to update the re-motion template tree from the PhoneBook template tree.

This output has three sections:

What about subversion directories (".svn")?

.svn directories in both template trees are ignored and not compared.