Is there a way to make TortoiseSVN temporarily ignore versioned files?

后端 未结 3 642
后悔当初
后悔当初 2021-01-07 01:33

We have certain configuration files which we want to be in version control as they specify project\'s default settings: search path, conditional defines etc. Unfortunately t

3条回答
  •  灰色年华
    2021-01-07 02:11

    The general solution to allowing local modifications to version-controlled configuration files is not to keep the config file itself under version control, but to version a template of it, e.g. with .template appended to the filename.

    The first time a developer checks out the project, they make a copy of this file, removing the .template from the filename of the copy. Then they add the copy (the non-template) to the ignore list to ensure it is not accidentally added or committed.

    Any changes that are made to the config which need to go into version control, must be made to the template. And each time a developer updates and finds a change in the template, they must again follow the copy/rename procedure. But hopefully this will not be often.

提交回复
热议问题