@microsoft/managed-apps-cli 0.21.0 → 0.22.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 +1 -1
- package/dist/{AddConnector-4AMM746J.js → AddConnector-5DUBFLEK.js} +2 -2
- package/dist/{AuthStatus-ZZIP3LBD.js → AuthStatus-6DMK7O6W.js} +2 -2
- package/dist/{AuthSwitch-HK7JU2FR.js → AuthSwitch-NUQIIRCG.js} +2 -2
- package/dist/Bin.js +1 -1
- package/dist/{BuildMaafApp-MOTZOLJZ.js → BuildMaafApp-A4IUU6LI.js} +2 -2
- package/dist/{Cli-6CCXMCPX.js → Cli-LYSWG64H.js} +5 -5
- package/dist/CloneMaafApp-B672N7T5.js +11 -0
- package/dist/CreateMaafApp-RWL7FXSP.js +20 -0
- package/dist/{DeleteMaafApp-MZVGIAX3.js → DeleteMaafApp-GT4CEFAE.js} +2 -2
- package/dist/{DeployMaafApp-KXATM3E3.js → DeployMaafApp-E4TQU6RO.js} +4 -4
- package/dist/{Dev-SHIA5S7X.js → Dev-ICCA5DEJ.js} +2 -2
- package/dist/{EnvironmentVariableAuthenticationProvider-5YTMRAE4.js → EnvironmentVariableAuthenticationProvider-LYCQ5D47.js} +2 -2
- package/dist/{GetMaafBuildStatus-3W7LI5TJ.js → GetMaafBuildStatus-UGAHVANE.js} +2 -2
- package/dist/{GetSettings-NM6H2U5F.js → GetSettings-ZI2IBKV5.js} +2 -2
- package/dist/InfoMaafApp-FL5PICDD.js +13 -0
- package/dist/{Init-CH5DUQWA.js → Init-XCSK3WQM.js} +2 -2
- package/dist/{ListConnectorActions-7SIFGPYR.js → ListConnectorActions-B2YD24RX.js} +2 -2
- package/dist/{ListConnectors-TRKIWRVQ.js → ListConnectors-MYUEVJPT.js} +2 -2
- package/dist/{ListMaafApps-RT3PGZSJ.js → ListMaafApps-3W6W6UYP.js} +2 -2
- package/dist/{Login-HG5S7LBC.js → Login-7RW6OEST.js} +2 -2
- package/dist/{Logout-BUPHLOAH.js → Logout-IXK2TMRL.js} +2 -2
- package/dist/{MockFetch-4CYTSNJ7.js → MockFetch-THQJ4KFB.js} +2 -2
- package/dist/{NodeMsalAuthenticationProvider-HTH3V3G2.js → NodeMsalAuthenticationProvider-VVQ6CCZ5.js} +2 -2
- package/dist/Pack-IWU3PFQL.js +8 -0
- package/dist/PlayMaafApp-5H3DCJ2C.js +12 -0
- package/dist/{RefreshDataSource-ZFZJXJ5L.js → RefreshDataSource-XQT7LVMO.js} +2 -2
- package/dist/{RefreshGitAuth-5A3SX2HC.js → RefreshGitAuth-IQBAFR37.js} +2 -2
- package/dist/{RemoveDataSource-57JJLK5I.js → RemoveDataSource-PGPLMJUX.js} +2 -2
- package/dist/{ServicePrincipalAuthenticationProvider-SVKDZG6X.js → ServicePrincipalAuthenticationProvider-IZZRJFZQ.js} +2 -2
- package/dist/{SetSetting-RB3F7IXG.js → SetSetting-SEWDA4TF.js} +2 -2
- package/dist/{ShareLinkCreate-7BCDPWY6.js → ShareLinkCreate-T5FN47J2.js} +2 -2
- package/dist/{ShareLinkList-4BI3WMNN.js → ShareLinkList-6JCVEYNC.js} +2 -2
- package/dist/{ShareLinkRevoke-EEJVCRCY.js → ShareLinkRevoke-OH5DZDHR.js} +2 -2
- package/dist/{ShareList-LJDAEGI3.js → ShareList-QCEL7QNJ.js} +2 -2
- package/dist/{ShareMaafApp-QFRXLYUD.js → ShareMaafApp-6MKZ33HW.js} +2 -2
- package/dist/{TelemetrySettings-A474HALH.js → TelemetrySettings-RXPPIEVO.js} +2 -2
- package/dist/{UnshareMaafApp-423RNXCN.js → UnshareMaafApp-OSE2TOBJ.js} +2 -2
- package/dist/{chunk-YIKNM523.js → chunk-23T63QIT.js} +2 -2
- package/dist/chunk-3JIZGVCA.js +11 -0
- package/dist/chunk-47LJLFDF.js +11 -0
- package/dist/{chunk-G33Q5FWT.js → chunk-4LIR3ZYP.js} +243 -243
- package/dist/{chunk-MFPX2RFH.js → chunk-4VBFOKV6.js} +2 -2
- package/dist/chunk-6LKH5WE7.js +104 -0
- package/dist/{chunk-EV3TTTOT.js → chunk-6RSE3J4X.js} +2 -2
- package/dist/chunk-7BRIEYGR.js +20 -0
- package/dist/{chunk-UBTSW22U.js → chunk-7GGFN2IW.js} +2 -2
- package/dist/{chunk-QSB5P4RM.js → chunk-AQLFVAFU.js} +11 -11
- package/dist/{chunk-NP2KJOYC.js → chunk-EQCYKUEU.js} +2 -2
- package/dist/{chunk-7NXJAIJX.js → chunk-EX6IKPAO.js} +2 -2
- package/dist/{chunk-VFSTQAZ2.js → chunk-IQGMFWXB.js} +2 -2
- package/dist/{chunk-3BRAT6NP.js → chunk-KYL2Y5G4.js} +2 -2
- package/dist/{chunk-6FFQN2SO.js → chunk-LQ65CHNN.js} +2 -2
- package/dist/{chunk-U36HMOQW.js → chunk-PPW4XUZO.js} +9 -9
- package/dist/{chunk-5AUOEXAR.js → chunk-SNWTSI75.js} +2 -2
- package/dist/{chunk-S5HEU7XK.js → chunk-UNJJUCSA.js} +2 -2
- package/dist/{chunk-QAFCXGBD.js → chunk-VMSJG53Y.js} +2 -2
- package/package.json +4 -4
- package/dist/CreateMaafApp-TUO72CW7.js +0 -20
- package/dist/GetMaafApp-ELB5KMHW.js +0 -11
- package/dist/Pack-AHKC2MYF.js +0 -8
- package/dist/PlayMaafApp-LWKJU2IN.js +0 -12
- package/dist/ShowMaafApp-3KK6NUG2.js +0 -11
- package/dist/chunk-6MXOK2LG.js +0 -11
- package/dist/chunk-DREO7EYO.js +0 -20
- package/dist/chunk-VNEZZ3RI.js +0 -11
- package/dist/chunk-W7EWOZPO.js +0 -104
package/README.md
CHANGED
|
@@ -12,7 +12,7 @@ Run commands with `ms <command>`.
|
|
|
12
12
|
|
|
13
13
|
## Commands
|
|
14
14
|
|
|
15
|
-
- **`ms app …`** — app lifecycle and configuration: create, init, list, show, build, deploy, dev, delete, share/unshare, share list, add data-source, refresh data-source (`--offline`), and settings.
|
|
15
|
+
- **`ms app …`** — app lifecycle and configuration: create, clone platform-managed repositories, init, list, info (`show` is a deprecated alias), build, deploy, play (including branch or commit previews), dev, delete, share/unshare, share list, add data-source, refresh data-source (`--offline`), and settings.
|
|
16
16
|
- **`ms connector …`** — discover connector actions and functions in the environment.
|
|
17
17
|
- **`ms auth …`** — sign in/out and manage cached accounts (login, logout, status, switch).
|
|
18
18
|
- **`ms git auth …`** — establish the Entra↔GitHub identity mapping for external repos.
|
|
@@ -4,7 +4,7 @@ import { dirname as __pathDirname } from 'node:path';
|
|
|
4
4
|
const require = __createRequire(import.meta.url);
|
|
5
5
|
const __filename = __fileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = __pathDirname(__filename);
|
|
7
|
-
import{a as ve,b as B,c as Ce,d as J,e as ye,g as we}from"./chunk-
|
|
7
|
+
import{a as ve,b as B,c as Ce,d as J,e as ye,g as we}from"./chunk-SNWTSI75.js";import{A as z,B as se,C as ce,D as le,M as j,N as me,O as ue,T as fe,U as ge,e as ee,f as ne,i as te,q as U,u as oe,ua as $,v as ae,va as x,w as ie,x as re,y as G,z as Y}from"./chunk-4LIR3ZYP.js";import{a as de,b as u,f as pe}from"./chunk-RBG2H562.js";import"./chunk-UNJJUCSA.js";import"./chunk-6RSE3J4X.js";import{c as he}from"./chunk-EX6IKPAO.js";import{b as P,c as b}from"./chunk-3JIZGVCA.js";import{a as V,c as T,h,i as I}from"./chunk-PVAIJSAI.js";import{a as w}from"./chunk-47LJLFDF.js";import"./chunk-PPW4XUZO.js";import"./chunk-Y5AMO72S.js";import"./chunk-UT667QSU.js";var De=["shared_commondataserviceforapps","commondataserviceforapps"];function H(e){let t=e.toLowerCase();return De.some(n=>t===n||t.endsWith(`/${n}`))}import*as Ie from"http";import xe from"open";var be={defaultBehavior:"Allow",allowedConnectors:[]};async function Se(e,t){if(e.toLowerCase().startsWith("shared_"))return e;let n=await ie(void 0,t??void 0),o=e.toLowerCase(),r=n.filter(a=>a.properties.displayName.toLowerCase()===o),i=r.length===0,c=i?n.filter(a=>a.properties.displayName.toLowerCase().includes(o)):r;if(c.length===0)return e;if(c.length===1)return i&&h(`Resolved '${e}' \u2192 '${c[0].properties.displayName}' (${c[0].name})`),c[0].name;let f=c.map(a=>` ${a.name} (${a.properties.displayName})`).join(`
|
|
8
8
|
`);throw new u(`Multiple connectors match '${e}'. Specify the connector ID directly:
|
|
9
9
|
${f}`)}var Ae="__create__",ke=600*1e3,K="1";async function Ne(e,t){let n=$(),o=await e.getTenantIdAsync();o||(n.trackErrorEvent("DlpSkippedNoTenantId",{apiId:t}),I(`Could not resolve tenant ID; skipping connector policy check. Sign in with '${"ms"} auth login' for full enforcement.`));let[r,i]=await Promise.all([oe(t,n),o?se(n,o).catch(()=>(I("Could not verify connector policy; proceeding without enforcement."),be)):Promise.resolve(be)]);if(!r)throw new pe(`Connector '${t}' not found. Run '${"ms"} connector list' to see available connector IDs.`);let c=(r.name??t).toLowerCase(),f=new Map(i.allowedConnectors.map(p=>[p.connectorId.toLowerCase(),p])),a=new Set((i.blockedConnectors??[]).map(p=>p.connectorId.toLowerCase()));if(i.defaultBehavior==="Block"?!f.has(c):a.has(c))throw new u(`Connector '${r.properties.displayName??t}' is blocked by your organization's connector policy.`);return{connector:r,tenantId:o,policy:i}}async function Q(e){let{argumentProvider:t,apiId:n,connector:o,useSso:r}=e,i=x(),c=$(),f=U(),a=await ae(n,c);if(!i.interactive)return Le({argumentProvider:t,apiId:n,connector:o,connections:a??[],useSso:r});if(r){if(!Y(o))throw new u(`--use-sso was set but '${o.properties.displayName??n}' does not support single sign-on (SSO) authentication.
|
|
10
10
|
To fix: Re-run without --use-sso to create a connection interactively.`);let l=(a??[]).filter(s=>z(s,o));if(l.length>0){let[s]=l;return h(`Using existing SSO connection '${s.properties.displayName}' (${s.name}).`),l.length>1&&I(`Multiple SSO connections found for '${o.properties.displayName??n}'. Re-run with --connection-id <id> or -c <id> to use a specific one.`),{connectionId:s.name,autoSelected:!0}}let m=await W(t,n);return T(`Created a new connection '${m.properties.displayName}' (${m.name}).`),{connectionId:m.name,autoSelected:!1}}let d=[...a.map(l=>({value:l.name,label:l.properties.displayName,hint:l.name})),{value:Ae,label:"(Create a new connection)"}],p=await Ce({message:"Select a connection:",options:d});if(p===Ae){if(G(o))try{return{connectionId:(await W(t,n)).name,autoSelected:!1}}catch(y){I(`Silent connection creation failed: ${y instanceof Error?y.message:String(y)}`),h(`Falling back to browser-based connection creation...
|
|
@@ -38,4 +38,4 @@ ${w.app.add.connector.description}`),e.addExamples(w.app.add.connector.deprecate
|
|
|
38
38
|
/*!
|
|
39
39
|
* Copyright (C) Microsoft Corporation. All rights reserved.
|
|
40
40
|
*/
|
|
41
|
-
//# sourceMappingURL=AddConnector-
|
|
41
|
+
//# sourceMappingURL=AddConnector-5DUBFLEK.js.map
|
|
@@ -4,8 +4,8 @@ import { dirname as __pathDirname } from 'node:path';
|
|
|
4
4
|
const require = __createRequire(import.meta.url);
|
|
5
5
|
const __filename = __fileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = __pathDirname(__filename);
|
|
7
|
-
import{a as i,d as u,h as a,i as s}from"./chunk-PVAIJSAI.js";import{a as o}from"./chunk-
|
|
7
|
+
import{a as i,d as u,h as a,i as s}from"./chunk-PVAIJSAI.js";import{a as o}from"./chunk-47LJLFDF.js";import"./chunk-PPW4XUZO.js";import"./chunk-Y5AMO72S.js";import"./chunk-UT667QSU.js";async function l(n){n.setDescription(o.auth.status.description),n.addExamples(o.auth.status.examples),await n.runVerb();let t=await n.getAccountManager().listCachedAccountsAsync();if(n.isJsonMode()){let e=t.find(c=>c.isActive);u({signedIn:t.length>0,activeAccount:e?{username:e.username,homeAccountId:e.homeAccountId}:null,accounts:t.map(c=>({username:c.username,homeAccountId:c.homeAccountId,isActive:c.isActive}))});return}if(t.length===0){s(`Not signed in. Run \`${"ms"} auth login\` to authenticate.`);return}if(t.length===1){a(`Signed in as ${t[0].username} (account ID: ${t[0].homeAccountId})`);return}let m=t.some(e=>e.isActive);i({title:"Cached accounts",columns:[{header:"Active"},{header:"Username"},{header:"Account ID"}],rows:t.map(e=>[e.isActive?"*":"",e.username,e.homeAccountId])}),m||s(`No active account selected. Run \`${"ms"} auth switch\` to choose one.`)}export{l as authStatusAsync};
|
|
8
8
|
/*!
|
|
9
9
|
* Copyright (C) Microsoft Corporation. All rights reserved.
|
|
10
10
|
*/
|
|
11
|
-
//# sourceMappingURL=AuthStatus-
|
|
11
|
+
//# sourceMappingURL=AuthStatus-6DMK7O6W.js.map
|
|
@@ -4,10 +4,10 @@ import { dirname as __pathDirname } from 'node:path';
|
|
|
4
4
|
const require = __createRequire(import.meta.url);
|
|
5
5
|
const __filename = __fileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = __pathDirname(__filename);
|
|
7
|
-
import{c as f}from"./chunk-
|
|
7
|
+
import{c as f}from"./chunk-SNWTSI75.js";import{va as h}from"./chunk-4LIR3ZYP.js";import{b as l}from"./chunk-RBG2H562.js";import"./chunk-UNJJUCSA.js";import"./chunk-6RSE3J4X.js";import"./chunk-EX6IKPAO.js";import{a as u}from"./chunk-3JIZGVCA.js";import{c as p,d as r,i as A}from"./chunk-PVAIJSAI.js";import{a as i}from"./chunk-47LJLFDF.js";import"./chunk-PPW4XUZO.js";import"./chunk-Y5AMO72S.js";import"./chunk-UT667QSU.js";async function b(t){t.setDescription(i.auth.switch.description),t.addExamples(i.auth.switch.examples),t.addOption({flags:{key:u.Account.name},description:i.auth.switch.options.account,optionalInNonInteractive:!0}),await t.runVerb();let n=t.getAccountManager(),s=await t.getOption(u.Account.name,!0),o=t.isJsonMode(),e=await n.listCachedAccountsAsync();if(e.length===0){if(o){r({activeAccount:null});return}A(`No cached accounts. Run \`${"ms"} auth login\` first.`);return}let a=s;if(!a){if(e.length===1){let c=await n.setActiveAccountAsync(e[0].homeAccountId);d(c.username,c.homeAccountId,o);return}if(o||!h().interactive)throw new l(`Multiple accounts are cached. Pass --account <email> to choose one.
|
|
8
8
|
`+e.map(c=>` - ${c.username}`).join(`
|
|
9
9
|
`));a=await f({message:"Choose the active account:",options:e.map(c=>({value:c.homeAccountId,label:c.username,hint:c.isActive?"currently active":void 0}))})}let m=await n.setActiveAccountAsync(a);d(m.username,m.homeAccountId,o)}function d(t,n,s){s?r({activeAccount:{username:t,homeAccountId:n}}):p(`Active account is ${t}.`)}export{b as authSwitchAsync};
|
|
10
10
|
/*!
|
|
11
11
|
* Copyright (C) Microsoft Corporation. All rights reserved.
|
|
12
12
|
*/
|
|
13
|
-
//# sourceMappingURL=AuthSwitch-
|
|
13
|
+
//# sourceMappingURL=AuthSwitch-NUQIIRCG.js.map
|
package/dist/Bin.js
CHANGED
|
@@ -5,7 +5,7 @@ import { dirname as __pathDirname } from 'node:path';
|
|
|
5
5
|
const require = __createRequire(import.meta.url);
|
|
6
6
|
const __filename = __fileURLToPath(import.meta.url);
|
|
7
7
|
const __dirname = __pathDirname(__filename);
|
|
8
|
-
import{i as a}from"./chunk-
|
|
8
|
+
import{i as a}from"./chunk-AQLFVAFU.js";import"./chunk-6RSE3J4X.js";import"./chunk-EX6IKPAO.js";import"./chunk-47LJLFDF.js";import"./chunk-PPW4XUZO.js";import"./chunk-Y5AMO72S.js";import"./chunk-UT667QSU.js";if(!a(process.argv)){let{boot:o}=await import("./Cli-LYSWG64H.js");await o()}
|
|
9
9
|
/*!
|
|
10
10
|
* Copyright (C) Microsoft Corporation. All rights reserved.
|
|
11
11
|
*/
|
|
@@ -4,8 +4,8 @@ import { dirname as __pathDirname } from 'node:path';
|
|
|
4
4
|
const require = __createRequire(import.meta.url);
|
|
5
5
|
const __filename = __fileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = __pathDirname(__filename);
|
|
7
|
-
import{b as $}from"./chunk-
|
|
7
|
+
import{b as $}from"./chunk-VMSJG53Y.js";import"./chunk-OL6CTXQR.js";import{a as R}from"./chunk-KYL2Y5G4.js";import"./chunk-7GGFN2IW.js";import"./chunk-4VBFOKV6.js";import{d as I}from"./chunk-7BRIEYGR.js";import{h as B}from"./chunk-SNWTSI75.js";import{X as S,ua as M,va as N}from"./chunk-4LIR3ZYP.js";import{b as c}from"./chunk-RBG2H562.js";import"./chunk-UNJJUCSA.js";import"./chunk-6RSE3J4X.js";import"./chunk-EX6IKPAO.js";import{n as e}from"./chunk-3JIZGVCA.js";import{c as p,d as r,e as A,h as b}from"./chunk-PVAIJSAI.js";import{a as i}from"./chunk-47LJLFDF.js";import{a as h}from"./chunk-PPW4XUZO.js";import"./chunk-Y5AMO72S.js";import"./chunk-UT667QSU.js";async function Q(t){if(D(t),await t.runVerb(),!t.getEnvironmentId())throw new c(`\`ms app build-app\` is deprecated and the \`--environment-id\` flag has been removed. The replacement flow is \`ms app create\` (scaffolds the app and writes ${h}) followed by \`ms app deploy\`. To run this deprecated command, invoke it from a directory with a ${h} (created by \`ms app create\`).`);let a=await t.getTenantIdAsync();if(!a)throw new c("Unable to determine tenant ID. Ensure you are logged in.");let l=await B(t),v=await t.getOption(e.NoWait.camelName)===!1,o=await t.getOption("commit",!0),m,y=!1;if(!o){let n=I();if(!n)throw new c("Could not determine the latest commit ID. Use --commit or -c to specify it.");o=n.commitSha,m=n.detached?void 0:n.branch,y=!0}let d=t.isJsonMode();y&&!d&&b(m?`Using branch '${m}' at commit ${o}.`:`Detached HEAD at commit ${o}.`);let w=N().appConfig,u=w?.repoType,C=w?.externalRepoUrl,F=await t.getOption(e.OpenBrowser.camelName,!0)??!1,k=await t.getOption(e.ForceReauth.camelName,!0)??!1;d&&u==="github"&&A({phase:"build-validation"});let g=await R(({isRetry:n})=>S({logger:M(),actionsParams:{appName:l,commitSha:o,...k&&!n&&u==="github"&&{forceReauth:!0}}}),{repoType:u,externalRepoUrl:C,tenantId:a,jsonMode:d,openBrowser:F,verb:"app build"});if(g===null){O(t.isJsonMode(),o);return}if(v){J(t.isJsonMode(),l,o);return}let f=await $({appName:l,commitSha:o,initialWaitMs:g.retryAfterMs??1e3,isJsonMode:t.isJsonMode()});t.isJsonMode()?r(f):(p(`Build status: ${f.status}`),f.status==="Succeeded"&&b(`Run \`ms app dev\` to run your app locally, or \`ms app deploy --commit ${o}\` to make this app live.`))}function D(t){t.setDescription(i.app.build.description),t.addExamples(i.app.build.examples),t.addOptions([{flags:{key:e.AppName.name},env:e.AppName.envVar,description:i.app.build.options.appName,optionalInNonInteractive:!0},{flags:{key:e.CommitSha.name,alias:e.CommitSha.alias},env:e.CommitSha.envVar,description:i.app.build.options.commitSha,optionalInNonInteractive:!0}]),t.addSwitch({flags:{key:e.NoWait.name},description:i.app.build.options.noWait}),t.addSwitch({flags:{key:e.OpenBrowser.name},description:i.app.build.options.openBrowser}),t.addSwitch({flags:{key:e.ForceReauth.name},description:i.app.build.options.forceReauth})}function J(t,s,a){if(t){r({commitSha:a,buildStatusCommand:`ms app build-status --app ${s} --commit ${a}`});return}p(`Build started for commit ${a}. Run \`ms app build-status --app ${s} --commit ${a}\` to check status.`)}function O(t,s){if(t){r({cached:!0,commitSha:s});return}p("Build already up to date for this commit.")}export{Q as buildMaafAppAsync};
|
|
8
8
|
/*!
|
|
9
9
|
* Copyright (C) Microsoft Corporation. All rights reserved.
|
|
10
10
|
*/
|
|
11
|
-
//# sourceMappingURL=BuildMaafApp-
|
|
11
|
+
//# sourceMappingURL=BuildMaafApp-A4IUU6LI.js.map
|