diff --git a/.changes/shell-execute-return.md b/.changes/shell-execute-return.md new file mode 100644 index 00000000..6bc270f5 --- /dev/null +++ b/.changes/shell-execute-return.md @@ -0,0 +1,5 @@ +--- +"shell": "patch" +--- + +Fix a regression introduce in the last release where The JS API `Command.execute()` returned malformed response. diff --git a/plugins/shell/src/commands.rs b/plugins/shell/src/commands.rs index 77aee699..dce61ec5 100644 --- a/plugins/shell/src/commands.rs +++ b/plugins/shell/src/commands.rs @@ -170,6 +170,7 @@ fn prepare_cmd( } #[derive(Serialize)] +#[serde(untagged)] enum Output { String(String), Raw(Vec), @@ -179,9 +180,7 @@ enum Output { pub struct ChildProcessReturn { code: Option, signal: Option, - #[serde(flatten)] stdout: Output, - #[serde(flatten)] stderr: Output, }