setup method
dynamic
setup(
- bool updateUnity
)
Implementation
setup(bool updateUnity) {
workspace = env('WORKSPACE');
iosHookUrl = env('IOS_HOOK_URL');
androidHookUrl = env('ANDROID_HOOK_URL');
appStoreConnectApiKeyId = env('APP_STORE_CONNECT_API_KEY_ID');
appStoreConnectApiIssuerId = env('APP_STORE_CONNECT_API_ISSUER_ID');
appStoreConnectApiKeyFilepath = env('APP_STORE_CONNECT_API_KEY_FILEPATH');
appIdentifier = env('APP_IDENTIFIER');
appId = env('APP_ID');
pgyerApiKey = env('PGYER_API_KEY');
if (updateUnity) {
final unityWorkspace = env('UNITY_WORKSPACE');
final iosUnityPath = env('IOS_UNITY_PATH');
final androidUnityPath = env('ANDROID_UNITY_PATH');
final unityEnginePath = env('UNITY_ENGINE_PATH');
unityEnvironment = UnityEnvironment(
unityWorkspace: unityWorkspace,
iosUnityPath: iosUnityPath,
androidUnityPath: androidUnityPath,
unityEnginePath: unityEnginePath,
);
}
buildName = env('BUILD_NAME');
dingdingIosHookUrl = env('DINGDING_IOS_HOOK_URL');
dingdingAndroidHookUrl = env('DINGDING_ANDROID_HOOK_URL');
branch = env('BRANCH').replaceFirst('origin/', '');
appwriteEnvironment = AppwriteEnvironment(
endPoint: env('APPWRITE_ENDPOINT'),
projectId: env('APPWRITE_PROJECT_ID'),
apiKey: env('APPWRITE_API_KEY'),
databaseId: env('APPWRITE_DATABASE_ID'),
collectionId: env('APPWRITE_COLLECTION_ID'),
);
umengPushEnvironment = UmengPushEnvironment(
umengAppKey: env('UMENG_APPKEY'),
umengMessageSecret: env('UMENG_MESSAGE_SECRET'),
umengChannel: env('UMENG_CHANNEL'),
);
buildNumber = DateTime.now().millisecondsSinceEpoch ~/ 1000;
forceBuild = env('FORCE_BUILD') == 'true';
unityBranchName = env('UNITY_BRANCH_NAME');
}