SVN: Ignoring an already committed file

前端 未结 6 1786
心在旅途
心在旅途 2020-12-14 17:30

I have a settings file that is under version control using subversion. Everybody has their own copy of this file, and I need this not to be ever committed. However, like I s

6条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-14 17:50

    If you remove the file from version control, how does a developer new to the project (or the one who accidentally deleted his local copy) get it after initial checkout? What if there are additions to the settings file?

    I would suggest the following: Keep a default settings file (with no passwords, hostnames, connection strings, etc.) in SVN, name it something like settings.dist, and let the code work with a copy of this, named settings. Every developer has to make this copy once, and can then work with her personalized settings. If there are additions, add them to settings.dist – everyone else will get them with a update and can merge then into her personalized copy.

提交回复
热议问题