Skip to content

Commit

Permalink
feat(cli): "wasmer deploy": return app version as json if --json spec…
Browse files Browse the repository at this point in the history
…ified

This can help in CI workflows and will also be used in tests.
  • Loading branch information
theduke committed Feb 29, 2024
1 parent 2b56441 commit 1e1131a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/cli/src/commands/deploy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,10 @@ impl AsyncCliCommand for CmdDeploy {
.with_context(|| format!("Could not write file: '{}'", file_path.display()))?;
}

if self.fmt.format == crate::utils::render::ItemFormat::Json {
println!("{}", serde_json::to_string_pretty(&app_version)?);
}

Ok(app_version)
}
}

0 comments on commit 1e1131a

Please sign in to comment.