Local git repo force updated from a remote git repo. (thick-client deployments)

后端 未结 5 646
暖寄归人
暖寄归人 2021-01-15 05:46

Update: I think this is related to an issue with the windows git client msysgit. Sorry to trouble you guys. http://code.google.com/p/msysgit/issues/detail?i

5条回答
  •  星月不相逢
    2021-01-15 06:00

    The following two commands should reset the client's working tree to a clean state, i.e. identical to how it was following the preceding git clone:

    git reset --hard HEAD
    

    This will undo any modifications made to files which are tracked (i.e. which exist in the repo).

    git clean -fdx
    

    This will remove any files which have been newly created by the client, i.e. which are not tracked by git.

提交回复
热议问题