pub struct WatchPluginArgs {
pub path: PathBuf,
pub server: Option<String>,
pub token: Option<String>,
pub install: bool,
pub release: bool,
pub debounce: u64,
}Expand description
Watches plugin source files and auto-rebuilds + uploads on changes.
For plugins with a [web] section, the watch command spawns the frontend
dev server (pnpm dev by default, configurable via broccoli.dev.toml)
as a long-running background process. tsup’s built-in --watch mode
handles incremental frontend rebuilds; the CLI watches the [web].root
output directory for changes and triggers package + upload when new
build artifacts appear.
For backend changes (.rs, .toml), the CLI runs cargo build itself
and then packages + uploads.
Create a broccoli.dev.toml in the plugin directory to customize behavior:
[watch] ignore = [“*.log”, “tmp/”] # extra patterns to ignore
[build] frontend_dir = “client” # frontend source directory frontend_install_cmd = “pnpm install –ignore-workspace” # install command frontend_build_cmd = “pnpm build” # one-shot build (default: “pnpm build”) frontend_dev_cmd = “pnpm dev” # dev server (default: “pnpm dev”)
Built-in ignores (always active): target/, .git/, node_modules/.
Fields§
§path: PathBufPath to the plugin directory
server: Option<String>Broccoli server URL (overrides saved credentials)
token: Option<String>Auth token (overrides saved credentials)
install: boolForce execution of the frontend installation command even if node_modules exists
release: boolBuild in release mode
debounce: u64Debounce interval in milliseconds
Trait Implementations§
Source§impl Args for WatchPluginArgs
impl Args for WatchPluginArgs
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl FromArgMatches for WatchPluginArgs
impl FromArgMatches for WatchPluginArgs
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.