zendframework/zf2 — pull request #3106 by Hounddog (2012-11-29 18:37:54+00:00)
Title: Added template map generator

I have basically copied the classmap generator for this. Need to still clean it up but wanted to know if it was something required. I just think that if you have many templates it is tedious to write a template map manually for every template... Same as writing a classmap.

Module Config example

'view_manager' => array(
'template_path_stack' => array(
__DIR__ . '/../view',
),
'template_map' => include __DIR__ . '../template_map.php',
),

To generate a classmap you can then just call php templatemap_generator.php from the root of your module and by default it would map all the templates within view.

I have also added the option to specify where the views are so you can also provide the library path aswell as the view path to generate the template map.

--view viewpath