Mercurial > piecrust2
comparison piecrust/plugins/builtin.py @ 1114:8af2ea1f5c34
tasks: Add new `tasks` command and infrastructure, with `mention` task.
* The new command lets `chef` run tasks from a queue.
* The webmention endpoint now adds a mention task.
* Moved mention handling code to a task runner.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Thu, 22 Feb 2018 22:12:45 -0800 |
parents | 8178671f9a04 |
children | 986ecdaa2a36 |
comparison
equal
deleted
inserted
replaced
1113:29c51b981c17 | 1114:8af2ea1f5c34 |
---|---|
15 ShowPathsCommand) | 15 ShowPathsCommand) |
16 from piecrust.commands.builtin.plugins import PluginsCommand | 16 from piecrust.commands.builtin.plugins import PluginsCommand |
17 from piecrust.commands.builtin.publishing import PublishCommand | 17 from piecrust.commands.builtin.publishing import PublishCommand |
18 from piecrust.commands.builtin.scaffolding import PrepareCommand | 18 from piecrust.commands.builtin.scaffolding import PrepareCommand |
19 from piecrust.commands.builtin.serving import ServeCommand | 19 from piecrust.commands.builtin.serving import ServeCommand |
20 from piecrust.commands.builtin.tasks import TasksCommand | |
20 from piecrust.commands.builtin.themes import ThemesCommand | 21 from piecrust.commands.builtin.themes import ThemesCommand |
21 from piecrust.commands.builtin.util import ( | 22 from piecrust.commands.builtin.util import ( |
22 InitCommand, PurgeCommand, ImportCommand) | 23 InitCommand, PurgeCommand, ImportCommand) |
23 | 24 |
24 return [ | 25 return [ |
37 PluginsCommand(), | 38 PluginsCommand(), |
38 BakeCommand(), | 39 BakeCommand(), |
39 ShowRecordCommand(), | 40 ShowRecordCommand(), |
40 ServeCommand(), | 41 ServeCommand(), |
41 AdministrationPanelCommand(), | 42 AdministrationPanelCommand(), |
42 PublishCommand()] | 43 PublishCommand(), |
44 TasksCommand() | |
45 ] | |
43 | 46 |
44 def getCommandExtensions(self): | 47 def getCommandExtensions(self): |
45 from piecrust.commands.builtin.scaffolding import ( | 48 from piecrust.commands.builtin.scaffolding import ( |
46 DefaultPrepareTemplatesCommandExtension, | 49 DefaultPrepareTemplatesCommandExtension, |
47 UserDefinedPrepareTemplatesCommandExtension, | 50 UserDefinedPrepareTemplatesCommandExtension, |
163 CopyPublisher, | 166 CopyPublisher, |
164 ShellCommandPublisher, | 167 ShellCommandPublisher, |
165 SftpPublisher, | 168 SftpPublisher, |
166 RsyncPublisher] | 169 RsyncPublisher] |
167 | 170 |
171 def getTaskRunners(self): | |
172 from piecrust.tasks.mentions import MentionTaskRunner | |
173 | |
174 return [ | |
175 MentionTaskRunner] |