pub fn version() -> String {
env!("CARGO_PKG_VERSION").to_string()
}
pub trait OutputGenerator {
fn generate(&self, input: &str) -> String;
}
#[derive(Debug, Default, Clone)]
pub struct NoopOutput;
impl OutputGenerator for NoopOutput {
fn generate(&self, input: &str) -> String {
input.to_string()
}
}
mod common;
mod github;
mod json;
mod progress;
pub use github::{to_github_markdown, GithubIssuesOutput};
pub use json::{
to_json_string_pretty, to_json_string_pretty_with_rheis, to_json_value,
to_json_value_with_rheis, JsonOutput, RheiMachine,
};
pub use progress::{to_progress_report, ProgressReportOutput};
pub trait PlanOutputGenerator {
fn generate_rhei(&self, rhei: &rhei_core::ast::Rhei) -> serde_json::Value;
}
#[cfg(test)]
mod tests;