diff --git a/src/config.rs b/src/config.rs index f0f57f0..7168755 100644 --- a/src/config.rs +++ b/src/config.rs @@ -179,7 +179,7 @@ pub struct Plugin { /// Arguments passed to the executable. #[serde(default, flatten)] - pub args: PluginArgs, + pub args: Option, /// A filter which decides whether the plugin should be run. /// diff --git a/src/plugin.rs b/src/plugin.rs index db58c44..73f0bba 100644 --- a/src/plugin.rs +++ b/src/plugin.rs @@ -38,7 +38,7 @@ impl From<&config::Plugin> for ExecutablePlugin { if value.with.is_some() { args.push(value.run.clone()); }; - match &value.args { + match value.args.clone().unwrap_or_default() { config::PluginArgs::Options(options) => { args.push( serde_json::to_string(&options)