In mercurial, how do I apply a reverse-patch to a particular file?

前端 未结 3 1531
感情败类
感情败类 2021-02-04 02:24

Related to Mercurial: Merging one file between branches in one repo , I\'m trying to perform a backout operation on a single file, even though that file was one of many particip

3条回答
  •  南笙
    南笙 (楼主)
    2021-02-04 03:11

    Use the revert command.

    hg revert -r1 file
    

    This should revert the contents of file to the version in revision 1. You can then further edit it and commit as normal.

提交回复
热议问题