2

I am planning to move the central repo, I want to display an error message to anyone that is trying to use: hg pull and tell them the new location of the repo. I wrote a hook that uses events, but none of the events are triggering if someone uses: hg pull

pulling over HTTP any ideas??

4

1 回答 1

5

ssg 的答案非常简单,这是一种基于preoutgoing hook的更简单的方法。你需要把它放在你.hg/hgrc的远程存储库中。

[hooks]
preoutgoing = echo "Repository moved to <url>"
于 2013-09-05T17:20:17.777 回答