mercurial/templatekw.py
changeset 36247 48a6b1a22ccf
parent 36110 230489fc0b41
child 36401 d65642840c6f
--- a/mercurial/templatekw.py	Sun Jan 07 12:09:33 2018 +0900
+++ b/mercurial/templatekw.py	Mon Jan 08 11:11:06 2018 +0900
@@ -726,6 +726,11 @@
                    lambda x: {'ctx': repo[x], 'revcache': {}},
                    lambda x: scmutil.formatchangeid(repo[x]))
 
+@templatekeyword('reporoot')
+def showreporoot(repo, **args):
+    """String. The root directory of the current repository."""
+    return repo.root
+
 @templatekeyword("successorssets")
 def showsuccessorssets(repo, ctx, **args):
     """Returns a string of sets of successors for a changectx. Format used