这是另一种更直接的方法.
for f in `hg locate`; do hg log -r "first(follow('$f'))" --template "$f: {author}\n"; done
Run Code Online (Sandbox Code Playgroud)
翻译:
for each file
follow its history to the beginning
print the filename and author
Run Code Online (Sandbox Code Playgroud)
要简单地获取Bob首先介绍的文件列表:
for f in `hg locate`; do hg log -r "first(follow('$f')) and author(bob)" --template "$f\n"; done
Run Code Online (Sandbox Code Playgroud)