2025-10-11 14:35:29 -07:00
|
|
|
use crate::context::SproutContext;
|
2025-11-03 02:04:21 -05:00
|
|
|
use alloc::rc::Rc;
|
2025-10-11 14:35:29 -07:00
|
|
|
use anyhow::Result;
|
2025-11-02 23:28:31 -05:00
|
|
|
use edera_sprout_config::actions::print::PrintConfiguration;
|
2025-10-27 00:21:24 -04:00
|
|
|
use log::info;
|
2025-10-05 00:09:53 -07:00
|
|
|
|
2025-10-19 21:44:05 -07:00
|
|
|
/// Executes the print action with the specified `configuration` inside the provided `context`.
|
2025-10-11 14:35:29 -07:00
|
|
|
pub fn print(context: Rc<SproutContext>, configuration: &PrintConfiguration) -> Result<()> {
|
2025-10-27 00:21:24 -04:00
|
|
|
info!("{}", context.stamp(&configuration.text));
|
2025-10-11 14:35:29 -07:00
|
|
|
Ok(())
|
2025-10-05 00:09:53 -07:00
|
|
|
}
|