polyhorn_cli/ios/tasks/
create_universal_binary.rs1use super::{IOSContext, IOSError};
2use crate::core::{Manager, Task};
3
4pub struct CreateUniversalBinary;
7
8impl Task for CreateUniversalBinary {
9 type Context = IOSContext;
10 type Error = IOSError;
11
12 fn verb(&self) -> &str {
13 "Creating"
14 }
15
16 fn message(&self) -> &str {
17 "Universal Binary"
18 }
19
20 fn detail(&self) -> &str {
21 "for iOS"
22 }
23
24 fn run(
25 &self,
26 mut context: Self::Context,
27 _manager: &mut Manager,
28 ) -> Result<Self::Context, Self::Error> {
29 if context.products.len() == 1 {
30 let path = context.products.values().next().unwrap().to_owned();
31 context.universal_binary_path = Some(path);
32 Ok(context)
33 } else {
34 todo!("Creating universal binaries for iOS has not yet been implemented.")
35 }
36 }
37}