在Mercurial中,"hg重命名"表示可以,但是历史记录不遵循文件? [英] In Mercurial, "hg rename" works but the history doesn't follow the file?

查看:50
本文介绍了在Mercurial中,"hg重命名"表示可以,但是历史记录不遵循文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我记得在SVN中,我可以将文件从foo.txt重命名为foo2.txt,所有历史记录都将跟随(foo2.txt的日志文件也将显示foo.txt的所有历史记录).但是在Mercurial上似乎并非如此.完成hg rename后,hg log foo2.txt将不显示任何以前的foo.txt历史记录吗?有办法解决吗?

I remember in SVN, I can rename a file from foo.txt to foo2.txt and all the history will follow (log file of foo2.txt will show all history of foo.txt as well). But on Mercurial, seems like that's not the case. When a hg rename is done, then hg log foo2.txt will not show any previous history of foo.txt? Is there a way around it?

推荐答案

使用hg log --follow foo2.txthg log -f foo2.txt(缩写形式)向您显示hg rename

Use hg log --follow foo2.txt or hg log -f foo2.txt (short form) to show you the entire history of the file before the hg rename

这篇关于在Mercurial中,"hg重命名"表示可以,但是历史记录不遵循文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆