Version Control Support
CodeSmith Generator is designed to fit into projects under version control, including systems that use exclusive check-outs, such as Team Foundation Version Control (TFVC).
Unchanged files stay untouched
When the content Generator produces is exactly the same as the existing file, Generator doesn't write the file. Its contents and modified date stay the same, so regenerating a project doesn't make your version control system check out or flag hundreds of files that didn't really change. Only files whose content actually changed show up as modified.
Check-outs in Visual Studio
When you work in Visual Studio, Generator checks files out of source control before it edits them:
- When you change a Generator project file, the project file is checked out.
- When you generate from a Generator project, the output files are checked out before they're written.
Source control in Template Explorer
Template Explorer includes your Windows Explorer context menus. If you use a source control client that adds commands to those menus, such as TortoiseGit or TortoiseSVN, you can update, commit and run its other commands on your templates directly from Template Explorer.