(output: Vec<u8>, executable: &std::path::Path)
| 675 | "; |
| 676 | |
| 677 | fn normalize_completion_script(output: Vec<u8>, executable: &std::path::Path) -> Result<String> { |
| 678 | let script = String::from_utf8(output) |
| 679 | .map_err(|e| miette::miette!("generated completions were not valid UTF-8: {e}"))?; |
| 680 | Ok(script.replace(executable.to_string_lossy().as_ref(), "openshell")) |
| 681 | } |
| 682 | |
| 683 | #[derive(Clone, Debug, ValueEnum)] |
| 684 | enum OutputFormat { |
no outgoing calls