Mercurial > hg-stable
changeset 23606:80e3cbe227d1
namespaces: add method to get template name of namespace
This patch adds the public api for getting the template name of a namespace so
that the next patch can use it to generate a template keyword automatically.
author | Sean Farley <sean.michael.farley@gmail.com> |
---|---|
date | Sun, 14 Dec 2014 19:12:27 -0800 |
parents | 4c4c967814ef |
children | 0fd778ef0f61 |
files | mercurial/namespaces.py |
diffstat | 1 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/namespaces.py Mon Dec 15 00:09:52 2014 -0800 +++ b/mercurial/namespaces.py Sun Dec 14 19:12:27 2014 -0800 @@ -84,3 +84,7 @@ return cl.node(maxrev) return n[0] raise KeyError(_('no such name: %s') % name) + + def templatename(self, namespace): + """method that returns the template name of a namespace""" + return self._names[namespace]['templatename']