My rules are:
- there needs to be a single command that sets up the environment after a checkout
- files under version control may not change during execution of the setup command or a build.
The weaker rules are:
- there should be no redundant information in version-controlled files
- making changes leads to a minimal difference
I have per-file-type filters configured that normalize the files before check-in. For QuartusII, these are:
- .qpf and .qsf have the datestamp removed. These load just fine, and Quartus just writes a new one, which is then removed again on the next checkin.
- .qsf is run through a normalization step (Quartus has an explicit "save normalized project file" command).
- .vhd files containing IP megafunctions are reduced to the recovery information comments, and regenerated by the setup script.
- .qip files are ignored (these are regenerated along with the megafunction)
Granted, there is an initial overhead, and this is difficult to set up, but this allows me to review individual commits as diffs easily.
Introducing these filters later on is possible by git filter-branch
, so I wouldn't let that impede development and just check in everything until filters are in place.