eas-cli 0.55.0 → 0.57.0
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/README.md +58 -49
- package/build/branch/queries.d.ts +5 -0
- package/build/branch/queries.js +87 -0
- package/build/build/android/version.d.ts +5 -0
- package/build/build/android/version.js +16 -9
- package/build/build/build.js +7 -2
- package/build/build/context.d.ts +3 -3
- package/build/build/createContext.d.ts +4 -2
- package/build/build/createContext.js +3 -1
- package/build/build/ios/build.js +1 -16
- package/build/build/ios/syncProjectConfiguration.d.ts +3 -3
- package/build/build/ios/syncProjectConfiguration.js +2 -2
- package/build/build/ios/version.d.ts +10 -3
- package/build/build/ios/version.js +57 -28
- package/build/build/metadata.d.ts +1 -0
- package/build/build/metadata.js +15 -5
- package/build/build/runBuildAndSubmit.d.ts +1 -0
- package/build/build/runBuildAndSubmit.js +8 -4
- package/build/commandUtils/pagination.d.ts +13 -0
- package/build/commandUtils/pagination.js +42 -0
- package/build/commands/branch/list.d.ts +3 -4
- package/build/commands/branch/list.js +6 -69
- package/build/commands/branch/view.d.ts +3 -0
- package/build/commands/branch/view.js +15 -63
- package/build/commands/build/index.d.ts +1 -0
- package/build/commands/build/index.js +9 -0
- package/build/commands/build/version/set.d.ts +10 -0
- package/build/commands/build/version/set.js +82 -0
- package/build/commands/build/version/sync.d.ts +12 -0
- package/build/commands/build/version/sync.js +124 -0
- package/build/commands/update/index.d.ts +2 -2
- package/build/commands/update/index.js +13 -5
- package/build/commands/update/list.js +13 -18
- package/build/credentials/ios/actions/SetUpAdhocProvisioningProfile.js +2 -2
- package/build/credentials/ios/types.d.ts +2 -0
- package/build/devices/actions/create/action.d.ts +5 -2
- package/build/devices/actions/create/action.js +12 -2
- package/build/devices/actions/create/developerPortalMethod.d.ts +6 -0
- package/build/devices/actions/create/developerPortalMethod.js +90 -0
- package/build/devices/manager.js +4 -4
- package/build/graphql/generated.d.ts +271 -59
- package/build/graphql/generated.js +8 -1
- package/build/graphql/mutations/AppVersionMutation.d.ts +11 -0
- package/build/graphql/mutations/AppVersionMutation.js +28 -0
- package/build/graphql/queries/AppVersionQuery.d.ts +4 -0
- package/build/graphql/queries/AppVersionQuery.js +37 -0
- package/build/graphql/queries/BranchQuery.d.ts +2 -1
- package/build/graphql/queries/BranchQuery.js +26 -0
- package/build/graphql/queries/UpdateQuery.d.ts +6 -8
- package/build/graphql/queries/UpdateQuery.js +27 -23
- package/build/platform.d.ts +1 -0
- package/build/platform.js +17 -1
- package/build/project/android/applicationId.js +2 -2
- package/build/project/android/versions.d.ts +3 -0
- package/build/project/android/versions.js +23 -0
- package/build/project/applicationIdentifier.d.ts +4 -0
- package/build/project/applicationIdentifier.js +37 -0
- package/build/project/ios/bundleIdentifier.js +2 -2
- package/build/project/ios/target.js +14 -1
- package/build/project/ios/versions.d.ts +3 -0
- package/build/project/ios/versions.js +17 -0
- package/build/project/publish.d.ts +1 -2
- package/build/project/publish.js +8 -12
- package/build/project/remoteVersionSource.d.ts +6 -0
- package/build/project/remoteVersionSource.js +52 -0
- package/build/submit/utils/files.js +1 -1
- package/build/update/queries.d.ts +3 -0
- package/build/update/queries.js +72 -0
- package/build/update/utils.d.ts +14 -0
- package/build/update/utils.js +26 -9
- package/build/uploads.d.ts +4 -3
- package/build/uploads.js +11 -9
- package/build/utils/expodash/chunk.d.ts +1 -0
- package/build/utils/expodash/chunk.js +16 -0
- package/build/utils/queries.d.ts +25 -0
- package/build/utils/queries.js +67 -0
- package/oclif.manifest.json +1 -1
- package/package.json +10 -5
package/build/build/context.d.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { ExpoConfig } from '@expo/config';
|
|
2
2
|
import { Platform, Workflow } from '@expo/eas-build-job';
|
|
3
|
-
import { BuildProfile } from '@expo/eas-json';
|
|
4
|
-
import type { XCBuildConfiguration } from 'xcode';
|
|
3
|
+
import { BuildProfile, EasJson } from '@expo/eas-json';
|
|
5
4
|
import { TrackingContext } from '../analytics/common';
|
|
6
5
|
import { CredentialsContext } from '../credentials/context';
|
|
7
6
|
import { Target } from '../credentials/ios/types';
|
|
@@ -17,13 +16,13 @@ export interface AndroidBuildContext {
|
|
|
17
16
|
}
|
|
18
17
|
export interface IosBuildContext {
|
|
19
18
|
bundleIdentifier: string;
|
|
20
|
-
applicationTargetBuildSettings: XCBuildConfiguration['buildSettings'];
|
|
21
19
|
applicationTarget: Target;
|
|
22
20
|
targets: Target[];
|
|
23
21
|
xcodeBuildContext: XcodeBuildContext;
|
|
24
22
|
}
|
|
25
23
|
export interface BuildContext<T extends Platform> {
|
|
26
24
|
accountName: string;
|
|
25
|
+
easJsonCliConfig: EasJson['cli'];
|
|
27
26
|
buildProfile: BuildProfile<T>;
|
|
28
27
|
buildProfileName: string;
|
|
29
28
|
resourceClass: BuildResourceClass;
|
|
@@ -36,6 +35,7 @@ export interface BuildContext<T extends Platform> {
|
|
|
36
35
|
projectDir: string;
|
|
37
36
|
projectId: string;
|
|
38
37
|
projectName: string;
|
|
38
|
+
message?: string;
|
|
39
39
|
trackingCtx: TrackingContext;
|
|
40
40
|
user: Actor;
|
|
41
41
|
workflow: Workflow;
|
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
import { Platform } from '@expo/eas-build-job';
|
|
2
|
-
import { BuildProfile } from '@expo/eas-json';
|
|
2
|
+
import { BuildProfile, EasJson } from '@expo/eas-json';
|
|
3
3
|
import { BuildResourceClass } from '../graphql/generated';
|
|
4
4
|
import { BuildContext } from './context';
|
|
5
5
|
import { LocalBuildOptions } from './local';
|
|
6
|
-
export declare function createBuildContextAsync<T extends Platform>({ buildProfileName, buildProfile, clearCache, localBuildOptions, nonInteractive, platform, projectDir, resourceClass, }: {
|
|
6
|
+
export declare function createBuildContextAsync<T extends Platform>({ buildProfileName, buildProfile, easJsonCliConfig, clearCache, localBuildOptions, nonInteractive, platform, projectDir, resourceClass, message, }: {
|
|
7
7
|
buildProfileName: string;
|
|
8
8
|
buildProfile: BuildProfile<T>;
|
|
9
|
+
easJsonCliConfig: EasJson['cli'];
|
|
9
10
|
clearCache: boolean;
|
|
10
11
|
localBuildOptions: LocalBuildOptions;
|
|
11
12
|
nonInteractive: boolean;
|
|
12
13
|
platform: T;
|
|
13
14
|
projectDir: string;
|
|
14
15
|
resourceClass: BuildResourceClass;
|
|
16
|
+
message?: string;
|
|
15
17
|
}): Promise<BuildContext<T>>;
|
|
@@ -15,7 +15,7 @@ const Account_1 = require("../user/Account");
|
|
|
15
15
|
const actions_1 = require("../user/actions");
|
|
16
16
|
const build_1 = require("./android/build");
|
|
17
17
|
const build_2 = require("./ios/build");
|
|
18
|
-
async function createBuildContextAsync({ buildProfileName, buildProfile, clearCache = false, localBuildOptions, nonInteractive = false, platform, projectDir, resourceClass, }) {
|
|
18
|
+
async function createBuildContextAsync({ buildProfileName, buildProfile, easJsonCliConfig, clearCache = false, localBuildOptions, nonInteractive = false, platform, projectDir, resourceClass, message, }) {
|
|
19
19
|
var _a;
|
|
20
20
|
const exp = (0, expoConfig_1.getExpoConfig)(projectDir, { env: buildProfile.env });
|
|
21
21
|
const user = await (0, actions_1.ensureLoggedInAsync)();
|
|
@@ -50,6 +50,7 @@ async function createBuildContextAsync({ buildProfileName, buildProfile, clearCa
|
|
|
50
50
|
buildProfile,
|
|
51
51
|
buildProfileName,
|
|
52
52
|
resourceClass,
|
|
53
|
+
easJsonCliConfig,
|
|
53
54
|
clearCache,
|
|
54
55
|
credentialsCtx,
|
|
55
56
|
exp,
|
|
@@ -62,6 +63,7 @@ async function createBuildContextAsync({ buildProfileName, buildProfile, clearCa
|
|
|
62
63
|
trackingCtx,
|
|
63
64
|
user,
|
|
64
65
|
workflow,
|
|
66
|
+
message,
|
|
65
67
|
};
|
|
66
68
|
if (platform === eas_build_job_1.Platform.ANDROID) {
|
|
67
69
|
const common = commonContext;
|
package/build/build/ios/build.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.prepareIosBuildAsync = exports.createIosContextAsync = void 0;
|
|
4
|
-
const config_plugins_1 = require("@expo/config-plugins");
|
|
5
4
|
const eas_build_job_1 = require("@expo/eas-build-job");
|
|
6
5
|
const BuildMutation_1 = require("../../graphql/mutations/BuildMutation");
|
|
7
6
|
const bundleIdentifier_1 = require("../../project/ios/bundleIdentifier");
|
|
@@ -33,11 +32,9 @@ async function createIosContextAsync(ctx) {
|
|
|
33
32
|
env: buildProfile.env,
|
|
34
33
|
});
|
|
35
34
|
const applicationTarget = (0, target_1.findApplicationTarget)(targets);
|
|
36
|
-
const applicationTargetBuildSettings = resolveBuildSettings(ctx, applicationTarget);
|
|
37
35
|
return {
|
|
38
36
|
bundleIdentifier: applicationTarget.bundleIdentifier,
|
|
39
37
|
applicationTarget,
|
|
40
|
-
applicationTargetBuildSettings,
|
|
41
38
|
targets,
|
|
42
39
|
xcodeBuildContext,
|
|
43
40
|
};
|
|
@@ -54,7 +51,7 @@ async function prepareIosBuildAsync(ctx) {
|
|
|
54
51
|
projectDir: ctx.projectDir,
|
|
55
52
|
exp: ctx.exp,
|
|
56
53
|
buildProfile: ctx.buildProfile,
|
|
57
|
-
|
|
54
|
+
targets: ctx.ios.targets,
|
|
58
55
|
});
|
|
59
56
|
},
|
|
60
57
|
prepareJobAsync: async (ctx, jobData) => {
|
|
@@ -76,15 +73,3 @@ async function prepareIosBuildAsync(ctx) {
|
|
|
76
73
|
});
|
|
77
74
|
}
|
|
78
75
|
exports.prepareIosBuildAsync = prepareIosBuildAsync;
|
|
79
|
-
function resolveBuildSettings(ctx, applicationTarget) {
|
|
80
|
-
var _a;
|
|
81
|
-
if (ctx.workflow === eas_build_job_1.Workflow.MANAGED) {
|
|
82
|
-
return {};
|
|
83
|
-
}
|
|
84
|
-
const project = config_plugins_1.IOSConfig.XcodeUtils.getPbxproj(ctx.projectDir);
|
|
85
|
-
const xcBuildConfiguration = config_plugins_1.IOSConfig.Target.getXCBuildConfigurationFromPbxproj(project, {
|
|
86
|
-
targetName: applicationTarget.targetName,
|
|
87
|
-
buildConfiguration: applicationTarget.buildConfiguration,
|
|
88
|
-
});
|
|
89
|
-
return (_a = xcBuildConfiguration === null || xcBuildConfiguration === void 0 ? void 0 : xcBuildConfiguration.buildSettings) !== null && _a !== void 0 ? _a : {};
|
|
90
|
-
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { ExpoConfig } from '@expo/config';
|
|
2
2
|
import { Platform } from '@expo/eas-build-job';
|
|
3
3
|
import { BuildProfile } from '@expo/eas-json';
|
|
4
|
-
import
|
|
5
|
-
export declare function syncProjectConfigurationAsync({ projectDir, exp, buildProfile,
|
|
4
|
+
import { Target } from '../../credentials/ios/types';
|
|
5
|
+
export declare function syncProjectConfigurationAsync({ projectDir, exp, buildProfile, targets, }: {
|
|
6
6
|
projectDir: string;
|
|
7
7
|
exp: ExpoConfig;
|
|
8
8
|
buildProfile: BuildProfile<Platform.IOS>;
|
|
9
|
-
|
|
9
|
+
targets: Target[];
|
|
10
10
|
}): Promise<void>;
|
|
@@ -6,7 +6,7 @@ const projectUtils_1 = require("../../project/projectUtils");
|
|
|
6
6
|
const workflow_1 = require("../../project/workflow");
|
|
7
7
|
const UpdatesModule_1 = require("../../update/ios/UpdatesModule");
|
|
8
8
|
const version_1 = require("./version");
|
|
9
|
-
async function syncProjectConfigurationAsync({ projectDir, exp, buildProfile,
|
|
9
|
+
async function syncProjectConfigurationAsync({ projectDir, exp, buildProfile, targets, }) {
|
|
10
10
|
const workflow = await (0, workflow_1.resolveWorkflowAsync)(projectDir, eas_build_job_1.Platform.IOS);
|
|
11
11
|
const { autoIncrement } = buildProfile;
|
|
12
12
|
const versionBumpStrategy = resolveVersionBumpStrategy(autoIncrement !== null && autoIncrement !== void 0 ? autoIncrement : false);
|
|
@@ -14,7 +14,7 @@ async function syncProjectConfigurationAsync({ projectDir, exp, buildProfile, bu
|
|
|
14
14
|
if ((0, projectUtils_1.isExpoUpdatesInstalled)(projectDir)) {
|
|
15
15
|
await (0, UpdatesModule_1.syncUpdatesConfigurationAsync)(projectDir, exp);
|
|
16
16
|
}
|
|
17
|
-
await (0, version_1.bumpVersionAsync)({ projectDir, exp, bumpStrategy: versionBumpStrategy,
|
|
17
|
+
await (0, version_1.bumpVersionAsync)({ projectDir, exp, bumpStrategy: versionBumpStrategy, targets });
|
|
18
18
|
}
|
|
19
19
|
else {
|
|
20
20
|
await (0, version_1.bumpVersionInAppJsonAsync)({ projectDir, exp, bumpStrategy: versionBumpStrategy });
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { ExpoConfig } from '@expo/config';
|
|
2
2
|
import type { XCBuildConfiguration } from 'xcode';
|
|
3
|
+
import { Target } from '../../credentials/ios/types';
|
|
3
4
|
export declare enum BumpStrategy {
|
|
4
5
|
APP_VERSION = 0,
|
|
5
6
|
BUILD_NUMBER = 1,
|
|
6
7
|
NOOP = 2
|
|
7
8
|
}
|
|
8
|
-
export declare function bumpVersionAsync({ bumpStrategy, projectDir, exp,
|
|
9
|
+
export declare function bumpVersionAsync({ bumpStrategy, projectDir, exp, targets, }: {
|
|
9
10
|
projectDir: string;
|
|
10
11
|
exp: ExpoConfig;
|
|
11
12
|
bumpStrategy: BumpStrategy;
|
|
12
|
-
|
|
13
|
+
targets: Target[];
|
|
13
14
|
}): Promise<void>;
|
|
14
15
|
export declare function bumpVersionInAppJsonAsync({ bumpStrategy, projectDir, exp, }: {
|
|
15
16
|
bumpStrategy: BumpStrategy;
|
|
@@ -18,9 +19,15 @@ export declare function bumpVersionInAppJsonAsync({ bumpStrategy, projectDir, ex
|
|
|
18
19
|
}): Promise<void>;
|
|
19
20
|
export declare function readShortVersionAsync(projectDir: string, exp: ExpoConfig, buildSettings: XCBuildConfiguration['buildSettings']): Promise<string | undefined>;
|
|
20
21
|
export declare function readBuildNumberAsync(projectDir: string, exp: ExpoConfig, buildSettings: XCBuildConfiguration['buildSettings']): Promise<string | undefined>;
|
|
21
|
-
export declare function maybeResolveVersionsAsync(projectDir: string, exp: ExpoConfig,
|
|
22
|
+
export declare function maybeResolveVersionsAsync(projectDir: string, exp: ExpoConfig, targets: Target[]): Promise<{
|
|
22
23
|
appVersion?: string;
|
|
23
24
|
appBuildVersion?: string;
|
|
24
25
|
}>;
|
|
25
26
|
export declare function getInfoPlistPath(projectDir: string, buildSettings: XCBuildConfiguration['buildSettings']): string;
|
|
27
|
+
export declare function updateNativeVersionsAsync({ projectDir, version, buildNumber, targets, }: {
|
|
28
|
+
projectDir: string;
|
|
29
|
+
version?: string;
|
|
30
|
+
buildNumber?: string;
|
|
31
|
+
targets: Target[];
|
|
32
|
+
}): Promise<void>;
|
|
26
33
|
export declare function evaluateTemplateString(s: string, buildSettings: XCBuildConfiguration['buildSettings']): string;
|
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.evaluateTemplateString = exports.getInfoPlistPath = exports.maybeResolveVersionsAsync = exports.readBuildNumberAsync = exports.readShortVersionAsync = exports.bumpVersionInAppJsonAsync = exports.bumpVersionAsync = exports.BumpStrategy = void 0;
|
|
3
|
+
exports.evaluateTemplateString = exports.updateNativeVersionsAsync = exports.getInfoPlistPath = exports.maybeResolveVersionsAsync = exports.readBuildNumberAsync = exports.readShortVersionAsync = exports.bumpVersionInAppJsonAsync = exports.bumpVersionAsync = exports.BumpStrategy = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
|
-
const config_1 = require("@expo/config");
|
|
6
5
|
const config_plugins_1 = require("@expo/config-plugins");
|
|
7
6
|
const eas_build_job_1 = require("@expo/eas-build-job");
|
|
8
7
|
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
9
8
|
const path_1 = tslib_1.__importDefault(require("path"));
|
|
10
9
|
const log_1 = tslib_1.__importDefault(require("../../log"));
|
|
10
|
+
const target_1 = require("../../project/ios/target");
|
|
11
|
+
const versions_1 = require("../../project/ios/versions");
|
|
11
12
|
const workflow_1 = require("../../project/workflow");
|
|
12
13
|
const prompts_1 = require("../../prompts");
|
|
14
|
+
const uniqBy_1 = tslib_1.__importDefault(require("../../utils/expodash/uniqBy"));
|
|
13
15
|
const plist_1 = require("../../utils/plist");
|
|
14
16
|
const appJson_1 = require("../utils/appJson");
|
|
15
17
|
const version_1 = require("../utils/version");
|
|
@@ -19,15 +21,20 @@ var BumpStrategy;
|
|
|
19
21
|
BumpStrategy[BumpStrategy["BUILD_NUMBER"] = 1] = "BUILD_NUMBER";
|
|
20
22
|
BumpStrategy[BumpStrategy["NOOP"] = 2] = "NOOP";
|
|
21
23
|
})(BumpStrategy = exports.BumpStrategy || (exports.BumpStrategy = {}));
|
|
22
|
-
async function bumpVersionAsync({ bumpStrategy, projectDir, exp,
|
|
24
|
+
async function bumpVersionAsync({ bumpStrategy, projectDir, exp, targets, }) {
|
|
25
|
+
var _a;
|
|
23
26
|
if (bumpStrategy === BumpStrategy.NOOP) {
|
|
24
27
|
return;
|
|
25
28
|
}
|
|
26
|
-
ensureStaticConfigExists(projectDir);
|
|
27
|
-
const infoPlist = await readInfoPlistAsync(projectDir, buildSettings);
|
|
29
|
+
(0, version_1.ensureStaticConfigExists)(projectDir);
|
|
28
30
|
await bumpVersionInAppJsonAsync({ bumpStrategy, projectDir, exp });
|
|
29
31
|
log_1.default.log('Updated versions in app.json');
|
|
30
|
-
await
|
|
32
|
+
await updateNativeVersionsAsync({
|
|
33
|
+
projectDir,
|
|
34
|
+
version: exp.version,
|
|
35
|
+
buildNumber: (_a = exp.ios) === null || _a === void 0 ? void 0 : _a.buildNumber,
|
|
36
|
+
targets,
|
|
37
|
+
});
|
|
31
38
|
log_1.default.log('Synchronized versions with Info.plist');
|
|
32
39
|
}
|
|
33
40
|
exports.bumpVersionAsync = bumpVersionAsync;
|
|
@@ -35,7 +42,7 @@ async function bumpVersionInAppJsonAsync({ bumpStrategy, projectDir, exp, }) {
|
|
|
35
42
|
if (bumpStrategy === BumpStrategy.NOOP) {
|
|
36
43
|
return;
|
|
37
44
|
}
|
|
38
|
-
ensureStaticConfigExists(projectDir);
|
|
45
|
+
(0, version_1.ensureStaticConfigExists)(projectDir);
|
|
39
46
|
log_1.default.addNewLineIfNone();
|
|
40
47
|
if (bumpStrategy === BumpStrategy.APP_VERSION) {
|
|
41
48
|
const appVersion = config_plugins_1.IOSConfig.Version.getVersion(exp);
|
|
@@ -43,10 +50,8 @@ async function bumpVersionInAppJsonAsync({ bumpStrategy, projectDir, exp, }) {
|
|
|
43
50
|
}
|
|
44
51
|
else {
|
|
45
52
|
const buildNumber = config_plugins_1.IOSConfig.Version.getBuildNumber(exp);
|
|
46
|
-
if (
|
|
47
|
-
const
|
|
48
|
-
comps[comps.length - 1] = String(Number(comps[comps.length - 1]) + 1);
|
|
49
|
-
const bumpedBuildNumber = comps.join('.');
|
|
53
|
+
if ((0, versions_1.isValidBuildNumber)(buildNumber)) {
|
|
54
|
+
const bumpedBuildNumber = (0, versions_1.getNextBuildNumber)(buildNumber);
|
|
50
55
|
log_1.default.log(`Bumping ${chalk_1.default.bold('expo.ios.buildNumber')} from ${chalk_1.default.bold(buildNumber)} to ${chalk_1.default.bold(bumpedBuildNumber)}`);
|
|
51
56
|
await (0, appJson_1.updateAppJsonConfigAsync)({ projectDir, exp }, config => {
|
|
52
57
|
config.ios = { ...config.ios, buildNumber: String(bumpedBuildNumber) };
|
|
@@ -89,11 +94,13 @@ async function readBuildNumberAsync(projectDir, exp, buildSettings) {
|
|
|
89
94
|
}
|
|
90
95
|
}
|
|
91
96
|
exports.readBuildNumberAsync = readBuildNumberAsync;
|
|
92
|
-
async function maybeResolveVersionsAsync(projectDir, exp,
|
|
97
|
+
async function maybeResolveVersionsAsync(projectDir, exp, targets) {
|
|
98
|
+
var _a, _b;
|
|
99
|
+
const applicationTarget = (0, target_1.findApplicationTarget)(targets);
|
|
93
100
|
try {
|
|
94
101
|
return {
|
|
95
|
-
appBuildVersion: await readBuildNumberAsync(projectDir, exp, buildSettings),
|
|
96
|
-
appVersion: await readShortVersionAsync(projectDir, exp, buildSettings),
|
|
102
|
+
appBuildVersion: await readBuildNumberAsync(projectDir, exp, (_a = applicationTarget.buildSettings) !== null && _a !== void 0 ? _a : {}),
|
|
103
|
+
appVersion: await readShortVersionAsync(projectDir, exp, (_b = applicationTarget.buildSettings) !== null && _b !== void 0 ? _b : {}),
|
|
97
104
|
};
|
|
98
105
|
}
|
|
99
106
|
catch (err) {
|
|
@@ -105,12 +112,6 @@ async function maybeResolveVersionsAsync(projectDir, exp, buildSettings) {
|
|
|
105
112
|
}
|
|
106
113
|
}
|
|
107
114
|
exports.maybeResolveVersionsAsync = maybeResolveVersionsAsync;
|
|
108
|
-
async function writeVersionsToInfoPlistAsync({ projectDir, exp, infoPlist, buildSettings, }) {
|
|
109
|
-
let updatedInfoPlist = config_plugins_1.IOSConfig.Version.setVersion(exp, infoPlist);
|
|
110
|
-
updatedInfoPlist = config_plugins_1.IOSConfig.Version.setBuildNumber(exp, updatedInfoPlist);
|
|
111
|
-
await writeInfoPlistAsync({ projectDir, infoPlist: updatedInfoPlist, buildSettings });
|
|
112
|
-
return updatedInfoPlist;
|
|
113
|
-
}
|
|
114
115
|
function getInfoPlistPath(projectDir, buildSettings) {
|
|
115
116
|
if (buildSettings.INFOPLIST_FILE) {
|
|
116
117
|
const infoPlistFile = buildSettings.INFOPLIST_FILE.startsWith('"')
|
|
@@ -133,16 +134,44 @@ async function readInfoPlistAsync(projectDir, buildSettings) {
|
|
|
133
134
|
const infoPlistPath = getInfoPlistPath(projectDir, buildSettings);
|
|
134
135
|
return ((_a = (await (0, plist_1.readPlistAsync)(infoPlistPath))) !== null && _a !== void 0 ? _a : {});
|
|
135
136
|
}
|
|
136
|
-
async function
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
const
|
|
142
|
-
|
|
143
|
-
|
|
137
|
+
async function updateNativeVersionsAsync({ projectDir, version, buildNumber, targets, }) {
|
|
138
|
+
var _a;
|
|
139
|
+
const project = config_plugins_1.IOSConfig.XcodeUtils.getPbxproj(projectDir);
|
|
140
|
+
const iosDir = path_1.default.join(projectDir, 'ios');
|
|
141
|
+
const infoPlistFiles = [];
|
|
142
|
+
for (const target of targets) {
|
|
143
|
+
const { targetName, buildConfiguration } = target;
|
|
144
|
+
const xcBuildConfiguration = config_plugins_1.IOSConfig.Target.getXCBuildConfigurationFromPbxproj(project, {
|
|
145
|
+
targetName,
|
|
146
|
+
buildConfiguration,
|
|
147
|
+
});
|
|
148
|
+
const infoPlist = (_a = xcBuildConfiguration === null || xcBuildConfiguration === void 0 ? void 0 : xcBuildConfiguration.buildSettings) === null || _a === void 0 ? void 0 : _a.INFOPLIST_FILE;
|
|
149
|
+
if (infoPlist) {
|
|
150
|
+
const evaluatedInfoPlistPath = trimQuotes(evaluateTemplateString(infoPlist, {
|
|
151
|
+
SRCROOT: iosDir,
|
|
152
|
+
}));
|
|
153
|
+
const absolutePath = path_1.default.isAbsolute(evaluatedInfoPlistPath)
|
|
154
|
+
? evaluatedInfoPlistPath
|
|
155
|
+
: path_1.default.join(iosDir, evaluatedInfoPlistPath);
|
|
156
|
+
infoPlistFiles.push(path_1.default.normalize(absolutePath));
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
const uniqueInfoPlistPaths = (0, uniqBy_1.default)(infoPlistFiles, i => i);
|
|
160
|
+
for (const infoPlistPath of uniqueInfoPlistPaths) {
|
|
161
|
+
const infoPlist = (await (0, plist_1.readPlistAsync)(infoPlistPath));
|
|
162
|
+
if (buildNumber) {
|
|
163
|
+
infoPlist.CFBundleVersion = buildNumber;
|
|
164
|
+
}
|
|
165
|
+
if (version) {
|
|
166
|
+
infoPlist.CFBundleShortVersionString = version;
|
|
167
|
+
}
|
|
168
|
+
await (0, plist_1.writePlistAsync)(infoPlistPath, infoPlist);
|
|
144
169
|
}
|
|
145
170
|
}
|
|
171
|
+
exports.updateNativeVersionsAsync = updateNativeVersionsAsync;
|
|
172
|
+
function trimQuotes(s) {
|
|
173
|
+
return (s === null || s === void 0 ? void 0 : s.startsWith('"')) && s.endsWith('"') ? s.slice(1, -1) : s;
|
|
174
|
+
}
|
|
146
175
|
function evaluateTemplateString(s, buildSettings) {
|
|
147
176
|
// necessary because XCBuildConfiguration['buildSettings'] is not a plain object
|
|
148
177
|
const vars = { ...buildSettings };
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import { Metadata, Platform } from '@expo/eas-build-job';
|
|
2
2
|
import { BuildContext } from './context';
|
|
3
3
|
export declare function collectMetadataAsync<T extends Platform>(ctx: BuildContext<T>): Promise<Metadata>;
|
|
4
|
+
export declare function truncateGitCommitMessage(msg: string | undefined, maxLength?: number): string | undefined;
|
package/build/build/metadata.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.collectMetadataAsync = void 0;
|
|
3
|
+
exports.truncateGitCommitMessage = exports.collectMetadataAsync = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const config_plugins_1 = require("@expo/config-plugins");
|
|
6
6
|
const eas_build_job_1 = require("@expo/eas-build-job");
|
|
@@ -16,7 +16,8 @@ const vcs_1 = require("../vcs");
|
|
|
16
16
|
const version_1 = require("./android/version");
|
|
17
17
|
const version_2 = require("./ios/version");
|
|
18
18
|
async function collectMetadataAsync(ctx) {
|
|
19
|
-
var _a, _b;
|
|
19
|
+
var _a, _b, _c;
|
|
20
|
+
const vcsClient = (0, vcs_1.getVcsClient)();
|
|
20
21
|
const channelOrReleaseChannel = await resolveChannelOrReleaseChannelAsync(ctx);
|
|
21
22
|
const distribution = (_a = ('simulator' in ctx.buildProfile && ctx.buildProfile.simulator
|
|
22
23
|
? 'simulator'
|
|
@@ -35,9 +36,11 @@ async function collectMetadataAsync(ctx) {
|
|
|
35
36
|
appName: ctx.exp.name,
|
|
36
37
|
appIdentifier: resolveAppIdentifier(ctx),
|
|
37
38
|
buildProfile: ctx.buildProfileName,
|
|
38
|
-
gitCommitHash: await
|
|
39
|
-
|
|
39
|
+
gitCommitHash: await vcsClient.getCommitHashAsync(),
|
|
40
|
+
gitCommitMessage: truncateGitCommitMessage((_c = (await vcsClient.getLastCommitMessageAsync())) !== null && _c !== void 0 ? _c : undefined),
|
|
41
|
+
isGitWorkingTreeDirty: await vcsClient.hasUncommittedChangesAsync(),
|
|
40
42
|
username: (0, projectUtils_1.getUsername)(ctx.exp, await (0, actions_1.ensureLoggedInAsync)()),
|
|
43
|
+
message: ctx.message,
|
|
41
44
|
...(ctx.platform === eas_build_job_1.Platform.IOS && {
|
|
42
45
|
iosEnterpriseProvisioning: resolveIosEnterpriseProvisioning(ctx),
|
|
43
46
|
}),
|
|
@@ -48,7 +51,7 @@ exports.collectMetadataAsync = collectMetadataAsync;
|
|
|
48
51
|
async function maybeResolveVersionsAsync(ctx) {
|
|
49
52
|
if (ctx.platform === eas_build_job_1.Platform.IOS) {
|
|
50
53
|
const iosContext = ctx;
|
|
51
|
-
return await (0, version_2.maybeResolveVersionsAsync)(ctx.projectDir, ctx.exp, iosContext.ios.
|
|
54
|
+
return await (0, version_2.maybeResolveVersionsAsync)(ctx.projectDir, ctx.exp, iosContext.ios.targets);
|
|
52
55
|
}
|
|
53
56
|
else if (ctx.platform === eas_build_job_1.Platform.ANDROID) {
|
|
54
57
|
const androidCtx = ctx;
|
|
@@ -122,3 +125,10 @@ async function getReactNativeVersionAsync(ctx) {
|
|
|
122
125
|
function resolveIosEnterpriseProvisioning(ctx) {
|
|
123
126
|
return ctx.buildProfile.enterpriseProvisioning;
|
|
124
127
|
}
|
|
128
|
+
function truncateGitCommitMessage(msg, maxLength = 4096) {
|
|
129
|
+
if (msg === undefined) {
|
|
130
|
+
return undefined;
|
|
131
|
+
}
|
|
132
|
+
return msg.length > maxLength ? `${msg.substring(0, maxLength - 3)}...` : msg;
|
|
133
|
+
}
|
|
134
|
+
exports.truncateGitCommitMessage = truncateGitCommitMessage;
|
|
@@ -12,5 +12,6 @@ export interface BuildFlags {
|
|
|
12
12
|
submitProfile?: string;
|
|
13
13
|
localBuildOptions: LocalBuildOptions;
|
|
14
14
|
userInputResourceClass?: UserInputResourceClass;
|
|
15
|
+
message?: string;
|
|
15
16
|
}
|
|
16
17
|
export declare function runBuildAndSubmitAsync(projectDir: string, flags: BuildFlags): Promise<void>;
|
|
@@ -40,7 +40,7 @@ const platformToGraphQLResourceClassMapping = {
|
|
|
40
40
|
},
|
|
41
41
|
};
|
|
42
42
|
async function runBuildAndSubmitAsync(projectDir, flags) {
|
|
43
|
-
var _a, _b;
|
|
43
|
+
var _a, _b, _c;
|
|
44
44
|
await (0, vcs_1.getVcsClient)().ensureRepoExistsAsync();
|
|
45
45
|
await (0, repository_1.ensureRepoIsCleanAsync)(flags.nonInteractive);
|
|
46
46
|
await (0, configure_1.ensureProjectConfiguredAsync)({
|
|
@@ -48,12 +48,13 @@ async function runBuildAndSubmitAsync(projectDir, flags) {
|
|
|
48
48
|
nonInteractive: flags.nonInteractive,
|
|
49
49
|
});
|
|
50
50
|
const easJsonReader = new eas_json_1.EasJsonReader(projectDir);
|
|
51
|
+
const easJsonCliConfig = (_a = (await easJsonReader.getCliConfigAsync())) !== null && _a !== void 0 ? _a : {};
|
|
51
52
|
const platforms = (0, platform_1.toPlatforms)(flags.requestedPlatform);
|
|
52
53
|
const buildProfiles = await (0, profiles_1.getProfilesAsync)({
|
|
53
54
|
type: 'build',
|
|
54
55
|
easJsonReader,
|
|
55
56
|
platforms,
|
|
56
|
-
profileName: (
|
|
57
|
+
profileName: (_b = flags.profile) !== null && _b !== void 0 ? _b : undefined,
|
|
57
58
|
});
|
|
58
59
|
await (0, devClient_1.ensureExpoDevClientInstalledForDevClientBuildsAsync)({
|
|
59
60
|
projectDir,
|
|
@@ -68,7 +69,8 @@ async function runBuildAndSubmitAsync(projectDir, flags) {
|
|
|
68
69
|
flags,
|
|
69
70
|
moreBuilds: platforms.length > 1,
|
|
70
71
|
buildProfile,
|
|
71
|
-
resourceClass: platformToGraphQLResourceClassMapping[buildProfile.platform][(
|
|
72
|
+
resourceClass: platformToGraphQLResourceClassMapping[buildProfile.platform][(_c = flags.userInputResourceClass) !== null && _c !== void 0 ? _c : types_1.UserInputResourceClass.DEFAULT],
|
|
73
|
+
easJsonCliConfig,
|
|
72
74
|
});
|
|
73
75
|
if (maybeBuild) {
|
|
74
76
|
startedBuilds.push({ build: maybeBuild, buildProfile });
|
|
@@ -128,7 +130,7 @@ async function runBuildAndSubmitAsync(projectDir, flags) {
|
|
|
128
130
|
}
|
|
129
131
|
}
|
|
130
132
|
exports.runBuildAndSubmitAsync = runBuildAndSubmitAsync;
|
|
131
|
-
async function prepareAndStartBuildAsync({ projectDir, flags, moreBuilds, buildProfile, resourceClass, }) {
|
|
133
|
+
async function prepareAndStartBuildAsync({ projectDir, flags, moreBuilds, buildProfile, resourceClass, easJsonCliConfig, }) {
|
|
132
134
|
const buildCtx = await (0, createContext_1.createBuildContextAsync)({
|
|
133
135
|
buildProfileName: buildProfile.profileName,
|
|
134
136
|
resourceClass,
|
|
@@ -138,6 +140,8 @@ async function prepareAndStartBuildAsync({ projectDir, flags, moreBuilds, buildP
|
|
|
138
140
|
platform: buildProfile.platform,
|
|
139
141
|
projectDir,
|
|
140
142
|
localBuildOptions: flags.localBuildOptions,
|
|
143
|
+
easJsonCliConfig,
|
|
144
|
+
message: flags.message,
|
|
141
145
|
});
|
|
142
146
|
if (moreBuilds) {
|
|
143
147
|
log_1.default.newLine();
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare const getPaginatedQueryOptions: (flags: Record<keyof typeof EasPaginatedQueryFlags, any>) => PaginatedQueryOptions;
|
|
2
|
+
export declare const EasPaginatedQueryFlags: {
|
|
3
|
+
offset: import("@oclif/core/lib/interfaces").OptionFlag<number | undefined>;
|
|
4
|
+
limit: import("@oclif/core/lib/interfaces").OptionFlag<number | undefined>;
|
|
5
|
+
json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
6
|
+
'non-interactive': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
7
|
+
};
|
|
8
|
+
export declare type PaginatedQueryOptions = {
|
|
9
|
+
nonInteractive: boolean;
|
|
10
|
+
json: boolean;
|
|
11
|
+
limit?: number;
|
|
12
|
+
offset: number;
|
|
13
|
+
};
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EasPaginatedQueryFlags = exports.getPaginatedQueryOptions = void 0;
|
|
4
|
+
const core_1 = require("@oclif/core");
|
|
5
|
+
const getPaginatedQueryOptions = (flags) => {
|
|
6
|
+
var _a, _b, _c;
|
|
7
|
+
return {
|
|
8
|
+
json: (_a = flags.json) !== null && _a !== void 0 ? _a : false,
|
|
9
|
+
offset: (_b = flags.offset) !== null && _b !== void 0 ? _b : 0,
|
|
10
|
+
nonInteractive: (_c = flags['non-interactive']) !== null && _c !== void 0 ? _c : false,
|
|
11
|
+
...('limit' in flags && { limit: flags.limit }),
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
exports.getPaginatedQueryOptions = getPaginatedQueryOptions;
|
|
15
|
+
const parseFlagInputStringAsInteger = (input, flagName, lowerLimit, upperLimit) => {
|
|
16
|
+
const inputAsNumber = Number(input);
|
|
17
|
+
if (isNaN(inputAsNumber)) {
|
|
18
|
+
throw new Error(`Unable to parse ${input} as a number`);
|
|
19
|
+
}
|
|
20
|
+
if (inputAsNumber < lowerLimit || inputAsNumber > upperLimit) {
|
|
21
|
+
throw new Error(`--${flagName} must be between ${lowerLimit} and ${upperLimit}`);
|
|
22
|
+
}
|
|
23
|
+
return inputAsNumber;
|
|
24
|
+
};
|
|
25
|
+
exports.EasPaginatedQueryFlags = {
|
|
26
|
+
offset: core_1.Flags.integer({
|
|
27
|
+
description: 'Start queries from specified index. Use for paginating results. Defaults to 0.',
|
|
28
|
+
// eslint-disable-next-line async-protect/async-suffix
|
|
29
|
+
parse: async (input) => parseFlagInputStringAsInteger(input, 'offset', 0, Number.MAX_SAFE_INTEGER),
|
|
30
|
+
}),
|
|
31
|
+
limit: core_1.Flags.integer({
|
|
32
|
+
description: 'The number of query items to list at once. The default value is 50 (the maximum is 100). Using a lower value may help increase command speed.',
|
|
33
|
+
// eslint-disable-next-line async-protect/async-suffix
|
|
34
|
+
parse: async (input) => parseFlagInputStringAsInteger(input, 'limit', 1, 100),
|
|
35
|
+
}),
|
|
36
|
+
json: core_1.Flags.boolean({
|
|
37
|
+
description: 'Enable JSON output, non-JSON messages will be printed to stderr.',
|
|
38
|
+
}),
|
|
39
|
+
'non-interactive': core_1.Flags.boolean({
|
|
40
|
+
description: 'Run the command in non-interactive mode.',
|
|
41
|
+
}),
|
|
42
|
+
};
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import EasCommand from '../../commandUtils/EasCommand';
|
|
2
|
-
import { UpdateBranchFragment } from '../../graphql/generated';
|
|
3
|
-
export declare function listBranchesAsync({ projectId, }: {
|
|
4
|
-
projectId: string;
|
|
5
|
-
}): Promise<UpdateBranchFragment[]>;
|
|
6
2
|
export default class BranchList extends EasCommand {
|
|
7
3
|
static description: string;
|
|
8
4
|
static flags: {
|
|
5
|
+
offset: import("@oclif/core/lib/interfaces").OptionFlag<number | undefined>;
|
|
6
|
+
limit: import("@oclif/core/lib/interfaces").OptionFlag<number | undefined>;
|
|
9
7
|
json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
8
|
+
'non-interactive': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
10
9
|
};
|
|
11
10
|
runAsync(): Promise<void>;
|
|
12
11
|
}
|
|
@@ -1,90 +1,27 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.listBranchesAsync = void 0;
|
|
4
3
|
const tslib_1 = require("tslib");
|
|
5
|
-
const
|
|
6
|
-
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
7
|
-
const cli_table3_1 = tslib_1.__importDefault(require("cli-table3"));
|
|
8
|
-
const graphql_1 = require("graphql");
|
|
9
|
-
const graphql_tag_1 = tslib_1.__importDefault(require("graphql-tag"));
|
|
4
|
+
const queries_1 = require("../../branch/queries");
|
|
10
5
|
const EasCommand_1 = tslib_1.__importDefault(require("../../commandUtils/EasCommand"));
|
|
11
|
-
const
|
|
12
|
-
const UpdateBranch_1 = require("../../graphql/types/UpdateBranch");
|
|
13
|
-
const log_1 = tslib_1.__importDefault(require("../../log"));
|
|
6
|
+
const pagination_1 = require("../../commandUtils/pagination");
|
|
14
7
|
const expoConfig_1 = require("../../project/expoConfig");
|
|
15
8
|
const projectUtils_1 = require("../../project/projectUtils");
|
|
16
|
-
const utils_1 = require("../../update/utils");
|
|
17
9
|
const json_1 = require("../../utils/json");
|
|
18
|
-
const BRANCHES_LIMIT = 10000;
|
|
19
|
-
async function listBranchesAsync({ projectId, }) {
|
|
20
|
-
var _a, _b;
|
|
21
|
-
const data = await (0, client_1.withErrorHandlingAsync)(client_1.graphqlClient
|
|
22
|
-
.query((0, graphql_tag_1.default) `
|
|
23
|
-
query BranchesByAppQuery($appId: String!, $limit: Int!) {
|
|
24
|
-
app {
|
|
25
|
-
byId(appId: $appId) {
|
|
26
|
-
id
|
|
27
|
-
updateBranches(offset: 0, limit: $limit) {
|
|
28
|
-
id
|
|
29
|
-
...UpdateBranchFragment
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
${(0, graphql_1.print)(UpdateBranch_1.UpdateBranchFragmentNode)}
|
|
35
|
-
`, {
|
|
36
|
-
appId: projectId,
|
|
37
|
-
limit: BRANCHES_LIMIT,
|
|
38
|
-
}, { additionalTypenames: ['UpdateBranch'] })
|
|
39
|
-
.toPromise());
|
|
40
|
-
return (_b = (_a = data === null || data === void 0 ? void 0 : data.app) === null || _a === void 0 ? void 0 : _a.byId.updateBranches) !== null && _b !== void 0 ? _b : [];
|
|
41
|
-
}
|
|
42
|
-
exports.listBranchesAsync = listBranchesAsync;
|
|
43
10
|
class BranchList extends EasCommand_1.default {
|
|
44
11
|
async runAsync() {
|
|
45
12
|
const { flags } = await this.parse(BranchList);
|
|
46
|
-
|
|
13
|
+
const options = (0, pagination_1.getPaginatedQueryOptions)(flags);
|
|
14
|
+
if (options.json) {
|
|
47
15
|
(0, json_1.enableJsonOutput)();
|
|
48
16
|
}
|
|
49
17
|
const projectDir = await (0, projectUtils_1.findProjectRootAsync)();
|
|
50
18
|
const exp = (0, expoConfig_1.getExpoConfig)(projectDir);
|
|
51
19
|
const projectId = await (0, projectUtils_1.getProjectIdAsync)(exp);
|
|
52
|
-
|
|
53
|
-
if (flags.json) {
|
|
54
|
-
(0, json_1.printJsonOnlyOutput)(branches);
|
|
55
|
-
}
|
|
56
|
-
else {
|
|
57
|
-
const table = new cli_table3_1.default({
|
|
58
|
-
head: ['Branch', ...utils_1.UPDATE_COLUMNS],
|
|
59
|
-
wordWrap: true,
|
|
60
|
-
});
|
|
61
|
-
table.push(...branches.map(branch => {
|
|
62
|
-
var _a, _b, _c, _d, _e;
|
|
63
|
-
return [
|
|
64
|
-
branch.name,
|
|
65
|
-
(0, utils_1.formatUpdate)(branch.updates[0]),
|
|
66
|
-
(_b = (_a = branch.updates[0]) === null || _a === void 0 ? void 0 : _a.runtimeVersion) !== null && _b !== void 0 ? _b : 'N/A',
|
|
67
|
-
(_d = (_c = branch.updates[0]) === null || _c === void 0 ? void 0 : _c.group) !== null && _d !== void 0 ? _d : 'N/A',
|
|
68
|
-
(0, utils_1.getPlatformsForGroup)({
|
|
69
|
-
updates: branch.updates,
|
|
70
|
-
group: (_e = branch.updates[0]) === null || _e === void 0 ? void 0 : _e.group,
|
|
71
|
-
}),
|
|
72
|
-
];
|
|
73
|
-
}));
|
|
74
|
-
log_1.default.addNewLineIfNone();
|
|
75
|
-
log_1.default.log(chalk_1.default.bold('Branches with their most recent update group:'));
|
|
76
|
-
log_1.default.log(table.toString());
|
|
77
|
-
if (branches.length >= BRANCHES_LIMIT) {
|
|
78
|
-
log_1.default.warn(`Showing first ${BRANCHES_LIMIT} branches, some results might be omitted.`);
|
|
79
|
-
}
|
|
80
|
-
}
|
|
20
|
+
await (0, queries_1.listAndRenderPaginatedBranchesAsync)(projectId, options);
|
|
81
21
|
}
|
|
82
22
|
}
|
|
83
23
|
exports.default = BranchList;
|
|
84
24
|
BranchList.description = 'list all branches';
|
|
85
25
|
BranchList.flags = {
|
|
86
|
-
|
|
87
|
-
description: 'return output as JSON',
|
|
88
|
-
default: false,
|
|
89
|
-
}),
|
|
26
|
+
...pagination_1.EasPaginatedQueryFlags,
|
|
90
27
|
};
|
|
@@ -7,7 +7,10 @@ export default class BranchView extends EasCommand {
|
|
|
7
7
|
description: string;
|
|
8
8
|
}[];
|
|
9
9
|
static flags: {
|
|
10
|
+
offset: import("@oclif/core/lib/interfaces").OptionFlag<number | undefined>;
|
|
11
|
+
limit: import("@oclif/core/lib/interfaces").OptionFlag<number | undefined>;
|
|
10
12
|
json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
13
|
+
'non-interactive': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
11
14
|
};
|
|
12
15
|
runAsync(): Promise<void>;
|
|
13
16
|
}
|