我有配置文件:conf/local.conf
我为它运行下一个命令:
git update-index --assume-unchanged local.conf
在我切换到另一个分支或拉之前没关系。
如何--assume-unchanged
在分支之间保留标志?
UPD
即将发生的一些示例:
$ git checkout 296-ToS-component
error: Your local changes to the following files would be overwritten by checkout:
conf/local.conf
Please commit your changes or stash them before you switch branches.
Aborting
$ git checkout -f 296-ToS-component
error: Entry 'conf/local.conf' not uptodate. Cannot merge.
我希望它像下一个一样工作:
- conf/local.conf 被保存
- 分支已切换
- conf/local.conf 被保存的版本替换