@forge/cli 6.20.0-next.8 → 6.20.1-next.12
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.
|
@@ -31,7 +31,6 @@ export declare class InstallController {
|
|
|
31
31
|
private promptForUpgrade;
|
|
32
32
|
private getUniqueInstallationProductsFromScopes;
|
|
33
33
|
run({ environment, site, product, upgrade, confirmScopes, nonInteractive }: InstallViewProps): Promise<void>;
|
|
34
|
-
private hasDeployments;
|
|
35
34
|
private extractAddedScopes;
|
|
36
35
|
}
|
|
37
36
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"install-controller.d.ts","sourceRoot":"","sources":["../../../src/command-line/controller/install-controller.ts"],"names":[],"mappings":";AAAA,OAAO,EAEL,iBAAiB,EAEjB,UAAU,EAEV,EAAE,EAQF,iBAAiB,EAElB,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAC1B,OAAO,EAAE,qBAAqB,EAAE,MAAM,sCAAsC,CAAC;AAC7E,OAAO,EAA6B,mBAAmB,EAAE,MAAM,oCAAoC,CAAC;AACpG,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAEnD,UAAU,gBAAgB;IACxB,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,aAAa,EAAE,OAAO,CAAC;CACxB;AAYD,qBAAa,iBAAkB,SAAQ,KAAK;gBAC9B,WAAW,EAAE,MAAM;CAGhC;AASD,qBAAa,iBAAiB;IAE1B,OAAO,CAAC,QAAQ,CAAC,iBAAiB;IAClC,OAAO,CAAC,QAAQ,CAAC,UAAU;IAC3B,OAAO,CAAC,QAAQ,CAAC,EAAE;IACnB,OAAO,CAAC,QAAQ,CAAC,qBAAqB;IACtC,OAAO,CAAC,QAAQ,CAAC,mBAAmB;IACpC,OAAO,CAAC,QAAQ,CAAC,WAAW;IAC5B,OAAO,CAAC,QAAQ,CAAC,YAAY;gBANZ,iBAAiB,EAAE,iBAAiB,EACpC,UAAU,EAAE,UAAU,EACtB,EAAE,EAAE,EAAE,EACN,qBAAqB,EAAE,qBAAqB,EAC5C,mBAAmB,EAAE,mBAAmB,EACxC,WAAW,EAAE,WAAW,EACxB,YAAY,EAAE,iBAAiB;YAGpC,cAAc;YAmBd,gBAAgB;YAyChB,gBAAgB;YAMhB,aAAa;YAsBb,gBAAgB;IAqB9B,OAAO,CAAC,uCAAuC;IAalC,GAAG,CAAC,EACf,WAAW,EACX,IAAI,EACJ,OAAO,EACP,OAAO,EACP,aAAa,EACb,cAAc,EACf,EAAE,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"install-controller.d.ts","sourceRoot":"","sources":["../../../src/command-line/controller/install-controller.ts"],"names":[],"mappings":";AAAA,OAAO,EAEL,iBAAiB,EAEjB,UAAU,EAEV,EAAE,EAQF,iBAAiB,EAElB,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAC1B,OAAO,EAAE,qBAAqB,EAAE,MAAM,sCAAsC,CAAC;AAC7E,OAAO,EAA6B,mBAAmB,EAAE,MAAM,oCAAoC,CAAC;AACpG,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAEnD,UAAU,gBAAgB;IACxB,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,GAAG,CAAC;IACX,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,aAAa,EAAE,OAAO,CAAC;CACxB;AAYD,qBAAa,iBAAkB,SAAQ,KAAK;gBAC9B,WAAW,EAAE,MAAM;CAGhC;AASD,qBAAa,iBAAiB;IAE1B,OAAO,CAAC,QAAQ,CAAC,iBAAiB;IAClC,OAAO,CAAC,QAAQ,CAAC,UAAU;IAC3B,OAAO,CAAC,QAAQ,CAAC,EAAE;IACnB,OAAO,CAAC,QAAQ,CAAC,qBAAqB;IACtC,OAAO,CAAC,QAAQ,CAAC,mBAAmB;IACpC,OAAO,CAAC,QAAQ,CAAC,WAAW;IAC5B,OAAO,CAAC,QAAQ,CAAC,YAAY;gBANZ,iBAAiB,EAAE,iBAAiB,EACpC,UAAU,EAAE,UAAU,EACtB,EAAE,EAAE,EAAE,EACN,qBAAqB,EAAE,qBAAqB,EAC5C,mBAAmB,EAAE,mBAAmB,EACxC,WAAW,EAAE,WAAW,EACxB,YAAY,EAAE,iBAAiB;YAGpC,cAAc;YAmBd,gBAAgB;YAyChB,gBAAgB;YAMhB,aAAa;YAsBb,gBAAgB;IAqB9B,OAAO,CAAC,uCAAuC;IAalC,GAAG,CAAC,EACf,WAAW,EACX,IAAI,EACJ,OAAO,EACP,OAAO,EACP,aAAa,EACb,cAAc,EACf,EAAE,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC;YAmGrB,kBAAkB;CASjC"}
|
|
@@ -126,10 +126,8 @@ class InstallController {
|
|
|
126
126
|
if ((0, cli_shared_1.isSecureSite)(site)) {
|
|
127
127
|
await this.securityPrompt(site);
|
|
128
128
|
}
|
|
129
|
-
const hasDefaultReadMeScope = await this.featureFlags.readMeScopeAddedByXLS();
|
|
130
|
-
this.ui.debug(`appId ${id} has read:me scope added by default?: ${hasDefaultReadMeScope}`);
|
|
131
129
|
const environmentPermissions = await this.installationService.getAppEnvironmentPermissions(id, environment);
|
|
132
|
-
if (!environmentPermissions ||
|
|
130
|
+
if (!(environmentPermissions === null || environmentPermissions === void 0 ? void 0 : environmentPermissions.hasDeployments)) {
|
|
133
131
|
this.ui.error(new NoDeploymentError(environment), { pad: false });
|
|
134
132
|
return;
|
|
135
133
|
}
|
|
@@ -143,9 +141,6 @@ class InstallController {
|
|
|
143
141
|
]);
|
|
144
142
|
const manifestEgressAddresses = (0, cli_shared_1.flatMap)(manifestEgressEntries, ({ domains }) => domains !== null && domains !== void 0 ? domains : []);
|
|
145
143
|
const manifestScopes = new Set((_a = permissions === null || permissions === void 0 ? void 0 : permissions.scopes) !== null && _a !== void 0 ? _a : []);
|
|
146
|
-
if (hasDefaultReadMeScope) {
|
|
147
|
-
manifestScopes.add('read:me');
|
|
148
|
-
}
|
|
149
144
|
const addedScopes = await this.extractAddedScopes(environmentPermissions);
|
|
150
145
|
const scopesConfirmationResult = await this.installView.promptForPermissionsConfirmation(environmentPermissions, addedScopes, [...manifestScopes], manifestEgressAddresses, environment, confirmScopes, !!nonInteractive, text);
|
|
151
146
|
if (!scopesConfirmationResult)
|
|
@@ -174,18 +169,11 @@ class InstallController {
|
|
|
174
169
|
this.ui.warn(cli_shared_1.Text.install.multiProductScopesDetected(productsToInstall, productsToUpgrade, site.host, environment));
|
|
175
170
|
}
|
|
176
171
|
}
|
|
177
|
-
hasDeployments(hasDefaultReadMeScope, environmentPermissions) {
|
|
178
|
-
var _a;
|
|
179
|
-
return hasDefaultReadMeScope
|
|
180
|
-
? ((_a = environmentPermissions.scopes) === null || _a === void 0 ? void 0 : _a.length) > 0
|
|
181
|
-
: environmentPermissions.hasDeployments;
|
|
182
|
-
}
|
|
183
172
|
async extractAddedScopes({ addedScopes }) {
|
|
184
|
-
const isAutoConsentAllowed = await this.featureFlags.isAutoConsentAllowed();
|
|
185
173
|
const scopesWithInteractiveConsent = (0, manifest_1.getScopesWithInteractiveConsent)();
|
|
186
174
|
return addedScopes.map((scope) => ({
|
|
187
175
|
name: scope,
|
|
188
|
-
requiresInteractiveConsent:
|
|
176
|
+
requiresInteractiveConsent: scopesWithInteractiveConsent.has(scope)
|
|
189
177
|
}));
|
|
190
178
|
}
|
|
191
179
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@forge/cli",
|
|
3
|
-
"version": "6.20.
|
|
3
|
+
"version": "6.20.1-next.12",
|
|
4
4
|
"description": "A command line interface for managing Atlassian-hosted apps",
|
|
5
5
|
"author": "Atlassian",
|
|
6
6
|
"license": "UNLICENSED",
|
|
@@ -18,16 +18,16 @@
|
|
|
18
18
|
"postinstall": "node -e \"fs.existsSync('./out/bin/postinstall.js') && require('./out/bin/postinstall.js')\""
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@forge/bundler": "4.13.
|
|
22
|
-
"@forge/cli-shared": "3.20.
|
|
23
|
-
"@forge/egress": "1.2.
|
|
24
|
-
"@forge/lint": "3.7.
|
|
25
|
-
"@forge/manifest": "4.20.
|
|
26
|
-
"@forge/node-runtime": "0.4.
|
|
27
|
-
"@forge/runtime": "5.1.
|
|
28
|
-
"@forge/tunnel": "3.8.
|
|
29
|
-
"@forge/util": "1.3.
|
|
30
|
-
"@sentry/node": "^7.
|
|
21
|
+
"@forge/bundler": "4.13.1-next.8",
|
|
22
|
+
"@forge/cli-shared": "3.20.3-next.7",
|
|
23
|
+
"@forge/egress": "1.2.7-next.0",
|
|
24
|
+
"@forge/lint": "3.7.3-next.7",
|
|
25
|
+
"@forge/manifest": "4.20.4-next.1",
|
|
26
|
+
"@forge/node-runtime": "0.4.1-next.3",
|
|
27
|
+
"@forge/runtime": "5.1.3-next.0",
|
|
28
|
+
"@forge/tunnel": "3.8.4-next.9",
|
|
29
|
+
"@forge/util": "1.3.3-next.0",
|
|
30
|
+
"@sentry/node": "^7.74.1",
|
|
31
31
|
"ajv": "^8.12.0",
|
|
32
32
|
"archiver": "^6.0.1",
|
|
33
33
|
"case": "^1.6.3",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"cheerio": "^0.22.0",
|
|
36
36
|
"cli-table3": "^0.6.3",
|
|
37
37
|
"command-exists": "^1.2.9",
|
|
38
|
-
"commander": "^11.
|
|
38
|
+
"commander": "^11.1.0",
|
|
39
39
|
"cross-spawn": "^7.0.3",
|
|
40
40
|
"dayjs": "^1.11.10",
|
|
41
41
|
"didyoumean": "^1.2.2",
|
|
@@ -57,16 +57,16 @@
|
|
|
57
57
|
"uuid": "^9.0.1"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
60
|
-
"@types/archiver": "^5.3.
|
|
61
|
-
"@types/cheerio": "^0.22.
|
|
62
|
-
"@types/command-exists": "^1.2.
|
|
63
|
-
"@types/cross-spawn": "^6.0.
|
|
64
|
-
"@types/didyoumean": "^1.2.
|
|
65
|
-
"@types/fs-extra": "^11.0.
|
|
66
|
-
"@types/hidefile": "^3.0.
|
|
67
|
-
"@types/inquirer": "^8.2.
|
|
60
|
+
"@types/archiver": "^5.3.4",
|
|
61
|
+
"@types/cheerio": "^0.22.33",
|
|
62
|
+
"@types/command-exists": "^1.2.2",
|
|
63
|
+
"@types/cross-spawn": "^6.0.4",
|
|
64
|
+
"@types/didyoumean": "^1.2.1",
|
|
65
|
+
"@types/fs-extra": "^11.0.3",
|
|
66
|
+
"@types/hidefile": "^3.0.2",
|
|
67
|
+
"@types/inquirer": "^8.2.7",
|
|
68
68
|
"@types/jest": "^29.5.5",
|
|
69
|
-
"@types/js-yaml": "^4.0.
|
|
69
|
+
"@types/js-yaml": "^4.0.7",
|
|
70
70
|
"@types/node": "14.18.63",
|
|
71
71
|
"@types/node-fetch": "^2.6.6",
|
|
72
72
|
"@types/omelette": "^0.4.2",
|
|
@@ -84,4 +84,4 @@
|
|
|
84
84
|
"engines": {
|
|
85
85
|
"node": ">=12.13.1"
|
|
86
86
|
}
|
|
87
|
-
}
|
|
87
|
+
}
|