Xcode

info.plist

Appearance

Light 关闭黑暗模式

Bundle display name

设置app名称,默认为工程名

Location When In Use Usage Description

定位权限一共有3个key

1.Privacy - Location When In Use Usage Description

2.Privacy - Location Always and When In Use Usage Description

3.Privacy - Location Always Usage Description
推荐使用1,好上架,以下教程使用Location When In Use Usage Description

swift 复制代码
import CoreLocation

// 定位
let locationManager = CLLocationManager()
locationManager.requestWhenInUseAuthorization()

//定位权限判断
switch CLLocationManager.authorizationStatus() {
case .denied :
    //未授权
case .notDetermined :
    //不确定
case .authorizedAlways :
    //一直允许
case .authorizedWhenInUse :
    //使用期间允许
case .restricted :
    //受限的
}

// 跳转到app权限设置页面
func openSettings() {
    guard let settingsURL = URL(string: UIApplication.openSettingsURLString) else {
        return
    }
 
    if UIApplication.shared.canOpenURL(settingsURL) {
        UIApplication.shared.open(settingsURL, options: [:], completionHandler: nil)
    }
}

长按显示的复制、剪切的提示从英文改为中文



Archive报错

Invalid large app icon. The large app icon in the asset catalog in "App-lOS.app" can't be transparent or contain an alpha channel.

打开app图标-> 文件 -> 导出-> 取消勾选Alpha通道

注:App图标为1024 * 1024 的正方形,不能有圆角;有圆角启动时会有黑色阴影

相关推荐
东坡肘子4 小时前
当每一次写入都有了新价格 -- 肘子的 Swift 周报 #144
人工智能·swiftui·swift
zzb15804 小时前
Zed 配置 Swift / iOS 开发
开发语言·ios·swift
黑科技iOS上架1 天前
如何解决AppStore Guideline 5.6被拒
经验分享·ios·ai编程
Geek-Chow1 天前
Mobile App Certificate Pinning: Underlying Principle and a Swift Example
开发语言·ios·swift·安全架构
韩曙亮1 天前
【Flutter】iOS 网络权限设置 ② ( 配置 iOS 平台可使用 HTTP 访问 | ATS 网络安全强制规范 )
网络·flutter·http·ios·https·网络权限·ats
酷虎软件2 天前
分享链接+视频音频文案提取 API 接口文档
ide·macos·xcode
CocoaKier2 天前
Facebook登录的这条红色警告,我终于搞明白了,真是反人类设计!
ios·facebook
humors2212 天前
【转帖】安全企业发布iOS漏洞攻击风险检测工具
安全·ios·手机·苹果
wangruofeng2 天前
终端里 rm 一下文件就没了,macOS 怎么删文件才进废纸篓
javascript·命令行·apple
沐风___2 天前
iOS 崩溃收集实战:从「只看到次数、看不到原因」到 Sentry 完整集成
ios·sentry