- Add `show-arguments` recipe documenting all version update commands - Add `complete-update-interactive` recipe for manual confirmations - Maintain `complete-update` as automatic mode (no prompts) - Update `update-help` to reference new recipes and modes - Document 7-step workflow and step-by-step differences Changes: - complete-update: Automatic mode (recommended for CI/CD) - complete-update-interactive: Interactive mode (with confirmations) - show-arguments: Complete documentation of all commands and modes - Both modes share same 7-step workflow with different behavior in Step 4
17 lines
423 B
Rust
17 lines
423 B
Rust
use image::DynamicImage;
|
|
|
|
use crate::image_to_ansi::nu_plugin::IntoAnsiParams;
|
|
|
|
use super::{make_ansi, string_writer::StringWriter};
|
|
|
|
pub fn to_ansi(img: &DynamicImage, config: &IntoAnsiParams) -> String {
|
|
let stdout = &mut StringWriter::new();
|
|
let _ = make_ansi(stdout, img, config);
|
|
|
|
// if config.restore_cursor {
|
|
// execute!(&mut stdout, RestorePosition)?;
|
|
// };
|
|
|
|
stdout.read().to_string()
|
|
}
|