@supersdk/supercli 0.3.8-staging.66 → 0.3.8
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/auth/browserAuth.js +1 -1
- package/dist/auth/browserAuth.js.map +1 -1
- package/dist/auth/identityOverride.js +46 -0
- package/dist/auth/identityOverride.js.map +1 -0
- package/dist/auth/tokenAuth.js +15 -6
- package/dist/auth/tokenAuth.js.map +1 -1
- package/dist/cli.js +66 -1
- package/dist/cli.js.map +1 -1
- package/dist/commands/accounts.js +8 -3
- package/dist/commands/accounts.js.map +1 -1
- package/dist/commands/deploy.js +6 -87
- package/dist/commands/deploy.js.map +1 -1
- package/dist/commands/image.js +10 -28
- package/dist/commands/image.js.map +1 -1
- package/dist/commands/login.js +13 -0
- package/dist/commands/login.js.map +1 -1
- package/dist/commands/logs.js +4 -12
- package/dist/commands/logs.js.map +1 -1
- package/dist/commands/publishSite.js +2 -1
- package/dist/commands/publishSite.js.map +1 -1
- package/dist/commands/superRun.js +9 -41
- package/dist/commands/superRun.js.map +1 -1
- package/dist/config/superConfig.js.map +1 -1
- package/dist/deploy/runAdapter.js +1 -1
- package/dist/deploy/runAdapter.js.map +1 -1
- package/dist/deploy/siteAdapter.js +1 -1
- package/dist/deploy/siteAdapter.js.map +1 -1
- package/dist/publish/registryClient.js +1 -3
- package/dist/publish/registryClient.js.map +1 -1
- package/dist/publish/runClient.js +1 -2
- package/dist/publish/runClient.js.map +1 -1
- package/dist/publish/siteClient.js +7 -1
- package/dist/publish/siteClient.js.map +1 -1
- package/dist/store/accountStore.js +39 -4
- package/dist/store/accountStore.js.map +1 -1
- package/dist/template/android/supersdk-default.config.json +1 -1
- package/dist/template/web/src/js/supersdk.js +5 -1
- package/dist/template/web/src/js/supersdk.provenance.json +3 -3
- package/dist/util/deprecations.js +25 -0
- package/dist/util/deprecations.js.map +1 -0
- package/package.json +1 -1
- package/dist/publish/orgResolve.js +0 -29
- package/dist/publish/orgResolve.js.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": "@supersdk/jssdk",
|
|
3
|
-
"version": "2.
|
|
4
|
-
"integrity": "sha512-
|
|
3
|
+
"version": "2.2.0",
|
|
4
|
+
"integrity": "sha512-a52400q5TdYur7DzN5Gx4AcNSMr46OzMjEZ1Fcf6R754FQr6BfuDCl36Kvx3Z5Md611dOLlgtpeYMhW7vAUlCw==",
|
|
5
5
|
"file": "dist/supersdk.js",
|
|
6
|
-
"sha256": "
|
|
6
|
+
"sha256": "27366fb38d56d3b4752b732dd6a8dee701162c96a97bd7dc971466f003eea3cf"
|
|
7
7
|
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.IGNORED_ORG_DESCRIPTION = void 0;
|
|
4
|
+
exports.acceptIgnoredOrg = acceptIgnoredOrg;
|
|
5
|
+
const log_1 = require("./log");
|
|
6
|
+
/**
|
|
7
|
+
* `--org` is accepted and ignored.
|
|
8
|
+
*
|
|
9
|
+
* 🔴 The CLI does not choose an organization. A credential is bound to exactly one when it
|
|
10
|
+
* is minted, and the server takes the org from `token.org` — `resolve_caller_org` only ever
|
|
11
|
+
* *compares* a client-sent org to that binding, so passing one could match (redundant) or
|
|
12
|
+
* differ (403). Resolving a value to send also cost a whoami round trip on every deploy.
|
|
13
|
+
*
|
|
14
|
+
* The flag stays declared rather than removed so existing scripts and CI jobs keep running;
|
|
15
|
+
* using it now says so once, on stderr, without touching the stdout envelope.
|
|
16
|
+
*
|
|
17
|
+
* Used as a commander coercion function, so it fires exactly when the flag is supplied.
|
|
18
|
+
*/
|
|
19
|
+
function acceptIgnoredOrg(value) {
|
|
20
|
+
log_1.log.warn('--org is deprecated and ignored: the organization comes from the credential itself');
|
|
21
|
+
return value;
|
|
22
|
+
}
|
|
23
|
+
/** Shared flag description, so all five call sites say the same thing. */
|
|
24
|
+
exports.IGNORED_ORG_DESCRIPTION = 'deprecated and ignored; the organization is bound to the credential and chosen when it is minted';
|
|
25
|
+
//# sourceMappingURL=deprecations.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deprecations.js","sourceRoot":"","sources":["../../src/util/deprecations.ts"],"names":[],"mappings":";;;AAeA,4CAGC;AAlBD,+BAA4B;AAE5B;;;;;;;;;;;;GAYG;AACH,SAAgB,gBAAgB,CAAC,KAAa;IAC5C,SAAG,CAAC,IAAI,CAAC,oFAAoF,CAAC,CAAC;IAC/F,OAAO,KAAK,CAAC;AACf,CAAC;AAED,0EAA0E;AAC7D,QAAA,uBAAuB,GAClC,kGAAkG,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.isValidOrgId = isValidOrgId;
|
|
4
|
-
exports.resolveOrgId = resolveOrgId;
|
|
5
|
-
function isValidOrgId(value) {
|
|
6
|
-
return /^[1-9][0-9]*$/.test(value);
|
|
7
|
-
}
|
|
8
|
-
function canonicalOrgId(value) {
|
|
9
|
-
if (typeof value === 'number' && Number.isSafeInteger(value) && value > 0)
|
|
10
|
-
return String(value);
|
|
11
|
-
if (typeof value === 'string' && isValidOrgId(value.trim()))
|
|
12
|
-
return value.trim();
|
|
13
|
-
return undefined;
|
|
14
|
-
}
|
|
15
|
-
function resolveOrgId(orgs, explicitOrg) {
|
|
16
|
-
if (explicitOrg !== undefined && explicitOrg.trim().length > 0) {
|
|
17
|
-
const orgId = explicitOrg.trim();
|
|
18
|
-
return isValidOrgId(orgId)
|
|
19
|
-
? { kind: 'resolved', orgId }
|
|
20
|
-
: { kind: 'invalid', reason: '--org must be a positive integer' };
|
|
21
|
-
}
|
|
22
|
-
const ids = [...new Set((orgs ?? []).map((org) => canonicalOrgId(org.id)).filter((id) => id !== undefined))];
|
|
23
|
-
if (ids.length === 0)
|
|
24
|
-
return { kind: 'none' };
|
|
25
|
-
if (ids.length === 1)
|
|
26
|
-
return { kind: 'resolved', orgId: ids[0] };
|
|
27
|
-
return { kind: 'ambiguous', orgIds: ids };
|
|
28
|
-
}
|
|
29
|
-
//# sourceMappingURL=orgResolve.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"orgResolve.js","sourceRoot":"","sources":["../../src/publish/orgResolve.ts"],"names":[],"mappings":";;AAUA,oCAEC;AAQD,oCAWC;AArBD,SAAgB,YAAY,CAAC,KAAa;IACxC,OAAO,eAAe,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;AACrC,CAAC;AAED,SAAS,cAAc,CAAC,KAAc;IACpC,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,MAAM,CAAC,aAAa,CAAC,KAAK,CAAC,IAAI,KAAK,GAAG,CAAC;QAAE,OAAO,MAAM,CAAC,KAAK,CAAC,CAAC;IAChG,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,YAAY,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC;QAAE,OAAO,KAAK,CAAC,IAAI,EAAE,CAAC;IACjF,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,SAAgB,YAAY,CAAC,IAAoC,EAAE,WAAoB;IACrF,IAAI,WAAW,KAAK,SAAS,IAAI,WAAW,CAAC,IAAI,EAAE,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAC/D,MAAM,KAAK,GAAG,WAAW,CAAC,IAAI,EAAE,CAAC;QACjC,OAAO,YAAY,CAAC,KAAK,CAAC;YACxB,CAAC,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE;YAC7B,CAAC,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE,kCAAkC,EAAE,CAAC;IACtE,CAAC;IACD,MAAM,GAAG,GAAG,CAAC,GAAG,IAAI,GAAG,CAAC,CAAC,IAAI,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,cAAc,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,EAAE,EAAgB,EAAE,CAAC,EAAE,KAAK,SAAS,CAAC,CAAC,CAAC,CAAC;IAC3H,IAAI,GAAG,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;IAC9C,IAAI,GAAG,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC;IACjE,OAAO,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC;AAC5C,CAAC"}
|