@expo/eas-build-job 0.2.101 → 0.2.103
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/android.d.ts +2 -4
- package/dist/android.js +2 -37
- package/dist/android.js.map +1 -1
- package/dist/common.d.ts +0 -6
- package/dist/common.js.map +1 -1
- package/dist/ios.d.ts +2 -4
- package/dist/ios.js +2 -34
- package/dist/ios.js.map +1 -1
- package/dist/job.d.ts +1 -13
- package/dist/job.js +2 -53
- package/dist/job.js.map +1 -1
- package/dist/metadata.d.ts +4 -0
- package/dist/metadata.js +1 -0
- package/dist/metadata.js.map +1 -1
- package/package.json +1 -1
package/dist/android.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import Joi from 'joi';
|
|
2
|
-
import { ArchiveSource, Env, Platform, Workflow, Cache, EnvironmentSecret,
|
|
2
|
+
import { ArchiveSource, Env, Platform, Workflow, Cache, EnvironmentSecret, BuildTrigger, BuildMode } from './common';
|
|
3
3
|
export interface Keystore {
|
|
4
4
|
dataBase64: string;
|
|
5
5
|
keystorePassword: string;
|
|
@@ -10,10 +10,8 @@ export declare enum BuildType {
|
|
|
10
10
|
APK = "apk",
|
|
11
11
|
APP_BUNDLE = "app-bundle"
|
|
12
12
|
}
|
|
13
|
-
export declare const builderBaseImages: readonly ["default", "latest", "stable", "ubuntu-18.04-android-30-ndk-r19c", "ubuntu-20.04-android-30-ndk-r21e", "ubuntu-18.04-jdk-8-ndk-r19c", "ubuntu-18.04-jdk-11-ndk-r19c", "ubuntu-20.04-jdk-8-ndk-r21e", "ubuntu-20.04-jdk-11-ndk-r21e", "ubuntu-22.04-jdk-8-ndk-r21e", "ubuntu-22.04-jdk-11-ndk-r21e"];
|
|
14
|
-
export declare const imageMatchRules: ImageMatchRule<typeof builderBaseImages[number]>[];
|
|
15
13
|
export interface BuilderEnvironment {
|
|
16
|
-
image?:
|
|
14
|
+
image?: string;
|
|
17
15
|
node?: string;
|
|
18
16
|
yarn?: string;
|
|
19
17
|
expoCli?: string;
|
package/dist/android.js
CHANGED
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.JobSchema = exports.
|
|
6
|
+
exports.JobSchema = exports.BuildType = void 0;
|
|
7
7
|
const joi_1 = __importDefault(require("joi"));
|
|
8
8
|
const common_1 = require("./common");
|
|
9
9
|
const KeystoreSchema = joi_1.default.object({
|
|
@@ -17,43 +17,8 @@ var BuildType;
|
|
|
17
17
|
BuildType["APK"] = "apk";
|
|
18
18
|
BuildType["APP_BUNDLE"] = "app-bundle";
|
|
19
19
|
})(BuildType = exports.BuildType || (exports.BuildType = {}));
|
|
20
|
-
exports.builderBaseImages = [
|
|
21
|
-
'default',
|
|
22
|
-
'latest',
|
|
23
|
-
'stable',
|
|
24
|
-
'ubuntu-18.04-android-30-ndk-r19c',
|
|
25
|
-
'ubuntu-20.04-android-30-ndk-r21e',
|
|
26
|
-
'ubuntu-18.04-jdk-8-ndk-r19c',
|
|
27
|
-
'ubuntu-18.04-jdk-11-ndk-r19c',
|
|
28
|
-
'ubuntu-20.04-jdk-8-ndk-r21e',
|
|
29
|
-
'ubuntu-20.04-jdk-11-ndk-r21e',
|
|
30
|
-
'ubuntu-22.04-jdk-8-ndk-r21e',
|
|
31
|
-
'ubuntu-22.04-jdk-11-ndk-r21e',
|
|
32
|
-
];
|
|
33
|
-
exports.imageMatchRules = [
|
|
34
|
-
{
|
|
35
|
-
image: 'ubuntu-18.04-jdk-11-ndk-r19c',
|
|
36
|
-
reactNativeSemverRange: '>=0.68.0',
|
|
37
|
-
sdkSemverRange: '<46',
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
image: 'ubuntu-18.04-jdk-8-ndk-r19c',
|
|
41
|
-
reactNativeSemverRange: '<0.68.0',
|
|
42
|
-
sdkSemverRange: '<46',
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
image: 'ubuntu-20.04-jdk-11-ndk-r21e',
|
|
46
|
-
reactNativeSemverRange: '>=0.68.0',
|
|
47
|
-
sdkSemverRange: '>=46',
|
|
48
|
-
},
|
|
49
|
-
{
|
|
50
|
-
image: 'ubuntu-20.04-jdk-8-ndk-r21e',
|
|
51
|
-
reactNativeSemverRange: '<0.68.0',
|
|
52
|
-
sdkSemverRange: '>=46',
|
|
53
|
-
},
|
|
54
|
-
];
|
|
55
20
|
const BuilderEnvironmentSchema = joi_1.default.object({
|
|
56
|
-
image: joi_1.default.string()
|
|
21
|
+
image: joi_1.default.string(),
|
|
57
22
|
node: joi_1.default.string(),
|
|
58
23
|
yarn: joi_1.default.string(),
|
|
59
24
|
expoCli: joi_1.default.string(),
|
package/dist/android.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"android.js","sourceRoot":"","sources":["../src/android.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAsB;AAEtB,
|
|
1
|
+
{"version":3,"file":"android.js","sourceRoot":"","sources":["../src/android.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAsB;AAEtB,qCAakB;AASlB,MAAM,cAAc,GAAG,aAAG,CAAC,MAAM,CAAC;IAChC,UAAU,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACnC,gBAAgB,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,QAAQ,EAAE;IACnD,QAAQ,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,WAAW,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,EAAE,CAAC;CACpC,CAAC,CAAC;AAEH,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,wBAAW,CAAA;IACX,sCAAyB,CAAA;AAC3B,CAAC,EAHW,SAA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ema,\n EnvironmentSecretsSchema,\n EnvironmentSecret,\n BuildTrigger,\n BuildMode,\n} from './common';\n\nexport interface Keystore {\n dataBase64: string;\n keystorePassword: string;\n keyAlias: string;\n keyPassword?: string;\n}\n\nconst KeystoreSchema = Joi.object({\n dataBase64: Joi.string().required(),\n keystorePassword: Joi.string().allow('').required(),\n keyAlias: Joi.string().required(),\n keyPassword: Joi.string().allow(''),\n});\n\nexport enum BuildType {\n APK = 'apk',\n APP_BUNDLE = 'app-bundle',\n}\n\nexport interface BuilderEnvironment {\n image?: string;\n node?: string;\n yarn?: string;\n expoCli?: string;\n ndk?: string;\n env?: Env;\n}\n\nconst BuilderEnvironmentSchema = Joi.object({\n image: Joi.string(),\n node: Joi.string(),\n yarn: Joi.string(),\n expoCli: Joi.string(),\n ndk: Joi.string(),\n env: EnvSchema,\n});\n\nexport interface Job {\n mode: BuildMode;\n type: Workflow;\n triggeredBy: BuildTrigger;\n projectArchive: ArchiveSource;\n platform: Platform.ANDROID;\n projectRootDirectory: string;\n buildProfile?: string;\n releaseChannel?: string;\n updates?: {\n channel?: string;\n };\n secrets: {\n buildCredentials?: {\n keystore: Keystore;\n };\n environmentSecrets?: EnvironmentSecret[];\n robotAccessToken?: string;\n };\n builderEnvironment?: BuilderEnvironment;\n cache: Cache;\n developmentClient?: boolean;\n version?: {\n versionCode?: string;\n /**\n * support for this field is implemented, but specifying it is disabled on schema level\n */\n versionName?: string;\n /**\n * support for this field is implemented, but specifying it is disabled on schema level\n */\n runtimeVersion?: string;\n };\n buildArtifactPaths?: string[];\n\n gradleCommand?: string;\n applicationArchivePath?: string;\n\n buildType?: BuildType;\n username?: string;\n\n experimental?: {\n prebuildCommand?: string;\n };\n}\n\nexport const JobSchema = Joi.object({\n mode: Joi.string().valid(BuildMode.BUILD).default(BuildMode.BUILD),\n type: Joi.string()\n .valid(...Object.values(Workflow))\n .required(),\n triggeredBy: Joi.string()\n .valid(...Object.values(BuildTrigger))\n .default(BuildTrigger.EAS_CLI),\n projectArchive: ArchiveSourceSchema.required(),\n platform: Joi.string().valid(Platform.ANDROID).required(),\n projectRootDirectory: Joi.string().required(),\n buildProfile: Joi.when('triggeredBy', {\n is: BuildTrigger.GIT_BASED_INTEGRATION,\n then: Joi.string().required(),\n otherwise: Joi.string(),\n }),\n releaseChannel: Joi.string(),\n updates: Joi.object({\n channel: Joi.string(),\n }),\n secrets: Joi.object({\n buildCredentials: Joi.object({ keystore: KeystoreSchema.required() }),\n environmentSecrets: EnvironmentSecretsSchema,\n robotAccessToken: Joi.string(),\n }).required(),\n builderEnvironment: BuilderEnvironmentSchema,\n cache: CacheSchema.default(),\n developmentClient: Joi.boolean(),\n version: Joi.object({\n versionCode: Joi.string().regex(/^\\d+$/),\n }),\n buildArtifactPaths: Joi.array().items(Joi.string()),\n\n gradleCommand: Joi.string(),\n applicationArchivePath: Joi.string(),\n\n buildType: Joi.string().valid(...Object.values(BuildType)),\n username: Joi.string(),\n\n experimental: Joi.object({\n prebuildCommand: Joi.string(),\n }),\n}).oxor('releaseChannel', 'updates.channel');\n"]}
|
package/dist/common.d.ts
CHANGED
|
@@ -77,9 +77,3 @@ export interface BuildPhaseStats {
|
|
|
77
77
|
result: BuildPhaseResult;
|
|
78
78
|
durationMs: number;
|
|
79
79
|
}
|
|
80
|
-
export interface ImageMatchRule<Image extends string> {
|
|
81
|
-
image: Image;
|
|
82
|
-
reactNativeSemverRange?: string;
|
|
83
|
-
sdkSemverRange?: string;
|
|
84
|
-
workflows?: Workflow[];
|
|
85
|
-
}
|
package/dist/common.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"common.js","sourceRoot":"","sources":["../src/common.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAsB;AAItB,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,4BAAe,CAAA;IACf,8BAAiB,CAAA;AACnB,CAAC,EAHW,SAAS,GAAT,iBAAS,KAAT,iBAAS,QAGpB;AAED,IAAY,QAIX;AAJD,WAAY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,CAAC,KAAK,CAAC,aAAG,CAAC,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC;CACzD,CAAC,CAAC","sourcesContent":["import Joi from 'joi';\n\nimport { BuildPhase, BuildPhaseResult } from './logs';\n\nexport enum BuildMode {\n BUILD = 'build',\n RESIGN = 'resign',\n}\n\nexport enum Workflow {\n GENERIC = 'generic',\n MANAGED = 'managed',\n UNKNOWN = 'unknown',\n}\n\nexport enum Platform {\n ANDROID = 'android',\n IOS = 'ios',\n}\n\nexport enum ArchiveSourceType {\n NONE = 'NONE',\n S3 = 'S3',\n URL = 'URL',\n PATH = 'PATH',\n GCS = 'GCS',\n GIT = 'GIT',\n}\n\nexport enum BuildTrigger {\n EAS_CLI = 'EAS_CLI',\n GIT_BASED_INTEGRATION = 'GIT_BASED_INTEGRATION',\n}\n\nexport type ArchiveSource =\n | { type: ArchiveSourceType.NONE }\n | { type: ArchiveSourceType.S3; bucketKey: string }\n | { type: ArchiveSourceType.GCS; bucketKey: string }\n | { type: ArchiveSourceType.URL; url: string }\n | { type: ArchiveSourceType.PATH; path: string }\n | {\n type: ArchiveSourceType.GIT;\n /**\n * Url that can be used to clone repository.\n * It should contain embedded credentials for private registries.\n */\n repositoryUrl: string;\n /**\n * Git commit hash, branch, or tag\n */\n gitRef: string;\n };\n\nexport const ArchiveSourceSchema = Joi.object<ArchiveSource>({\n type: Joi.string()\n .valid(...Object.values(ArchiveSourceType))\n .required(),\n})\n .when(Joi.object({ type: ArchiveSourceType.GCS }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.GCS).required(),\n bucketKey: Joi.string().required(),\n }),\n })\n .when(Joi.object({ type: ArchiveSourceType.S3 }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.S3).required(),\n bucketKey: Joi.string().required(),\n }),\n })\n .when(Joi.object({ type: ArchiveSourceType.URL }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.URL).required(),\n url: Joi.string().uri().required(),\n }),\n })\n .when(Joi.object({ type: ArchiveSourceType.GIT }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.GIT).required(),\n repositoryUrl: Joi.string().required(),\n gitRef: Joi.string().required(),\n }),\n })\n .when(Joi.object({ type: ArchiveSourceType.PATH }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.PATH).required(),\n path: Joi.string().required(),\n }),\n });\n\nexport type Env = Record<string, string>;\nexport const EnvSchema = Joi.object().pattern(Joi.string(), Joi.string());\n\nexport type EnvironmentSecret = {\n name: string;\n type: EnvironmentSecretType;\n value: string;\n};\nexport enum EnvironmentSecretType {\n STRING = 'string',\n FILE = 'file',\n}\nexport const EnvironmentSecretsSchema = Joi.array().items(\n Joi.object({\n name: Joi.string().required(),\n value: Joi.string().required(),\n type: Joi.string()\n .valid(...Object.values(EnvironmentSecretType))\n .required(),\n })\n);\n\nexport interface Cache {\n disabled: boolean;\n clear: boolean;\n key?: string;\n cacheDefaultPaths: boolean;\n customPaths: string[];\n}\n\nexport const CacheSchema = Joi.object({\n disabled: Joi.boolean().default(false),\n clear: Joi.boolean().default(false),\n key: Joi.string().allow('').max(128),\n cacheDefaultPaths: Joi.boolean().default(true),\n customPaths: Joi.array().items(Joi.string()).default([]),\n});\n\nexport interface BuildPhaseStats {\n buildPhase: BuildPhase;\n result: BuildPhaseResult;\n durationMs: number;\n}\n
|
|
1
|
+
{"version":3,"file":"common.js","sourceRoot":"","sources":["../src/common.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAsB;AAItB,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,4BAAe,CAAA;IACf,8BAAiB,CAAA;AACnB,CAAC,EAHW,SAAS,GAAT,iBAAS,KAAT,iBAAS,QAGpB;AAED,IAAY,QAIX;AAJD,WAAY,QAAQ;IAClB,+BAAmB,CAAA;IACnB,+BAAmB,CAAA;IACnB,+BAAmB,CAAA;AACrB,CAAC,EAJW,QAAQ,GA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sourcesContent":["import Joi from 'joi';\n\nimport { BuildPhase, BuildPhaseResult } from './logs';\n\nexport enum BuildMode {\n BUILD = 'build',\n RESIGN = 'resign',\n}\n\nexport enum Workflow {\n GENERIC = 'generic',\n MANAGED = 'managed',\n UNKNOWN = 'unknown',\n}\n\nexport enum Platform {\n ANDROID = 'android',\n IOS = 'ios',\n}\n\nexport enum ArchiveSourceType {\n NONE = 'NONE',\n S3 = 'S3',\n URL = 'URL',\n PATH = 'PATH',\n GCS = 'GCS',\n GIT = 'GIT',\n}\n\nexport enum BuildTrigger {\n EAS_CLI = 'EAS_CLI',\n GIT_BASED_INTEGRATION = 'GIT_BASED_INTEGRATION',\n}\n\nexport type ArchiveSource =\n | { type: ArchiveSourceType.NONE }\n | { type: ArchiveSourceType.S3; bucketKey: string }\n | { type: ArchiveSourceType.GCS; bucketKey: string }\n | { type: ArchiveSourceType.URL; url: string }\n | { type: ArchiveSourceType.PATH; path: string }\n | {\n type: ArchiveSourceType.GIT;\n /**\n * Url that can be used to clone repository.\n * It should contain embedded credentials for private registries.\n */\n repositoryUrl: string;\n /**\n * Git commit hash, branch, or tag\n */\n gitRef: string;\n };\n\nexport const ArchiveSourceSchema = Joi.object<ArchiveSource>({\n type: Joi.string()\n .valid(...Object.values(ArchiveSourceType))\n .required(),\n})\n .when(Joi.object({ type: ArchiveSourceType.GCS }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.GCS).required(),\n bucketKey: Joi.string().required(),\n }),\n })\n .when(Joi.object({ type: ArchiveSourceType.S3 }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.S3).required(),\n bucketKey: Joi.string().required(),\n }),\n })\n .when(Joi.object({ type: ArchiveSourceType.URL }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.URL).required(),\n url: Joi.string().uri().required(),\n }),\n })\n .when(Joi.object({ type: ArchiveSourceType.GIT }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.GIT).required(),\n repositoryUrl: Joi.string().required(),\n gitRef: Joi.string().required(),\n }),\n })\n .when(Joi.object({ type: ArchiveSourceType.PATH }).unknown(), {\n then: Joi.object({\n type: Joi.string().valid(ArchiveSourceType.PATH).required(),\n path: Joi.string().required(),\n }),\n });\n\nexport type Env = Record<string, string>;\nexport const EnvSchema = Joi.object().pattern(Joi.string(), Joi.string());\n\nexport type EnvironmentSecret = {\n name: string;\n type: EnvironmentSecretType;\n value: string;\n};\nexport enum EnvironmentSecretType {\n STRING = 'string',\n FILE = 'file',\n}\nexport const EnvironmentSecretsSchema = Joi.array().items(\n Joi.object({\n name: Joi.string().required(),\n value: Joi.string().required(),\n type: Joi.string()\n .valid(...Object.values(EnvironmentSecretType))\n .required(),\n })\n);\n\nexport interface Cache {\n disabled: boolean;\n clear: boolean;\n key?: string;\n cacheDefaultPaths: boolean;\n customPaths: string[];\n}\n\nexport const CacheSchema = Joi.object({\n disabled: Joi.boolean().default(false),\n clear: Joi.boolean().default(false),\n key: Joi.string().allow('').max(128),\n cacheDefaultPaths: Joi.boolean().default(true),\n customPaths: Joi.array().items(Joi.string()).default([]),\n});\n\nexport interface BuildPhaseStats {\n buildPhase: BuildPhase;\n result: BuildPhaseResult;\n durationMs: number;\n}\n"]}
|
package/dist/ios.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import Joi from 'joi';
|
|
2
|
-
import { ArchiveSource, Env, Platform, Workflow, Cache, EnvironmentSecret,
|
|
2
|
+
import { ArchiveSource, Env, Platform, Workflow, Cache, EnvironmentSecret, BuildTrigger, BuildMode } from './common';
|
|
3
3
|
export declare type DistributionType = 'store' | 'internal' | 'simulator';
|
|
4
4
|
export interface TargetCredentials {
|
|
5
5
|
provisioningProfileBase64: string;
|
|
@@ -11,10 +11,8 @@ export interface DistributionCertificate {
|
|
|
11
11
|
dataBase64: string;
|
|
12
12
|
password: string;
|
|
13
13
|
}
|
|
14
|
-
export declare const builderBaseImages: readonly ["default", "latest", "stable", "macos-big-sur-11.4-xcode-12.5", "macos-big-sur-11.4-xcode-13.0", "macos-monterey-12.1-xcode-13.2", "macos-monterey-12.3-xcode-13.3", "macos-monterey-12.4-xcode-13.4", "macos-monterey-12.6-xcode-14.0", "macos-monterey-12.6-xcode-14.1"];
|
|
15
|
-
export declare const imageMatchRules: ImageMatchRule<typeof builderBaseImages[number]>[];
|
|
16
14
|
export interface BuilderEnvironment {
|
|
17
|
-
image?:
|
|
15
|
+
image?: string;
|
|
18
16
|
node?: string;
|
|
19
17
|
yarn?: string;
|
|
20
18
|
expoCli?: string;
|
package/dist/ios.js
CHANGED
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.JobSchema =
|
|
6
|
+
exports.JobSchema = void 0;
|
|
7
7
|
const joi_1 = __importDefault(require("joi"));
|
|
8
8
|
const common_1 = require("./common");
|
|
9
9
|
const TargetCredentialsSchema = joi_1.default.object().keys({
|
|
@@ -14,40 +14,8 @@ const TargetCredentialsSchema = joi_1.default.object().keys({
|
|
|
14
14
|
}).required(),
|
|
15
15
|
});
|
|
16
16
|
const BuildCredentialsSchema = joi_1.default.object().pattern(joi_1.default.string().required(), TargetCredentialsSchema);
|
|
17
|
-
exports.builderBaseImages = [
|
|
18
|
-
'default',
|
|
19
|
-
'latest',
|
|
20
|
-
'stable',
|
|
21
|
-
'macos-big-sur-11.4-xcode-12.5',
|
|
22
|
-
'macos-big-sur-11.4-xcode-13.0',
|
|
23
|
-
'macos-monterey-12.1-xcode-13.2',
|
|
24
|
-
'macos-monterey-12.3-xcode-13.3',
|
|
25
|
-
'macos-monterey-12.4-xcode-13.4',
|
|
26
|
-
'macos-monterey-12.6-xcode-14.0',
|
|
27
|
-
'macos-monterey-12.6-xcode-14.1',
|
|
28
|
-
];
|
|
29
|
-
exports.imageMatchRules = [
|
|
30
|
-
{
|
|
31
|
-
image: 'macos-big-sur-11.4-xcode-13.0',
|
|
32
|
-
sdkSemverRange: '<=44',
|
|
33
|
-
workflows: [common_1.Workflow.MANAGED],
|
|
34
|
-
},
|
|
35
|
-
{
|
|
36
|
-
image: 'macos-monterey-12.4-xcode-13.4',
|
|
37
|
-
sdkSemverRange: '>=45 <47',
|
|
38
|
-
workflows: [common_1.Workflow.MANAGED],
|
|
39
|
-
},
|
|
40
|
-
{
|
|
41
|
-
image: 'macos-monterey-12.6-xcode-14.0',
|
|
42
|
-
sdkSemverRange: '>=47',
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
image: 'macos-monterey-12.6-xcode-14.0',
|
|
46
|
-
reactNativeSemverRange: '>=0.70.0',
|
|
47
|
-
},
|
|
48
|
-
];
|
|
49
17
|
const BuilderEnvironmentSchema = joi_1.default.object({
|
|
50
|
-
image: joi_1.default.string()
|
|
18
|
+
image: joi_1.default.string(),
|
|
51
19
|
node: joi_1.default.string(),
|
|
52
20
|
yarn: joi_1.default.string(),
|
|
53
21
|
expoCli: joi_1.default.string(),
|
package/dist/ios.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ios.js","sourceRoot":"","sources":["../src/ios.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAsB;AAEtB,
|
|
1
|
+
{"version":3,"file":"ios.js","sourceRoot":"","sources":["../src/ios.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAsB;AAEtB,qCAakB;AAIlB,MAAM,uBAAuB,GAAG,aAAG,CAAC,MAAM,EAAE,CAAC,IAAI,CAAC;IAChD,yBAAyB,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAClD,uBAAuB,EAAE,aAAG,CAAC,MAAM,CAAC;QAClC,UAAU,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;QACnC,QAAQ,EAAE,aAAG,CAAC,M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chema,\n Platform,\n Workflow,\n Cache,\n CacheSchema,\n EnvironmentSecretsSchema,\n EnvironmentSecret,\n BuildTrigger,\n BuildMode,\n} from './common';\n\nexport type DistributionType = 'store' | 'internal' | 'simulator';\n\nconst TargetCredentialsSchema = Joi.object().keys({\n provisioningProfileBase64: Joi.string().required(),\n distributionCertificate: Joi.object({\n dataBase64: Joi.string().required(),\n password: Joi.string().allow('').required(),\n }).required(),\n});\n\nexport interface TargetCredentials {\n provisioningProfileBase64: string;\n distributionCertificate: DistributionCertificate;\n}\n\nconst BuildCredentialsSchema = Joi.object().pattern(\n Joi.string().required(),\n TargetCredentialsSchema\n);\n\ntype Target = string;\nexport type BuildCredentials = Record<Target, TargetCredentials>;\n\nexport interface DistributionCertificate {\n dataBase64: string;\n password: string;\n}\nexport interface BuilderEnvironment {\n image?: string;\n node?: string;\n yarn?: string;\n expoCli?: string;\n bundler?: string;\n fastlane?: string;\n cocoapods?: string;\n env?: Env;\n}\n\nconst BuilderEnvironmentSchema = Joi.object({\n image: Joi.string(),\n node: Joi.string(),\n yarn: Joi.string(),\n expoCli: Joi.string(),\n bundler: Joi.string(),\n fastlane: Joi.string(),\n cocoapods: Joi.string(),\n env: EnvSchema,\n});\n\nexport interface Job {\n mode: BuildMode;\n type: Workflow;\n triggeredBy: BuildTrigger;\n projectArchive: ArchiveSource;\n resign?: {\n applicationArchiveSource: ArchiveSource;\n };\n platform: Platform.IOS;\n projectRootDirectory?: string;\n buildProfile?: string;\n releaseChannel?: string;\n updates?: {\n channel?: string;\n };\n secrets: {\n buildCredentials?: BuildCredentials;\n environmentSecrets?: EnvironmentSecret[];\n robotAccessToken?: string;\n };\n builderEnvironment?: BuilderEnvironment;\n cache: Cache;\n developmentClient?: boolean;\n simulator?: boolean;\n version?: {\n buildNumber?: string;\n /**\n * support for this field is implemented, but specifying it is disabled on schema level\n */\n appVersion?: string;\n /**\n * support for this field is implemented, but specifying it is disabled on schema level\n */\n runtimeVersion?: string;\n };\n buildArtifactPaths?: string[];\n\n scheme?: string;\n buildConfiguration?: string;\n applicationArchivePath?: string;\n\n username?: string;\n\n experimental?: {\n prebuildCommand?: string;\n };\n}\n\nexport const JobSchema = Joi.object({\n mode: Joi.string()\n .valid(...Object.values(BuildMode))\n .default(BuildMode.BUILD),\n type: Joi.when('mode', {\n is: Joi.string().valid(BuildMode.BUILD),\n then: Joi.string()\n .valid(...Object.values(Workflow))\n .required(),\n otherwise: Joi.string().valid(Workflow.UNKNOWN).default(Workflow.UNKNOWN),\n }),\n triggeredBy: Joi.string()\n .valid(...Object.values(BuildTrigger))\n .default(BuildTrigger.EAS_CLI),\n projectArchive: ArchiveSourceSchema.required(),\n resign: Joi.when('mode', {\n is: Joi.string().valid(BuildMode.BUILD),\n then: Joi.any().strip(),\n otherwise: Joi.object({\n applicationArchiveSource: ArchiveSourceSchema.required(),\n }).required(),\n }),\n platform: Joi.string().valid(Platform.IOS).required(),\n projectRootDirectory: Joi.when('mode', {\n is: Joi.string().valid(BuildMode.BUILD),\n then: Joi.string().required(),\n otherwise: Joi.any().strip(),\n }),\n buildProfile: Joi.when('mode', {\n is: Joi.string().valid(BuildMode.BUILD),\n then: Joi.when('triggeredBy', {\n is: Joi.string().valid(BuildTrigger.GIT_BASED_INTEGRATION),\n then: Joi.string().required(),\n otherwise: Joi.string(),\n }),\n otherwise: Joi.string(),\n }),\n releaseChannel: Joi.string(),\n updates: Joi.object({\n channel: Joi.string(),\n }),\n secrets: Joi.object({\n buildCredentials: BuildCredentialsSchema,\n environmentSecrets: EnvironmentSecretsSchema,\n robotAccessToken: Joi.string(),\n }).required(),\n builderEnvironment: BuilderEnvironmentSchema,\n cache: CacheSchema.default(),\n developmentClient: Joi.boolean(),\n simulator: Joi.boolean(),\n version: Joi.object({\n buildNumber: Joi.string(),\n }),\n buildArtifactPaths: Joi.array().items(Joi.string()),\n\n scheme: Joi.string(),\n buildConfiguration: Joi.string(),\n applicationArchivePath: Joi.string(),\n\n username: Joi.string(),\n\n experimental: Joi.object({\n prebuildCommand: Joi.string(),\n }),\n}).oxor('releaseChannel', 'updates.channel');\n"]}
|
package/dist/job.d.ts
CHANGED
|
@@ -1,18 +1,6 @@
|
|
|
1
1
|
import Joi from 'joi';
|
|
2
|
-
import { Workflow } from './common';
|
|
3
2
|
import * as Android from './android';
|
|
4
3
|
import * as Ios from './ios';
|
|
5
4
|
export declare type Job = Android.Job | Ios.Job;
|
|
6
|
-
interface ImageMatchArgs {
|
|
7
|
-
sdkVersion?: string;
|
|
8
|
-
reactNativeVersion?: string;
|
|
9
|
-
workflow: Workflow;
|
|
10
|
-
}
|
|
11
5
|
export declare const JobSchema: Joi.ObjectSchema<Job>;
|
|
12
|
-
export declare function sanitizeJob(rawJob: object
|
|
13
|
-
reactNativeVersion?: string;
|
|
14
|
-
sdkVersion?: string;
|
|
15
|
-
}): Job;
|
|
16
|
-
export declare function setAndroidBuilderImage(job: Job, args: ImageMatchArgs): void;
|
|
17
|
-
export declare function setIosBuilderImage(job: Job, args: ImageMatchArgs): void;
|
|
18
|
-
export {};
|
|
6
|
+
export declare function sanitizeJob(rawJob: object): Job;
|
package/dist/job.js
CHANGED
|
@@ -26,9 +26,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
26
26
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
-
exports.
|
|
29
|
+
exports.sanitizeJob = exports.JobSchema = void 0;
|
|
30
30
|
const joi_1 = __importDefault(require("joi"));
|
|
31
|
-
const semver_1 = __importDefault(require("semver"));
|
|
32
31
|
const common_1 = require("./common");
|
|
33
32
|
const Android = __importStar(require("./android"));
|
|
34
33
|
const Ios = __importStar(require("./ios"));
|
|
@@ -39,27 +38,13 @@ exports.JobSchema = joi_1.default.object({
|
|
|
39
38
|
})
|
|
40
39
|
.when(joi_1.default.object({ platform: common_1.Platform.ANDROID }).unknown(), { then: Android.JobSchema })
|
|
41
40
|
.when(joi_1.default.object({ platform: common_1.Platform.IOS }).unknown(), { then: Ios.JobSchema });
|
|
42
|
-
function sanitizeJob(rawJob
|
|
43
|
-
var _a;
|
|
41
|
+
function sanitizeJob(rawJob) {
|
|
44
42
|
const { value, error } = exports.JobSchema.validate(rawJob, {
|
|
45
43
|
stripUnknown: true,
|
|
46
44
|
convert: true,
|
|
47
45
|
abortEarly: false,
|
|
48
46
|
});
|
|
49
47
|
const job = value;
|
|
50
|
-
if (!((_a = job === null || job === void 0 ? void 0 : job.builderEnvironment) === null || _a === void 0 ? void 0 : _a.image)) {
|
|
51
|
-
const resolveArgs = {
|
|
52
|
-
sdkVersion,
|
|
53
|
-
reactNativeVersion,
|
|
54
|
-
workflow: job.type,
|
|
55
|
-
};
|
|
56
|
-
if (job.platform === common_1.Platform.IOS) {
|
|
57
|
-
setIosBuilderImage(job, resolveArgs);
|
|
58
|
-
}
|
|
59
|
-
else if (job.platform === common_1.Platform.ANDROID) {
|
|
60
|
-
setAndroidBuilderImage(job, resolveArgs);
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
48
|
if (error) {
|
|
64
49
|
throw error;
|
|
65
50
|
}
|
|
@@ -68,40 +53,4 @@ function sanitizeJob(rawJob, { sdkVersion, reactNativeVersion } = {}) {
|
|
|
68
53
|
}
|
|
69
54
|
}
|
|
70
55
|
exports.sanitizeJob = sanitizeJob;
|
|
71
|
-
function doesImageRuleMatch(rule, { sdkVersion, reactNativeVersion, workflow }) {
|
|
72
|
-
if (rule.reactNativeSemverRange) {
|
|
73
|
-
if (!reactNativeVersion || !semver_1.default.satisfies(reactNativeVersion, rule.reactNativeSemverRange)) {
|
|
74
|
-
return false;
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
if (rule.sdkSemverRange) {
|
|
78
|
-
if (!sdkVersion || !semver_1.default.satisfies(sdkVersion, rule.sdkSemverRange)) {
|
|
79
|
-
return false;
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
if (rule.workflows) {
|
|
83
|
-
if (!workflow || !rule.workflows.includes(workflow)) {
|
|
84
|
-
return false;
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
return true;
|
|
88
|
-
}
|
|
89
|
-
function setAndroidBuilderImage(job, args) {
|
|
90
|
-
for (const rule of Android.imageMatchRules) {
|
|
91
|
-
if (doesImageRuleMatch(rule, args)) {
|
|
92
|
-
job.builderEnvironment = Object.assign(Object.assign({}, job.builderEnvironment), { image: rule.image });
|
|
93
|
-
return;
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
exports.setAndroidBuilderImage = setAndroidBuilderImage;
|
|
98
|
-
function setIosBuilderImage(job, args) {
|
|
99
|
-
for (const rule of Ios.imageMatchRules) {
|
|
100
|
-
if (doesImageRuleMatch(rule, args)) {
|
|
101
|
-
job.builderEnvironment = Object.assign(Object.assign({}, job.builderEnvironment), { image: rule.image });
|
|
102
|
-
return;
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
exports.setIosBuilderImage = setIosBuilderImage;
|
|
107
56
|
//# sourceMappingURL=job.js.map
|
package/dist/job.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"job.js","sourceRoot":"","sources":["../src/job.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,8CAAsB;
|
|
1
|
+
{"version":3,"file":"job.js","sourceRoot":"","sources":["../src/job.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,8CAAsB;AAEtB,qCAAoC;AACpC,mDAAqC;AACrC,2CAA6B;AAIhB,QAAA,SAAS,GAAG,aAAG,CAAC,MAAM,CAAM;IACvC,QAAQ,EAAE,aAAG,CAAC,MAAM,EAAE;SACnB,KAAK,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC,iBAAQ,CAAC,CAAC;SACjC,QAAQ,EAAE;CACd,CAAC;KACC,IAAI,CAAC,aAAG,CAAC,MAAM,CAAC,EAAE,QAAQ,EAAE,iBAAQ,CAAC,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,SAAS,EAAE,CAAC;KACvF,IAAI,CAAC,aAAG,CAAC,MAAM,CAAC,EAAE,QAAQ,EAAE,iBAAQ,CAAC,GAAG,EAAE,CAAC,CAAC,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,CAAC,SAAS,EAAE,CAAC,CAAC;AAEnF,SAAgB,WAAW,CAAC,MAAc;IACxC,MAAM,EAAE,KAAK,EAAE,KAAK,EAAE,GAAG,iBAAS,CAAC,QAAQ,CAAC,MAAM,EAAE;QAClD,YAAY,EAAE,IAAI;QAClB,OAAO,EAAE,IAAI;QACb,UAAU,EAAE,KAAK;KAClB,CAAC,CAAC;IAEH,MAAM,GAAG,GAAQ,KAAK,CAAC;IAEvB,IAAI,KAAK,EAAE;QACT,MAAM,KAAK,CAAC;KACb;SAAM;QACL,OAAO,GAAG,CAAC;KACZ;AACH,CAAC;AAdD,kCAcC","sourcesContent":["import Joi from 'joi';\n\nimport { Platform } from './common';\nimport * as Android from './android';\nimport * as Ios from './ios';\n\nexport type Job = Android.Job | Ios.Job;\n\nexport const JobSchema = Joi.object<Job>({\n platform: Joi.string()\n .valid(...Object.values(Platform))\n .required(),\n})\n .when(Joi.object({ platform: Platform.ANDROID }).unknown(), { then: Android.JobSchema })\n .when(Joi.object({ platform: Platform.IOS }).unknown(), { then: Ios.JobSchema });\n\nexport function sanitizeJob(rawJob: object): Job {\n const { value, error } = JobSchema.validate(rawJob, {\n stripUnknown: true,\n convert: true,\n abortEarly: false,\n });\n\n const job: Job = value;\n\n if (error) {\n throw error;\n } else {\n return job;\n }\n}\n"]}
|
package/dist/metadata.d.ts
CHANGED
|
@@ -110,6 +110,10 @@ export declare type Metadata = {
|
|
|
110
110
|
* Indicates whether the build was run with --no-wait flag.
|
|
111
111
|
*/
|
|
112
112
|
runWithNoWaitFlag?: boolean;
|
|
113
|
+
/**
|
|
114
|
+
* Build mode
|
|
115
|
+
*/
|
|
116
|
+
buildMode?: 'build' | 'resign';
|
|
113
117
|
};
|
|
114
118
|
export declare const MetadataSchema: Joi.ObjectSchema<any>;
|
|
115
119
|
export declare function sanitizeMetadata(metadata: object): Metadata;
|
package/dist/metadata.js
CHANGED
|
@@ -31,6 +31,7 @@ exports.MetadataSchema = joi_1.default.object({
|
|
|
31
31
|
message: joi_1.default.string().max(1024),
|
|
32
32
|
runFromCI: joi_1.default.boolean(),
|
|
33
33
|
runWithNoWaitFlag: joi_1.default.boolean(),
|
|
34
|
+
buildMode: joi_1.default.string().valid('build', 'resign'),
|
|
34
35
|
});
|
|
35
36
|
function sanitizeMetadata(metadata) {
|
|
36
37
|
const { value, error } = exports.MetadataSchema.validate(metadata, {
|
package/dist/metadata.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"metadata.js","sourceRoot":"","sources":["../src/metadata.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAsB;
|
|
1
|
+
{"version":3,"file":"metadata.js","sourceRoot":"","sources":["../src/metadata.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAsB;AA+IT,QAAA,cAAc,GAAG,aAAG,CAAC,MAAM,CAAC;IACvC,eAAe,EAAE,aAAG,CAAC,MAAM,EAAE;SAC1B,OAAO,CAAC,aAAG,CAAC,MAAM,EAAE,EAAE,CAAC,aAAG,CAAC,MAAM,EAAE,EAAE,aAAG,CAAC,MAAM,EAAE,EAAE,aAAG,CAAC,OAAO,EAAE,CAAC,CAAC;SAClE,QAAQ,EAAE;IACb,UAAU,EAAE,aAAG,CAAC,MAAM,EAAE;IACxB,eAAe,EAAE,aAAG,CAAC,MAAM,EAAE;IAC7B,UAAU,EAAE,aAAG,CAAC,MAAM,EAAE;IACxB,QAAQ,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,SAAS,EAAE,SAAS,CAAC;IAClD,Y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AC,QAAQ,EAAE;QACzD,YAAY,EAAE,IAAI;QAClB,OAAO,EAAE,IAAI;QACb,UAAU,EAAE,KAAK;KAClB,CAAC,CAAC;IACH,IAAI,KAAK,EAAE;QACT,MAAM,KAAK,CAAC;KACb;SAAM;QACL,OAAO,KAAK,CAAC;KACd;AACH,CAAC;AAXD,4CAWC","sourcesContent":["import Joi from 'joi';\n\nimport { Workflow } from './common';\n\nexport type Metadata = {\n /**\n * Tracking context\n * It's used to track build process across different Expo services and tools.\n */\n trackingContext: Record<string, string | number | boolean>;\n\n /**\n * Application version:\n * - managed projects: expo.version in app.json/app.config.js\n * - generic projects:\n * * iOS: CFBundleShortVersionString in Info.plist\n * * Android: versionName in build.gradle\n */\n appVersion?: string;\n\n /**\n * Application build version:\n * - Android: version code\n * - iOS: build number\n */\n appBuildVersion?: string;\n\n /**\n * EAS CLI version\n */\n cliVersion?: string;\n\n /**\n * Build workflow\n * It's either 'generic' or 'managed'\n */\n workflow?: Workflow;\n\n /**\n * Credentials source\n * Credentials could be obtained either from credential.json or EAS servers.\n */\n credentialsSource?: 'local' | 'remote';\n\n /**\n * Expo SDK version\n * It's determined by the expo package version in package.json.\n * It's undefined if the expo package is not installed for the project.\n */\n sdkVersion?: string;\n\n /**\n * Runtime version (for Expo Updates)\n */\n runtimeVersion?: string;\n\n /**\n * Release channel (for classic expo-updates)\n * It's undefined if the classic expo-updates package is not installed for the project.\n */\n releaseChannel?: string;\n\n /**\n * Version of the react-native package used in the project.\n */\n reactNativeVersion?: string;\n\n /**\n * Channel (for Expo Updates when it is configured for for use with EAS)\n * It's undefined if the expo-updates package is not configured for use with EAS.\n */\n channel?: string;\n\n /**\n * Distribution type\n * Indicates whether this is a build for store, internal distribution, or simulator (iOS).\n */\n distribution?: 'store' | 'internal' | 'simulator';\n\n /**\n * App name (expo.name in app.json/app.config.js)\n */\n appName?: string;\n\n /**\n * App identifier:\n * - iOS builds: the bundle identifier (expo.ios.bundleIdentifier in app.json/app.config.js)\n * - Android builds: the application id (expo.android.package in app.json/app.config.js)\n */\n appIdentifier?: string;\n\n /**\n * Build profile name (e.g. release)\n */\n buildProfile?: string;\n\n /**\n * Git commit hash (e.g. aab03fbdabb6e536ea78b28df91575ad488f5f21)\n */\n gitCommitHash?: string;\n\n /**\n * Git commit message\n */\n gitCommitMessage?: string;\n\n /**\n * State of the git working tree\n */\n isGitWorkingTreeDirty?: boolean;\n\n /**\n * Username of the initiating user\n */\n username?: string;\n\n /**\n * Indicates what type of an enterprise provisioning profile was used to build the app.\n * It's either adhoc or universal\n */\n iosEnterpriseProvisioning?: 'adhoc' | 'universal';\n\n /**\n * Message attached to the build.\n */\n message?: string;\n\n /**\n * Indicates whether the build was run from CI.\n */\n runFromCI?: boolean;\n\n /**\n * Indicates whether the build was run with --no-wait flag.\n */\n runWithNoWaitFlag?: boolean;\n\n /**\n * Build mode\n */\n buildMode?: 'build' | 'resign';\n};\n\nexport const MetadataSchema = Joi.object({\n trackingContext: Joi.object()\n .pattern(Joi.string(), [Joi.string(), Joi.number(), Joi.boolean()])\n .required(),\n appVersion: Joi.string(),\n appBuildVersion: Joi.string(),\n cliVersion: Joi.string(),\n workflow: Joi.string().valid('generic', 'managed'),\n distribution: Joi.string().valid('store', 'internal', 'simulator'),\n credentialsSource: Joi.string().valid('local', 'remote'),\n sdkVersion: Joi.string(),\n runtimeVersion: Joi.string(),\n reactNativeVersion: Joi.string(),\n releaseChannel: Joi.string(),\n channel: Joi.string(),\n appName: Joi.string(),\n appIdentifier: Joi.string(),\n buildProfile: Joi.string(),\n gitCommitHash: Joi.string().length(40).hex(),\n gitCommitMessage: Joi.string().max(4096),\n isGitWorkingTreeDirty: Joi.boolean(),\n username: Joi.string(),\n iosEnterpriseProvisioning: Joi.string().valid('adhoc', 'universal'),\n message: Joi.string().max(1024),\n runFromCI: Joi.boolean(),\n runWithNoWaitFlag: Joi.boolean(),\n buildMode: Joi.string().valid('build', 'resign'),\n});\n\nexport function sanitizeMetadata(metadata: object): Metadata {\n const { value, error } = MetadataSchema.validate(metadata, {\n stripUnknown: true,\n convert: true,\n abortEarly: false,\n });\n if (error) {\n throw error;\n } else {\n return value;\n }\n}\n"]}
|