I have an repository for an app that I\'m working on that includes a configuration file. Currently, I distribute with a .dist
extension, and have the user rename th
You can also version and distribute:
.gitattributes
files declaring a filter driver (for only 'config.dist')config
file)Now that is bending a bit what a filter driver is about (it is about modifying the content of a file, regardless of its "state", i.e its full path and name). But it can work.
The .gitattributes
would contain:
config.dist filter=generateConfig
And you can register your smudge script (applied during the checkout step when creating/updating the working directory) like:
git config --global filter.generateConfig.smudge /path/to/generateConfig