Skip to main content

earl_protocol_bash/
lib.rs

1pub mod builder;
2pub mod executor;
3pub mod sandbox;
4pub mod schema;
5
6pub use executor::BashExecutor;
7pub use schema::{BashOperationTemplate, BashSandboxTemplate, BashScriptTemplate};
8
9/// Resolved sandbox settings for bash execution.
10#[derive(Debug, Clone)]
11pub struct ResolvedBashSandbox {
12    pub network: bool,
13    pub writable_paths: Vec<String>,
14    pub max_time_ms: Option<u64>,
15    pub max_output_bytes: Option<usize>,
16}
17
18/// Prepared bash script data, ready for execution.
19#[derive(Debug, Clone)]
20pub struct PreparedBashScript {
21    pub script: String,
22    pub env: Vec<(String, String)>,
23    pub cwd: Option<String>,
24    pub stdin: Option<String>,
25    pub sandbox: ResolvedBashSandbox,
26}