Skip to main content

@baeta/plugin-exec

Interfaces

ExecPluginOptions

Configuration options for the exec plugin.

Properties

PropertyTypeDescription

exec

string | (ctx) => void | Promise<void>

Command to execute - can be either:

  • A string command to be executed via shell
  • A function that receives the generator context

actionName?

string

Action name displayed in the generation status. Shows as "Generating {actionName}..."

name?

string

Plugin name displayed in logs

skip?

(ctx: object) => boolean | Promise<boolean>

Optional function to determine if execution should be skipped

watch?

GeneratorPluginV1WatchOptions

File watching configuration

Functions

createExecPlugin()

createExecPlugin(options): GeneratorPluginV1<unknown>

A plugin that executes commands or functions during generation.

Parameters

ParameterTypeDescription

options

ExecPluginOptions

Plugin configuration options

Returns

GeneratorPluginV1<unknown>

A Baeta generator plugin

References

default

Renames and re-exports createExecPlugin