Mercurial > piecrust2
comparison piecrust/commands/builtin/info.py @ 168:56d6b17e057b
routes: Show regex patterns for routes.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Sat, 03 Jan 2015 18:06:34 -0800 |
parents | 4534ccbdd2a3 |
children | 869a206facd5 |
comparison
equal
deleted
inserted
replaced
167:0a1736ef740d | 168:56d6b17e057b |
---|---|
77 def run(self, ctx): | 77 def run(self, ctx): |
78 for route in ctx.app.routes: | 78 for route in ctx.app.routes: |
79 logger.info("%s:" % route.uri_pattern) | 79 logger.info("%s:" % route.uri_pattern) |
80 logger.info(" source: %s" % route.source_name) | 80 logger.info(" source: %s" % route.source_name) |
81 logger.info(" taxonomy: %s" % (route.taxonomy or '')) | 81 logger.info(" taxonomy: %s" % (route.taxonomy or '')) |
82 logger.info(" regex: %s" % route.uri_re.pattern) | |
82 | 83 |
83 | 84 |
84 class ShowPathsCommand(ChefCommand): | 85 class ShowPathsCommand(ChefCommand): |
85 def __init__(self): | 86 def __init__(self): |
86 super(ShowPathsCommand, self).__init__() | 87 super(ShowPathsCommand, self).__init__() |