Mercurial > piecrust2
comparison piecrust/plugins/builtin.py @ 187:d5b7c2a4ec9d
prepare: Add user-defined scaffolding templates.
Any files found in `scaffold/pages` will be used as possible templates for
the `chef prepare` command, in addition to the default ones.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Sun, 04 Jan 2015 15:49:31 -0800 |
parents | 139179dc7abd |
children | 154b8df04829 |
comparison
equal
deleted
inserted
replaced
186:e61fbae61402 | 187:d5b7c2a4ec9d |
---|---|
5 RootCommand, ShowConfigCommand, | 5 RootCommand, ShowConfigCommand, |
6 FindCommand, ShowSourcesCommand, ShowRoutesCommand, ShowPathsCommand) | 6 FindCommand, ShowSourcesCommand, ShowRoutesCommand, ShowPathsCommand) |
7 from piecrust.commands.builtin.scaffolding import ( | 7 from piecrust.commands.builtin.scaffolding import ( |
8 PrepareCommand, | 8 PrepareCommand, |
9 DefaultPrepareTemplatesCommandExtension, | 9 DefaultPrepareTemplatesCommandExtension, |
10 UserDefinedPrepareTemplatesCommandExtension, | |
10 DefaultPrepareTemplatesHelpTopic) | 11 DefaultPrepareTemplatesHelpTopic) |
11 from piecrust.commands.builtin.serving import (ServeCommand) | 12 from piecrust.commands.builtin.serving import (ServeCommand) |
12 from piecrust.commands.builtin.util import ( | 13 from piecrust.commands.builtin.util import ( |
13 InitCommand, PurgeCommand, ImportCommand) | 14 InitCommand, PurgeCommand, ImportCommand) |
14 from piecrust.data.provider import (IteratorDataProvider, BlogDataProvider) | 15 from piecrust.data.provider import (IteratorDataProvider, BlogDataProvider) |
54 ServeCommand()] | 55 ServeCommand()] |
55 | 56 |
56 def getCommandExtensions(self): | 57 def getCommandExtensions(self): |
57 return [ | 58 return [ |
58 DefaultPrepareTemplatesCommandExtension(), | 59 DefaultPrepareTemplatesCommandExtension(), |
60 UserDefinedPrepareTemplatesCommandExtension(), | |
59 DefaultPrepareTemplatesHelpTopic()] | 61 DefaultPrepareTemplatesHelpTopic()] |
60 | 62 |
61 def getSources(self): | 63 def getSources(self): |
62 return [ | 64 return [ |
63 DefaultPageSource, | 65 DefaultPageSource, |