线上配置1
Production deploy / build (push) Successful in 1m29s Details

This commit is contained in:
wendazhi 2026-02-12 17:57:24 +08:00
parent 48dbd4b49f
commit 3b6cb52149
6 changed files with 65 additions and 0 deletions

View File

@ -0,0 +1,12 @@
// Develop.xcconfig - 开发/测试环境
// 用于连接测试服、预发布环境
#include "Shared.xcconfig"
// API 域名(注入 Info.plist运行时通过 Bundle.main 读取)
API_DOMAIN = https://api.muststudy.xin
INFOPLIST_KEY_API_DOMAIN = $(API_DOMAIN)
// Swift 编译条件:代码中可用 #if API_ENV_DEVELOP
SWIFT_ACTIVE_COMPILATION_CONDITIONS = API_ENV_DEVELOP $(inherited)
GCC_PREPROCESSOR_DEFINITIONS = $(inherited)

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>API_DOMAIN</key>
<string>$(API_DOMAIN)</string>
</dict>
</plist>

View File

@ -0,0 +1,13 @@
// Local.xcconfig - 本地开发环境
// 用于连接本机 localhost 或局域网后端
// 真机调试时可将 API_DOMAIN 改为本机局域网 IP如 http://192.168.1.100:3000
#include "Shared.xcconfig"
// API 域名(注入 Info.plist运行时通过 Bundle.main 读取)
API_DOMAIN = http://localhost:3000
INFOPLIST_KEY_API_DOMAIN = $(API_DOMAIN)
// Swift 编译条件:代码中可用 #if API_ENV_LOCAL
SWIFT_ACTIVE_COMPILATION_CONDITIONS = API_ENV_LOCAL $(inherited)
GCC_PREPROCESSOR_DEFINITIONS = $(inherited)

View File

@ -0,0 +1,12 @@
// Online.xcconfig - 线上生产环境
// 用于 Release 打包、TestFlight、App Store
#include "Shared.xcconfig"
// API 域名(注入 Info.plist运行时通过 Bundle.main 读取)
API_DOMAIN = https://wildgrowth.upolar.com
INFOPLIST_KEY_API_DOMAIN = $(API_DOMAIN)
// Swift 编译条件:代码中可用 #if API_ENV_ONLINE
SWIFT_ACTIVE_COMPILATION_CONDITIONS = API_ENV_ONLINE $(inherited)
GCC_PREPROCESSOR_DEFINITIONS = $(inherited)

View File

@ -0,0 +1,6 @@
// Shared.xcconfig - 公共配置(被各环境 xcconfig 引用)
// 包含 Swift 版本、编译选项等通用设置
SWIFT_VERSION = 5.0
SWIFT_EMIT_LOC_STRINGS = YES
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>BuildLocationStyle</key>
<string>UseAppPreferences</string>
<key>CustomBuildLocationType</key>
<string>RelativeToDerivedData</string>
<key>DerivedDataLocationStyle</key>
<string>Default</string>
<key>ShowSharedSchemesAutomaticallyEnabled</key>
<true/>
</dict>
</plist>