Action
Class Action
class Action(Node['Action'])
Base class for actions that can be embedded in a Novella pipeline.
context
The instance of the Novella application object that controls the pipeline and lifecycle of the build process. This is set when the action is added to the pipeline and is always available when execute() is called.
callsite
The callsite at which the action was created.
supports_reloading
Set to True to indicate that the action supports content reloading while it is running. This is relevant for actions that trigger static site generators serving content that already have automatic reloading capabilities as this will tell Novella to not kill the action and instead rerun the parts of the pipeline that came before it.
__post_init__
def __post_init__() -> None
Called from __init__()
. Can be overwritten by subclasses to avoid having to overload the constructor.
get_description
def get_description() -> str | None
Return a short text description of the action. It may be shown while the action is running to information the user of what is currently happening.
setup
def setup(build: BuildContext) -> None
Called before configuration closures when the build context is ready.
execute
@abc.abstractmethod
def execute(build: BuildContext) -> None
Execute the action.