@@ -80,24 +80,32 @@ pub struct Options {
80
80
pub ci : bool ,
81
81
/// Describes how Xcode should export the archive.
82
82
///
83
- /// Use this to create a package ready for the App Store (app-store-connect option) or TestFlight (release-testing option).
83
+ /// Use this to create a package ready for distribution.
84
+ /// for more information, see https://developer.apple.com/documentation/xcode/distributing-your-app-for-beta-testing-and-releases
85
+ ///
86
+ /// - `app-store`: Distribute using TestFlight or through the App Store.
87
+ /// - `ad-hoc`: Distribute to a limited number of devices you register in App Store Connect.
88
+ /// - `enterprise`: Distribute to members of your organization.
89
+ /// - `development`: Distribute to a limited number of devices you register in App Store Connect.
84
90
#[ clap( long, value_enum) ]
85
91
pub export_method : Option < ExportMethod > ,
86
92
}
87
93
88
94
#[ derive( Debug , Clone , Copy , ValueEnum ) ]
89
95
pub enum ExportMethod {
90
- AppStoreConnect ,
91
- ReleaseTesting ,
92
- Debugging ,
96
+ AppStore ,
97
+ AdHoc ,
98
+ Enterprise ,
99
+ Development ,
93
100
}
94
101
95
102
impl std:: fmt:: Display for ExportMethod {
96
103
fn fmt ( & self , f : & mut std:: fmt:: Formatter < ' _ > ) -> std:: fmt:: Result {
97
104
match self {
98
- Self :: AppStoreConnect => write ! ( f, "app-store-connect" ) ,
99
- Self :: ReleaseTesting => write ! ( f, "release-testing" ) ,
100
- Self :: Debugging => write ! ( f, "debugging" ) ,
105
+ Self :: AppStore => write ! ( f, "app-store" ) ,
106
+ Self :: AdHoc => write ! ( f, "ad-hoc" ) ,
107
+ Self :: Enterprise => write ! ( f, "enterprise" ) ,
108
+ Self :: Development => write ! ( f, "development" ) ,
101
109
}
102
110
}
103
111
}
@@ -107,10 +115,11 @@ impl std::str::FromStr for ExportMethod {
107
115
108
116
fn from_str ( s : & str ) -> Result < Self , Self :: Err > {
109
117
match s {
110
- "app-store-connect" => Ok ( Self :: AppStoreConnect ) ,
111
- "release-testing" => Ok ( Self :: ReleaseTesting ) ,
112
- "debugging" => Ok ( Self :: Debugging ) ,
113
- _ => Err ( "unknown ios target" ) ,
118
+ "app-store" => Ok ( Self :: AppStore ) ,
119
+ "ad-hoc" => Ok ( Self :: AdHoc ) ,
120
+ "enterprise" => Ok ( Self :: Enterprise ) ,
121
+ "development" => Ok ( Self :: Development ) ,
122
+ _ => Err ( "unknown ios export method" ) ,
114
123
}
115
124
}
116
125
}
0 commit comments