File tree Expand file tree Collapse file tree 2 files changed +22
-0
lines changed
crates/tauri-plugin/src/build Expand file tree Collapse file tree 2 files changed +22
-0
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ " tauri-plugin " : minor:feat
3
+ ---
4
+
5
+ Added ` build::mobile::update_info_plist ` to allow a plugin to update the iOS project Info.plist file.
Original file line number Diff line number Diff line change @@ -31,6 +31,23 @@ pub fn update_entitlements<F: FnOnce(&mut plist::Dictionary)>(f: F) -> Result<()
31
31
Ok ( ( ) )
32
32
}
33
33
34
+ #[ cfg( target_os = "macos" ) ]
35
+ pub fn update_info_plist < F : FnOnce ( & mut plist:: Dictionary ) > ( f : F ) -> Result < ( ) > {
36
+ if let ( Some ( project_path) , Ok ( app_name) ) = (
37
+ var_os ( "TAURI_IOS_PROJECT_PATH" ) . map ( PathBuf :: from) ,
38
+ std:: env:: var ( "TAURI_IOS_APP_NAME" ) ,
39
+ ) {
40
+ update_plist_file (
41
+ project_path
42
+ . join ( format ! ( "{app_name}_iOS" ) )
43
+ . join ( "Info.plist" ) ,
44
+ f,
45
+ ) ?;
46
+ }
47
+
48
+ Ok ( ( ) )
49
+ }
50
+
34
51
pub fn update_android_manifest ( block_identifier : & str , parent : & str , insert : String ) -> Result < ( ) > {
35
52
if let Some ( project_path) = var_os ( "TAURI_ANDROID_PROJECT_PATH" ) . map ( PathBuf :: from) {
36
53
let manifest_path = project_path. join ( "app/src/main/AndroidManifest.xml" ) ;
You can’t perform that action at this time.
0 commit comments