|
@@ -1,7 +1,7 @@
|
|
import { CapacitorConfig } from '@capacitor/cli';
|
|
import { CapacitorConfig } from '@capacitor/cli';
|
|
import { updateVersion } from './scripts/sync-version';
|
|
import { updateVersion } from './scripts/sync-version';
|
|
-
|
|
|
|
-updateVersion()
|
|
|
|
|
|
+
|
|
|
|
+updateVersion()
|
|
|
|
|
|
const config: CapacitorConfig = {
|
|
const config: CapacitorConfig = {
|
|
appId: 'com.example.app',
|
|
appId: 'com.example.app',
|
|
@@ -13,24 +13,9 @@ const config: CapacitorConfig = {
|
|
url: 'http://192.168.0.59:5173',
|
|
url: 'http://192.168.0.59:5173',
|
|
cleartext: true, // 允许HTTP明文通信(仅开发环境)
|
|
cleartext: true, // 允许HTTP明文通信(仅开发环境)
|
|
allowNavigation: ['*'] // 允许任意URL导航
|
|
allowNavigation: ['*'] // 允许任意URL导航
|
|
- },
|
|
|
|
|
|
+ },
|
|
// 插件配置
|
|
// 插件配置
|
|
plugins: {
|
|
plugins: {
|
|
- SplashScreen: {
|
|
|
|
- launchShowDuration: 3000,
|
|
|
|
- launchAutoHide: true,
|
|
|
|
- backgroundColor: '#ffffffff', // ARGB格式白色背景
|
|
|
|
- androidScaleType: 'CENTER_CROP',
|
|
|
|
- showSpinner: false,
|
|
|
|
- androidSpinnerStyle: 'large',
|
|
|
|
- iosSpinnerStyle: 'small',
|
|
|
|
- spinnerColor: '#999999',
|
|
|
|
- splashFullScreen: true,
|
|
|
|
- splashImmersive: true,
|
|
|
|
- androidSplashResourceName: 'splash',
|
|
|
|
- useDialog: false
|
|
|
|
- },
|
|
|
|
-
|
|
|
|
CapacitorAssets: {
|
|
CapacitorAssets: {
|
|
iconBackgroundColor: '#ffffff' // 应用图标背景色
|
|
iconBackgroundColor: '#ffffff' // 应用图标背景色
|
|
},
|
|
},
|
|
@@ -40,16 +25,6 @@ const config: CapacitorConfig = {
|
|
presentationOptions: ['badge', 'sound', 'alert']
|
|
presentationOptions: ['badge', 'sound', 'alert']
|
|
}
|
|
}
|
|
},
|
|
},
|
|
-
|
|
|
|
- // 资源文件配置
|
|
|
|
- // assets: {
|
|
|
|
- // splash: {
|
|
|
|
- // src: 'assets/splash.png', // 启动图路径
|
|
|
|
- // android: true,
|
|
|
|
- // ios: true
|
|
|
|
- // }
|
|
|
|
- // },
|
|
|
|
-
|
|
|
|
// iOS专属配置
|
|
// iOS专属配置
|
|
ios: {
|
|
ios: {
|
|
scheme: 'App',
|
|
scheme: 'App',
|
|
@@ -65,8 +40,8 @@ const config: CapacitorConfig = {
|
|
buildOptions: {
|
|
buildOptions: {
|
|
keystorePath: 'f62.keystore',
|
|
keystorePath: 'f62.keystore',
|
|
keystoreAlias: 'f62', // // 生成时指定的别名
|
|
keystoreAlias: 'f62', // // 生成时指定的别名
|
|
- keystorePassword: 'LkSvN1Ys', // 从环境变量读取
|
|
|
|
- keystoreAliasPassword: 'LkSvN1Ys'
|
|
|
|
|
|
+ keystorePassword: 'LkSvN1Ys', // 从环境变量读取
|
|
|
|
+ keystoreAliasPassword: 'LkSvN1Ys'
|
|
}
|
|
}
|
|
}
|
|
}
|
|
};
|
|
};
|