@metabase/cli 0.1.5 → 0.1.6
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 +115 -102
- package/dist/{add-collection-C_iovi9i.mjs → add-collection-BU8r3r2M.mjs} +9 -4
- package/dist/add-collection-C0w6ACQF.mjs +11 -0
- package/dist/{archive-Dvzrmdbk.mjs → archive-BNinrUak.mjs} +9 -8
- package/dist/{archive-WaEW85NB.mjs → archive-C1enZgKV.mjs} +8 -7
- package/dist/archive-CDA0KxL8.mjs +40 -0
- package/dist/{archive-BKPO8lEO.mjs → archive-CRhiBpPJ.mjs} +9 -8
- package/dist/{archive-DdaP94H3.mjs → archive-DMPS8Kih.mjs} +9 -8
- package/dist/archive-lWgqiFAt.mjs +40 -0
- package/dist/auth-CzXb_zB2.mjs +19 -0
- package/dist/{body-XtR7-uCO.mjs → body-DjdFxjpg.mjs} +4 -4
- package/dist/{branches-XUY4JY-X.mjs → branches-B1WRfG7-.mjs} +11 -7
- package/dist/{cancel-BrUVO_ax.mjs → cancel-Dl_Ho056.mjs} +7 -6
- package/dist/{cancel-task-oXheTOB6.mjs → cancel-task-CdigdCaO.mjs} +11 -7
- package/dist/capabilities-7e9MgquN.mjs +29 -0
- package/dist/card-DP4rfoOi.mjs +21 -0
- package/dist/{card-CQxvHeyP.mjs → card-DlCAaAPq.mjs} +1 -1
- package/dist/{cards-CONTTAG9.mjs → cards-BGiJS675.mjs} +8 -7
- package/dist/cli.mjs +264 -44
- package/dist/collection-tY18ezvn.mjs +21 -0
- package/dist/{predicates-CGO17Q15.mjs → command-augment-BH9qgQ5u.mjs} +66 -14
- package/dist/create-BNiva__H.mjs +52 -0
- package/dist/{create-Ca9lIDwP.mjs → create-BTcpaop_.mjs} +9 -8
- package/dist/{create-V-q2rU0T.mjs → create-BYlIju0b.mjs} +14 -12
- package/dist/{create-DZxUeqdf.mjs → create-Be_0Vier.mjs} +10 -9
- package/dist/{create-kYpjobrq.mjs → create-CHF313Qg.mjs} +13 -9
- package/dist/{create-swbIXdo5.mjs → create-CwGtmwqm.mjs} +14 -12
- package/dist/{create-Dq25vsMu.mjs → create-CzzrbL0u.mjs} +10 -9
- package/dist/{create-Le3Bqn7b.mjs → create-DGth_uOp.mjs} +14 -12
- package/dist/{create-branch-D5u14AxL.mjs → create-branch-DKZkoQ64.mjs} +11 -7
- package/dist/{create-Cs2xntFG.mjs → create-dhxPxfF3.mjs} +16 -14
- package/dist/{credentials-BIQ1cEzM.mjs → credentials-dzeq7ckm.mjs} +12 -11
- package/dist/{current-task-DCq7rk9V.mjs → current-task-CCRzm0_7.mjs} +11 -7
- package/dist/dashboard-ChM_Tu0l.mjs +22 -0
- package/dist/{dashboard-CnMD04PQ.mjs → dashboard-FY5UzJ_Z.mjs} +2 -1
- package/dist/{database-BSvzYlRe.mjs → database-CIXwHKjK.mjs} +3 -3
- package/dist/{database-vvig8k4x.mjs → database-lH-B3G1I.mjs} +1 -1
- package/dist/db-DrQn_i3W.mjs +22 -0
- package/dist/{remove-C6bS0Z6w.mjs → delete-CM3jnAeQ.mjs} +21 -20
- package/dist/{delete-CUx6RT9e.mjs → delete-Dimc-2y8.mjs} +9 -8
- package/dist/{delete-VTAS9EUt.mjs → delete-ZjnV35OJ.mjs} +9 -8
- package/dist/{delete-runtime-DfFMWJJ6.mjs → delete-runtime-B6RQo_pw.mjs} +5 -3
- package/dist/{delete-table-DzUneMKe.mjs → delete-table-agZJpivt.mjs} +9 -8
- package/dist/{deprovision-CpJfGgCt.mjs → deprovision-CwxcIT3k.mjs} +16 -12
- package/dist/{dirty-nkAOXxgC.mjs → dirty-D4d0yHqj.mjs} +11 -7
- package/dist/{docker-D5FTIoD0.mjs → docker-Oq80q3tu.mjs} +4 -4
- package/dist/{translate-Cqsd0Px5.mjs → eid-BXzaQh0o.mjs} +37 -22
- package/dist/error-C9S6PN3-.mjs +190 -0
- package/dist/{export-BWvY7X_G.mjs → export-DTygoXBP.mjs} +17 -16
- package/dist/field-Z6Pcxf4n.mjs +19 -0
- package/dist/{fields-dH16G5UV.mjs → fields-CoQi99gv.mjs} +9 -8
- package/dist/{get-BnBRKHr7.mjs → get-Bzys7vgp.mjs} +8 -7
- package/dist/{get-B7i_nYJB.mjs → get-C2p383Qc.mjs} +8 -7
- package/dist/{get-D96QEU49.mjs → get-C3HdQ91a.mjs} +8 -7
- package/dist/{get-DNN1X2gN.mjs → get-CP3Z3NiH.mjs} +9 -8
- package/dist/{get-CACaBFLt.mjs → get-C_w1kvN3.mjs} +9 -8
- package/dist/{get-D8e_RzZ0.mjs → get-CzuzeKSe.mjs} +10 -9
- package/dist/{get-C6SR3A9t.mjs → get-D3SbEQSE.mjs} +10 -9
- package/dist/{get-7macOPAI.mjs → get-DFxZXaKz.mjs} +7 -7
- package/dist/{get-DAWofnzK.mjs → get-DQTZG_NP.mjs} +8 -7
- package/dist/{get-BcqxMVC1.mjs → get-DSWFjy7O.mjs} +8 -7
- package/dist/{get-R7OaVL_t.mjs → get-Ddr0XLh7.mjs} +8 -7
- package/dist/{get-B08K82JV.mjs → get-Hc93A0Yz.mjs} +8 -7
- package/dist/{get-CKxlhMy1.mjs → get-lb7q3JYs.mjs} +7 -6
- package/dist/get-run-B7sKdaDU.mjs +38 -0
- package/dist/git-sync-CiGAad76.mjs +28 -0
- package/dist/{has-remote-changes-BAnIXQXU.mjs → has-remote-changes-BY10-nnE.mjs} +11 -7
- package/dist/{import-CfdPEMng.mjs → import-CiMz4Wz-.mjs} +17 -16
- package/dist/{input-BQ-BZA8h.mjs → input-cMSEqISy.mjs} +7 -4
- package/dist/{is-dirty-CZWcG0vj.mjs → is-dirty-BZOaryxT.mjs} +9 -4
- package/dist/is-dirty-Ume4oV0j.mjs +10 -0
- package/dist/{items-DqwahOKf.mjs → items-BWfvkY-J.mjs} +9 -8
- package/dist/key-C2XG394c.mjs +17 -0
- package/dist/license-Dxarh-gG.mjs +17 -0
- package/dist/{list-vF4EneaE.mjs → list--OYdUTtu.mjs} +7 -6
- package/dist/{list-yxVAE1S7.mjs → list-2j7GsXsl.mjs} +7 -6
- package/dist/{list-D41gfkKb.mjs → list-BI4zr8LW.mjs} +10 -8
- package/dist/{list-BpNU1neq.mjs → list-Brgh-Z2v.mjs} +8 -6
- package/dist/{list-ViT2KWhv.mjs → list-C3hfovHv.mjs} +7 -6
- package/dist/{list-CQkDqphl.mjs → list-CL7eCOQE.mjs} +7 -6
- package/dist/{list-L63TpX1t.mjs → list-Clz5igWg.mjs} +7 -7
- package/dist/list-D4sFiqX8.mjs +173 -0
- package/dist/{list-oftHLFbE.mjs → list-DXH7TlkU.mjs} +9 -7
- package/dist/{list-BqNMpIXy.mjs → list-DZ8fNUoQ.mjs} +9 -8
- package/dist/{list-Bkd7Nbds.mjs → list-SOG0whQ-.mjs} +7 -6
- package/dist/{list-J277Qtki.mjs → list-d58BprgJ.mjs} +7 -6
- package/dist/{list-DJcGwJ4W.mjs → list-sD5N3fGk.mjs} +9 -8
- package/dist/{list-DBOYoJtA.mjs → list-zSO0DMw-.mjs} +10 -6
- package/dist/{login-D1nZwgKv.mjs → login-Bm2AnCez.mjs} +65 -80
- package/dist/{logout-DD4q5whi.mjs → logout-BlyRJODO.mjs} +8 -7
- package/dist/{logs-Ci3mJE2z.mjs → logs-CywPikkL.mjs} +9 -8
- package/dist/{manifest-CGM7XNLC.mjs → manifest-BBR46KFM.mjs} +15 -15
- package/dist/measure-C44EK_xt.mjs +20 -0
- package/dist/{measure-BEQfnLdN.mjs → measure-ClESGxIb.mjs} +2 -2
- package/dist/{metadata-BDat-jN9.mjs → metadata-B8ZSF9LA.mjs} +10 -9
- package/dist/{metadata-29_qlqbz.mjs → metadata-DqiI2q9q.mjs} +9 -8
- package/dist/parse-enum-CrEWOhuY.mjs +11 -0
- package/dist/{parse-id-CysSaCbf.mjs → parse-id-lk_K-CEF.mjs} +1 -1
- package/dist/{parse-ref-D1yeDOn8.mjs → parse-ref-BiETXmvm.mjs} +1 -1
- package/dist/{parse-schemas-B10n01ez.mjs → parse-schemas-BqUdWUwq.mjs} +2 -2
- package/dist/{path-DLByFMMA.mjs → path-AEtZ3mBq.mjs} +7 -7
- package/dist/{poll-p9Y7-JEQ.mjs → poll-DHKDpCiq.mjs} +2 -2
- package/dist/{poll-task-BQe0NvJZ.mjs → poll-task-Cooi0lQV.mjs} +3 -20
- package/dist/{preflight-CvFu0Cct.mjs → preflight-aXV5LyDs.mjs} +4 -4
- package/dist/{process-zJeVJZTM.mjs → process-C7V8LJ-j.mjs} +1 -1
- package/dist/{prompt-DgDNy_Pc.mjs → prompt-CFKoys7k.mjs} +3 -1
- package/dist/{provision-BP-b4Are.mjs → provision-UWcNDoDe.mjs} +29 -24
- package/dist/{ps-BxQdpkr5.mjs → ps-CJU0EbrC.mjs} +5 -3
- package/dist/ps-DEroLgbI.mjs +11 -0
- package/dist/{query-CFH4nBlK.mjs → query-AaKzYnTY.mjs} +9 -8
- package/dist/{query-C7zTlFJA.mjs → query-BlsVNZpD.mjs} +15 -13
- package/dist/{remove-BuWxx3hY.mjs → remove-BFWun0e8.mjs} +9 -8
- package/dist/{remove-collection-Bc4roCq0.mjs → remove-collection-CoCmrrQs.mjs} +13 -9
- package/dist/{render-DuoDUTVL.mjs → render-CfznwleY.mjs} +15 -17
- package/dist/render-OQn3iRsI.mjs +32 -0
- package/dist/{rescan-values-DabyRYQ_.mjs → rescan-values-C0FDsjT7.mjs} +10 -9
- package/dist/{run-Cl-9RtC4.mjs → run-B4Wn43zm.mjs} +10 -9
- package/dist/{runs-BH6s1Zao.mjs → runs-Bbaszr18.mjs} +9 -8
- package/dist/{runtime-CDu6fykq.mjs → runtime-Dmv5VtUK.mjs} +657 -428
- package/dist/{schema-tables-i58wp_p3.mjs → schema-tables-CaWinbuK.mjs} +9 -8
- package/dist/{schemas-_m8RYRl9.mjs → schemas-DUgGpAyB.mjs} +7 -6
- package/dist/{search-DObOsjbP.mjs → search-BLrBXLUk.mjs} +12 -16
- package/dist/segment-B3Uwwcsm.mjs +20 -0
- package/dist/{set-CJA9dpK6.mjs → set-B8cUbRLD.mjs} +13 -12
- package/dist/{set-CwVWeAsi.mjs → set-DfGsta5O.mjs} +11 -10
- package/dist/{setting-Czy4ws6h.mjs → setting-D2p2MA7f.mjs} +3 -3
- package/dist/{setup-DqBOe3HZ.mjs → setup-C9ikBRw_.mjs} +9 -8
- package/dist/{skills-C2rTVj0n.mjs → skills-CUHIcQS6.mjs} +3 -3
- package/dist/{skills-CHU7uuDU.mjs → skills-CiN1OQ8W.mjs} +2 -2
- package/dist/snippet-B7D0uWlz.mjs +20 -0
- package/dist/{start-CfruN4wF.mjs → start-3PX3ahjT.mjs} +68 -37
- package/dist/{stash-CWuXKSZq.mjs → stash-EIDcSvpF.mjs} +17 -16
- package/dist/{status-D-RYZB9G.mjs → status-95ElRAu9.mjs} +12 -8
- package/dist/status-B0_MiZEf.mjs +100 -0
- package/dist/status-CEplmC44.mjs +34 -0
- package/dist/{stop-D8Hr4cKX.mjs → stop-CQ0XGrN8.mjs} +11 -10
- package/dist/{summary-Lt2XLBK9.mjs → summary-C12LiEuJ.mjs} +8 -7
- package/dist/{sync-schema-BDElSynU.mjs → sync-schema-Ba8M3DiX.mjs} +10 -9
- package/dist/{table-B-PYcgGb.mjs → table-C7a5V6Zn.mjs} +1 -1
- package/dist/table-e6h8SLVX.mjs +20 -0
- package/dist/transform-BMYh1lsC.mjs +25 -0
- package/dist/transform-job-Cm7z5TfH.mjs +20 -0
- package/dist/{transform-job-BrhOLO4M.mjs → transform-job-DeTDPMxt.mjs} +1 -1
- package/dist/{tree-DfvjDjmk.mjs → tree-Des2ZG9d.mjs} +6 -5
- package/dist/{update-CqnDMNtZ.mjs → update-Bx54nWEI.mjs} +17 -15
- package/dist/{update-D9Z8cL7h.mjs → update-CyIZdbIQ.mjs} +11 -10
- package/dist/{update-CVxOxmt6.mjs → update-DBi5U8zb.mjs} +16 -14
- package/dist/{update-BYduslhn.mjs → update-DHZubok3.mjs} +18 -14
- package/dist/{update-BgcroYkF.mjs → update-DSgceARZ.mjs} +11 -10
- package/dist/{update-zp7pCBZH.mjs → update-DzAN4SPj.mjs} +15 -13
- package/dist/{update-qnFY5IuC.mjs → update-F6DmZncY.mjs} +11 -10
- package/dist/{update-B0bjPqKC.mjs → update-_QfgNa53.mjs} +12 -11
- package/dist/{update-dashcard-CQ3kmmss.mjs → update-dashcard-wpSjv4M7.mjs} +11 -10
- package/dist/{update-DzgXF082.mjs → update-mYVnoYNV.mjs} +15 -13
- package/dist/{update-DuA8-cCq.mjs → update-njHe3j-s.mjs} +15 -13
- package/dist/{upgrade-CIgTr2CG.mjs → upgrade-iAuvhX-W.mjs} +9 -8
- package/dist/{url-B5MgZXzg.mjs → url-DWaT6WIZ.mjs} +11 -10
- package/dist/{uuid-CJz9TmHI.mjs → uuid-CMKnS8-z.mjs} +8 -6
- package/dist/{validate-CB0bu50i.mjs → validate-dPEOnOf8.mjs} +2 -1
- package/dist/{validate-query-CavIA0Q2.mjs → validate-query-Cw6WE5Y8.mjs} +3 -3
- package/dist/{values-BXN6tx1i.mjs → values-BfSTAbzc.mjs} +8 -7
- package/dist/verify-D5YtTqqp.mjs +79 -0
- package/dist/{wait-BFqBlg0y.mjs → wait-8yV9_WIo.mjs} +2 -2
- package/dist/{wait-tDp9ZOou.mjs → wait-Bv3Tsnv4.mjs} +12 -8
- package/dist/{wait-flags-CN-e9zNq.mjs → wait-flags-Dzq9BGQY.mjs} +20 -9
- package/dist/workspace-CKLZrR7l.mjs +26 -0
- package/dist/{workspace-credentials-4lIxxz4g.mjs → workspace-credentials-BXpABsNZ.mjs} +2 -2
- package/dist/{yaml-ECiog374.mjs → yaml-YTQiYJ9s.mjs} +1 -1
- package/package.json +2 -1
- package/skill-data/core/SKILL.md +55 -453
- package/skill-data/git-sync/SKILL.md +1 -1
- package/skill-data/mbql/SKILL.md +156 -0
- package/skill-data/mbql/references/operators.md +253 -0
- package/skill-data/transform/SKILL.md +2 -40
- package/skill-data/viz/SKILL.md +137 -0
- package/skill-data/viz/references/settings.md +312 -0
- package/skill-data/workspace/SKILL.md +45 -63
- package/skills/metabase-cli/SKILL.md +5 -26
- package/dist/add-collection-ucsyAMkV.mjs +0 -11
- package/dist/api-key-BENHbTbV.mjs +0 -13
- package/dist/auth-DICRtJDy.mjs +0 -19
- package/dist/card-l-UmrUIo.mjs +0 -20
- package/dist/collection-oV0olVY-.mjs +0 -19
- package/dist/command-augment-D9pI9Vbh.mjs +0 -11
- package/dist/create-CrUq6sib.mjs +0 -125
- package/dist/create-D3Z878yr.mjs +0 -50
- package/dist/dashboard-hbKDd36X.mjs +0 -20
- package/dist/db-qVK6NsdB.mjs +0 -22
- package/dist/eid-CDFXX_6H.mjs +0 -13
- package/dist/field-C0LE7RQI.mjs +0 -18
- package/dist/flag-pair-Fmcdkrfx.mjs +0 -17
- package/dist/get-run-CwFuR4Uw.mjs +0 -36
- package/dist/git-sync-DV7YjniX.mjs +0 -28
- package/dist/is-dirty-LxVbm2C5.mjs +0 -10
- package/dist/key-CCJdVWKc.mjs +0 -12
- package/dist/license-Cb6ewEJO.mjs +0 -17
- package/dist/list-DV6CONhp.mjs +0 -55
- package/dist/measure-XhJuL77y.mjs +0 -19
- package/dist/package-DFUprkSZ.mjs +0 -85
- package/dist/ps-Bk6unzaX.mjs +0 -11
- package/dist/segment-DfxZdJmR.mjs +0 -19
- package/dist/snippet-BCY4KHBU.mjs +0 -19
- package/dist/status-1oUnw803.mjs +0 -56
- package/dist/status-J9HIDcA5.mjs +0 -32
- package/dist/table-BwX3Ib5f.mjs +0 -19
- package/dist/transform-iaAi37V0.mjs +0 -24
- package/dist/transform-job-Bemonf82.mjs +0 -19
- package/dist/workspace-BBsT0H0g.mjs +0 -24
- /package/dist/{body-flags-BK7J6Daz.mjs → body-flags-D7q87Btw.mjs} +0 -0
- /package/dist/{field-B3gvaqpK.mjs → field-yomXlkvl.mjs} +0 -0
- /package/dist/{paginate-CTSfuYiF.mjs → paginate-Dfm9eO9A.mjs} +0 -0
- /package/dist/{revision-message-flag-oyq2xrDU.mjs → revision-message-flag-WmsIzUOM.mjs} +0 -0
- /package/dist/{segment-BMrUBz94.mjs → segment-Be2v4ilr.mjs} +0 -0
- /package/dist/{setting-CTaAeMci.mjs → setting-oL97SNeO.mjs} +0 -0
- /package/dist/{snippet-CSWqkslB.mjs → snippet-COggaWxx.mjs} +0 -0
- /package/dist/{transform-DR4ejuPM.mjs → transform-GTW3G-01.mjs} +0 -0
- /package/dist/{workspace-DUfqhPm5.mjs → workspace-BBXJczJK.mjs} +0 -0
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import "./input-cMSEqISy.mjs";
|
|
7
|
+
import "./field-yomXlkvl.mjs";
|
|
8
|
+
import { Card, CardCreateInput, cardView } from "./card-DlCAaAPq.mjs";
|
|
9
|
+
import { readBody } from "./body-DjdFxjpg.mjs";
|
|
10
|
+
import { bodyInputFlags } from "./body-flags-D7q87Btw.mjs";
|
|
11
|
+
import "./validate-dPEOnOf8.mjs";
|
|
12
|
+
import { CARD_DATASET_QUERY_LABELS, preflightMbql5Query, skipValidateFlag } from "./validate-query-Cw6WE5Y8.mjs";
|
|
13
|
+
|
|
14
|
+
//#region src/commands/card/create.ts
|
|
15
|
+
var create_default = defineMetabaseCommand({
|
|
16
|
+
meta: {
|
|
17
|
+
name: "create",
|
|
18
|
+
description: "Create a card (question, model, or metric) from JSON"
|
|
19
|
+
},
|
|
20
|
+
details: "The JSON body needs `name`, `display` (the visualization — e.g. table, bar, scalar), `dataset_query` (the query powering the card), and `visualization_settings` (`{}` is fine). When `dataset_query` is an MBQL 5 query it is checked against a bundled JSON Schema before sending — fix the reported errors, or pass --skip-validate to send anyway. Native-SQL and legacy queries are sent unchecked. See `mb skills get mbql`.",
|
|
21
|
+
capabilities: { minVersion: 58 },
|
|
22
|
+
args: {
|
|
23
|
+
...outputFlags,
|
|
24
|
+
...profileFlag,
|
|
25
|
+
...connectionFlags,
|
|
26
|
+
...bodyInputFlags,
|
|
27
|
+
...skipValidateFlag
|
|
28
|
+
},
|
|
29
|
+
outputSchema: Card,
|
|
30
|
+
examples: [
|
|
31
|
+
"cat card.json | mb card create",
|
|
32
|
+
"mb card create --file card.json",
|
|
33
|
+
"mb card create --body '{\"name\":\"x\",\"display\":\"table\",\"dataset_query\":{...},\"visualization_settings\":{}}'",
|
|
34
|
+
"mb card create --file card.json --skip-validate"
|
|
35
|
+
],
|
|
36
|
+
async run({ args, ctx, getClient }) {
|
|
37
|
+
const body = await readBody({
|
|
38
|
+
flag: args.body,
|
|
39
|
+
file: args.file
|
|
40
|
+
}, CardCreateInput);
|
|
41
|
+
preflightMbql5Query(body.dataset_query, CARD_DATASET_QUERY_LABELS, { skip: args["skip-validate"] === true });
|
|
42
|
+
const client = await getClient();
|
|
43
|
+
const created = await client.requestParsed(Card, "/api/card", {
|
|
44
|
+
method: "POST",
|
|
45
|
+
body
|
|
46
|
+
});
|
|
47
|
+
renderItem(created, cardView, ctx);
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
//#endregion
|
|
52
|
+
export { create_default as default };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import "./
|
|
6
|
-
import
|
|
7
|
-
import { readBody } from "./body-
|
|
8
|
-
import { bodyInputFlags } from "./body-flags-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import "./input-cMSEqISy.mjs";
|
|
7
|
+
import { readBody } from "./body-DjdFxjpg.mjs";
|
|
8
|
+
import { bodyInputFlags } from "./body-flags-D7q87Btw.mjs";
|
|
9
9
|
import { Collection, CollectionCreateInput, collectionView } from "./collection-B3sPXRLs.mjs";
|
|
10
10
|
|
|
11
11
|
//#region src/commands/collection/create.ts
|
|
@@ -14,6 +14,7 @@ var create_default = defineMetabaseCommand({
|
|
|
14
14
|
name: "create",
|
|
15
15
|
description: "Create a collection from a JSON spec"
|
|
16
16
|
},
|
|
17
|
+
capabilities: { minVersion: 58 },
|
|
17
18
|
args: {
|
|
18
19
|
...outputFlags,
|
|
19
20
|
...profileFlag,
|
|
@@ -1,21 +1,23 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import "./
|
|
6
|
-
import
|
|
7
|
-
import { readBody } from "./body-
|
|
8
|
-
import { bodyInputFlags } from "./body-flags-
|
|
9
|
-
import "./validate-
|
|
10
|
-
import { TRANSFORM_SOURCE_QUERY_LABELS, preflightMbql5Query, skipValidateFlag } from "./validate-query-
|
|
11
|
-
import { Transform, TransformCreateInput, transformView } from "./transform-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import "./input-cMSEqISy.mjs";
|
|
7
|
+
import { readBody } from "./body-DjdFxjpg.mjs";
|
|
8
|
+
import { bodyInputFlags } from "./body-flags-D7q87Btw.mjs";
|
|
9
|
+
import "./validate-dPEOnOf8.mjs";
|
|
10
|
+
import { TRANSFORM_SOURCE_QUERY_LABELS, preflightMbql5Query, skipValidateFlag } from "./validate-query-Cw6WE5Y8.mjs";
|
|
11
|
+
import { Transform, TransformCreateInput, transformView } from "./transform-GTW3G-01.mjs";
|
|
12
12
|
|
|
13
13
|
//#region src/commands/transform/create.ts
|
|
14
14
|
var create_default = defineMetabaseCommand({
|
|
15
15
|
meta: {
|
|
16
16
|
name: "create",
|
|
17
|
-
description: "Create a transform
|
|
17
|
+
description: "Create a transform from JSON"
|
|
18
18
|
},
|
|
19
|
+
details: "The JSON body needs a `name`, a `source` (the query to run — native SQL or MBQL — under `source.query`), and a `target` (the warehouse table to write, with `database`/`schema`/`name`). When `source.query` is an MBQL 5 query it is checked against a bundled JSON Schema before sending; pass --skip-validate to bypass. See `mb skills get mbql`.",
|
|
20
|
+
capabilities: { minVersion: 59 },
|
|
19
21
|
args: {
|
|
20
22
|
...outputFlags,
|
|
21
23
|
...profileFlag,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import "./
|
|
6
|
-
import
|
|
7
|
-
import { readBody } from "./body-
|
|
8
|
-
import { bodyInputFlags } from "./body-flags-
|
|
9
|
-
import { Snippet, SnippetCreateInput, snippetView } from "./snippet-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import "./input-cMSEqISy.mjs";
|
|
7
|
+
import { readBody } from "./body-DjdFxjpg.mjs";
|
|
8
|
+
import { bodyInputFlags } from "./body-flags-D7q87Btw.mjs";
|
|
9
|
+
import { Snippet, SnippetCreateInput, snippetView } from "./snippet-COggaWxx.mjs";
|
|
10
10
|
|
|
11
11
|
//#region src/commands/snippet/create.ts
|
|
12
12
|
var create_default = defineMetabaseCommand({
|
|
@@ -14,6 +14,7 @@ var create_default = defineMetabaseCommand({
|
|
|
14
14
|
name: "create",
|
|
15
15
|
description: "Create a native query snippet from a JSON spec"
|
|
16
16
|
},
|
|
17
|
+
capabilities: { minVersion: 58 },
|
|
17
18
|
args: {
|
|
18
19
|
...outputFlags,
|
|
19
20
|
...profileFlag,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import "./
|
|
6
|
-
import
|
|
7
|
-
import { readBody } from "./body-
|
|
8
|
-
import { bodyInputFlags } from "./body-flags-
|
|
9
|
-
import { Workspace, WorkspaceCreateInput, workspaceView } from "./workspace-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import "./input-cMSEqISy.mjs";
|
|
7
|
+
import { readBody } from "./body-DjdFxjpg.mjs";
|
|
8
|
+
import { bodyInputFlags } from "./body-flags-D7q87Btw.mjs";
|
|
9
|
+
import { Workspace, WorkspaceCreateInput, workspaceView } from "./workspace-BBXJczJK.mjs";
|
|
10
10
|
|
|
11
11
|
//#region src/commands/workspace/create.ts
|
|
12
12
|
var create_default = defineMetabaseCommand({
|
|
@@ -14,6 +14,10 @@ var create_default = defineMetabaseCommand({
|
|
|
14
14
|
name: "create",
|
|
15
15
|
description: "Create a workspace"
|
|
16
16
|
},
|
|
17
|
+
capabilities: {
|
|
18
|
+
minVersion: 62,
|
|
19
|
+
tokenFeature: "workspaces"
|
|
20
|
+
},
|
|
17
21
|
args: {
|
|
18
22
|
...outputFlags,
|
|
19
23
|
...profileFlag,
|
|
@@ -1,21 +1,23 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import "./
|
|
6
|
-
import
|
|
7
|
-
import { readBody } from "./body-
|
|
8
|
-
import { bodyInputFlags } from "./body-flags-
|
|
9
|
-
import "./validate-
|
|
10
|
-
import { MEASURE_DEFINITION_LABELS, preflightMbql5Query, skipValidateFlag } from "./validate-query-
|
|
11
|
-
import { Measure, MeasureCreateInput, measureView } from "./measure-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import "./input-cMSEqISy.mjs";
|
|
7
|
+
import { readBody } from "./body-DjdFxjpg.mjs";
|
|
8
|
+
import { bodyInputFlags } from "./body-flags-D7q87Btw.mjs";
|
|
9
|
+
import "./validate-dPEOnOf8.mjs";
|
|
10
|
+
import { MEASURE_DEFINITION_LABELS, preflightMbql5Query, skipValidateFlag } from "./validate-query-Cw6WE5Y8.mjs";
|
|
11
|
+
import { Measure, MeasureCreateInput, measureView } from "./measure-ClESGxIb.mjs";
|
|
12
12
|
|
|
13
13
|
//#region src/commands/measure/create.ts
|
|
14
14
|
var create_default = defineMetabaseCommand({
|
|
15
15
|
meta: {
|
|
16
16
|
name: "create",
|
|
17
|
-
description: "Create a measure
|
|
17
|
+
description: "Create a measure (saved aggregation) from JSON"
|
|
18
18
|
},
|
|
19
|
+
details: "A measure is a reusable, saved aggregation tied to a table. The JSON body needs `name`, `table_id`, and a `definition` (an MBQL query holding exactly one aggregation). An MBQL 5 `definition` is checked against a bundled JSON Schema before sending; pass --skip-validate to bypass. See `mb skills get mbql`.",
|
|
20
|
+
capabilities: { minVersion: 59 },
|
|
19
21
|
args: {
|
|
20
22
|
...outputFlags,
|
|
21
23
|
...profileFlag,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import "./
|
|
6
|
-
import
|
|
7
|
-
import { readBody } from "./body-
|
|
8
|
-
import { bodyInputFlags } from "./body-flags-
|
|
9
|
-
import { TransformJob, TransformJobCreateInput, transformJobView } from "./transform-job-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import "./input-cMSEqISy.mjs";
|
|
7
|
+
import { readBody } from "./body-DjdFxjpg.mjs";
|
|
8
|
+
import { bodyInputFlags } from "./body-flags-D7q87Btw.mjs";
|
|
9
|
+
import { TransformJob, TransformJobCreateInput, transformJobView } from "./transform-job-DeTDPMxt.mjs";
|
|
10
10
|
|
|
11
11
|
//#region src/commands/transform-job/create.ts
|
|
12
12
|
var create_default = defineMetabaseCommand({
|
|
@@ -14,6 +14,7 @@ var create_default = defineMetabaseCommand({
|
|
|
14
14
|
name: "create",
|
|
15
15
|
description: "Create a transform job"
|
|
16
16
|
},
|
|
17
|
+
capabilities: { minVersion: 59 },
|
|
17
18
|
args: {
|
|
18
19
|
...outputFlags,
|
|
19
20
|
...profileFlag,
|
|
@@ -1,21 +1,23 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import "./
|
|
6
|
-
import
|
|
7
|
-
import { readBody } from "./body-
|
|
8
|
-
import { bodyInputFlags } from "./body-flags-
|
|
9
|
-
import "./validate-
|
|
10
|
-
import { SEGMENT_DEFINITION_LABELS, preflightMbql5Query, skipValidateFlag } from "./validate-query-
|
|
11
|
-
import { Segment, SegmentCreateInput, segmentView } from "./segment-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import "./input-cMSEqISy.mjs";
|
|
7
|
+
import { readBody } from "./body-DjdFxjpg.mjs";
|
|
8
|
+
import { bodyInputFlags } from "./body-flags-D7q87Btw.mjs";
|
|
9
|
+
import "./validate-dPEOnOf8.mjs";
|
|
10
|
+
import { SEGMENT_DEFINITION_LABELS, preflightMbql5Query, skipValidateFlag } from "./validate-query-Cw6WE5Y8.mjs";
|
|
11
|
+
import { Segment, SegmentCreateInput, segmentView } from "./segment-Be2v4ilr.mjs";
|
|
12
12
|
|
|
13
13
|
//#region src/commands/segment/create.ts
|
|
14
14
|
var create_default = defineMetabaseCommand({
|
|
15
15
|
meta: {
|
|
16
16
|
name: "create",
|
|
17
|
-
description: "Create a segment
|
|
17
|
+
description: "Create a segment (saved filter) from JSON"
|
|
18
18
|
},
|
|
19
|
+
details: "A segment is a reusable, saved row filter tied to a table. The JSON body needs `name`, `table_id`, and a `definition` (an MBQL query holding the filter). An MBQL 5 `definition` is checked against a bundled JSON Schema before sending; pass --skip-validate to bypass. See `mb skills get mbql`.",
|
|
20
|
+
capabilities: { minVersion: 58 },
|
|
19
21
|
args: {
|
|
20
22
|
...outputFlags,
|
|
21
23
|
...profileFlag,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import { REMOTE_SYNC_PATHS } from "./poll-task-
|
|
7
|
-
import "./poll-
|
|
1
|
+
import { ConfigError } from "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import { REMOTE_SYNC_PATHS } from "./poll-task-Cooi0lQV.mjs";
|
|
7
|
+
import "./poll-DHKDpCiq.mjs";
|
|
8
8
|
import { z } from "zod";
|
|
9
9
|
|
|
10
10
|
//#region src/commands/git-sync/create-branch.ts
|
|
@@ -27,6 +27,10 @@ var create_branch_default = defineMetabaseCommand({
|
|
|
27
27
|
name: "create-branch",
|
|
28
28
|
description: "Create a new branch on the git remote and switch git-sync to it"
|
|
29
29
|
},
|
|
30
|
+
capabilities: {
|
|
31
|
+
minVersion: 60,
|
|
32
|
+
tokenFeature: "remote_sync"
|
|
33
|
+
},
|
|
30
34
|
args: {
|
|
31
35
|
...outputFlags,
|
|
32
36
|
...profileFlag,
|
|
@@ -1,23 +1,25 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import "./
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import "./
|
|
10
|
-
import "./
|
|
11
|
-
import "./validate-
|
|
12
|
-
import { Dashboard, DashboardCreateInput, DashboardDetail, dashboardView } from "./dashboard-
|
|
13
|
-
import { preflightDashcardCardReferences, wrapChainedDashboardWriteError } from "./preflight-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import "./input-cMSEqISy.mjs";
|
|
7
|
+
import "./field-yomXlkvl.mjs";
|
|
8
|
+
import "./card-DlCAaAPq.mjs";
|
|
9
|
+
import { readBody } from "./body-DjdFxjpg.mjs";
|
|
10
|
+
import { bodyInputFlags } from "./body-flags-D7q87Btw.mjs";
|
|
11
|
+
import "./validate-dPEOnOf8.mjs";
|
|
12
|
+
import { Dashboard, DashboardCreateInput, DashboardDetail, dashboardView } from "./dashboard-FY5UzJ_Z.mjs";
|
|
13
|
+
import { preflightDashcardCardReferences, wrapChainedDashboardWriteError } from "./preflight-aXV5LyDs.mjs";
|
|
14
14
|
|
|
15
15
|
//#region src/commands/dashboard/create.ts
|
|
16
16
|
var create_default = defineMetabaseCommand({
|
|
17
17
|
meta: {
|
|
18
18
|
name: "create",
|
|
19
|
-
description: "Create a dashboard from
|
|
19
|
+
description: "Create a dashboard from JSON"
|
|
20
20
|
},
|
|
21
|
+
details: "Any positive card_id referenced from dashcards is pre-flight-validated (exists and readable, not archived) before the dashboard is created.",
|
|
22
|
+
capabilities: { minVersion: 58 },
|
|
21
23
|
args: {
|
|
22
24
|
...outputFlags,
|
|
23
25
|
...profileFlag,
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import {
|
|
6
|
-
import { parseId } from "./parse-id-
|
|
7
|
-
import "./poll-
|
|
8
|
-
import "./yaml-
|
|
9
|
-
import "./process-
|
|
10
|
-
import { checkDockerReady, readContainerCredentialsFile, requireWorkspaceContainerLocation } from "./docker-
|
|
11
|
-
import { WorkspaceCredentials } from "./workspace-credentials-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { outputFlags } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand, localUrl, parseJson } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import { parseId } from "./parse-id-lk_K-CEF.mjs";
|
|
7
|
+
import "./poll-DHKDpCiq.mjs";
|
|
8
|
+
import "./yaml-YTQiYJ9s.mjs";
|
|
9
|
+
import "./process-C7V8LJ-j.mjs";
|
|
10
|
+
import { checkDockerReady, readContainerCredentialsFile, requireWorkspaceContainerLocation } from "./docker-Oq80q3tu.mjs";
|
|
11
|
+
import { WorkspaceCredentials } from "./workspace-credentials-BXpABsNZ.mjs";
|
|
12
12
|
import { z } from "zod";
|
|
13
13
|
|
|
14
14
|
//#region src/commands/workspace/credentials.ts
|
|
@@ -55,6 +55,7 @@ var credentials_default = defineMetabaseCommand({
|
|
|
55
55
|
name: "credentials",
|
|
56
56
|
description: "Read the workspace child instance's admin credentials (email + password + API key) from the running container"
|
|
57
57
|
},
|
|
58
|
+
capabilities: null,
|
|
58
59
|
args: {
|
|
59
60
|
...outputFlags,
|
|
60
61
|
id: {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import {
|
|
6
|
-
import { SyncTaskOrIdle, fetchCurrentTask, syncTaskIdleView, syncTaskView } from "./poll-task-
|
|
7
|
-
import "./poll-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import { SyncTaskOrIdle, fetchCurrentTask, syncTaskIdleView, syncTaskView } from "./poll-task-Cooi0lQV.mjs";
|
|
7
|
+
import "./poll-DHKDpCiq.mjs";
|
|
8
8
|
|
|
9
9
|
//#region src/commands/git-sync/current-task.ts
|
|
10
10
|
const CurrentTaskResult = SyncTaskOrIdle;
|
|
@@ -13,6 +13,10 @@ var current_task_default = defineMetabaseCommand({
|
|
|
13
13
|
name: "current-task",
|
|
14
14
|
description: "Get the most recent git-sync task (or idle if none)"
|
|
15
15
|
},
|
|
16
|
+
capabilities: {
|
|
17
|
+
minVersion: 60,
|
|
18
|
+
tokenFeature: "remote_sync"
|
|
19
|
+
},
|
|
16
20
|
args: {
|
|
17
21
|
...outputFlags,
|
|
18
22
|
...profileFlag,
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { defineCommand } from "citty";
|
|
2
|
+
|
|
3
|
+
//#region src/commands/dashboard/index.ts
|
|
4
|
+
var dashboard_default = defineCommand({
|
|
5
|
+
meta: {
|
|
6
|
+
name: "dashboard",
|
|
7
|
+
alias: "dashboards",
|
|
8
|
+
description: "Manage Metabase dashboards"
|
|
9
|
+
},
|
|
10
|
+
subCommands: {
|
|
11
|
+
list: () => import("./list-DXH7TlkU.mjs").then((mod) => mod.default),
|
|
12
|
+
get: () => import("./get-DSWFjy7O.mjs").then((mod) => mod.default),
|
|
13
|
+
cards: () => import("./cards-BGiJS675.mjs").then((mod) => mod.default),
|
|
14
|
+
create: () => import("./create-dhxPxfF3.mjs").then((mod) => mod.default),
|
|
15
|
+
update: () => import("./update-Bx54nWEI.mjs").then((mod) => mod.default),
|
|
16
|
+
"update-dashcard": () => import("./update-dashcard-wpSjv4M7.mjs").then((mod) => mod.default),
|
|
17
|
+
archive: () => import("./archive-CDA0KxL8.mjs").then((mod) => mod.default)
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
//#endregion
|
|
22
|
+
export { dashboard_default as default };
|
|
@@ -156,7 +156,8 @@ const DashcardPatchInput = z.object({
|
|
|
156
156
|
dashboard_tab_id: z.number().int().nullable().optional(),
|
|
157
157
|
parameter_mappings: z.array(z.unknown()).optional(),
|
|
158
158
|
inline_parameters: z.array(z.string()).optional(),
|
|
159
|
-
visualization_settings: z.unknown().optional()
|
|
159
|
+
visualization_settings: z.unknown().optional(),
|
|
160
|
+
series: z.array(z.unknown()).optional()
|
|
160
161
|
}).strict().refine((value) => Object.keys(value).length > 0, { message: "patch must contain at least one field" });
|
|
161
162
|
|
|
162
163
|
//#endregion
|
|
@@ -7,9 +7,9 @@ var database_default = defineCommand({
|
|
|
7
7
|
description: "Manage databases provisioned to a workspace"
|
|
8
8
|
},
|
|
9
9
|
subCommands: {
|
|
10
|
-
provision: () => import("./provision-
|
|
11
|
-
update: () => import("./update-
|
|
12
|
-
deprovision: () => import("./deprovision-
|
|
10
|
+
provision: () => import("./provision-UWcNDoDe.mjs").then((mod) => mod.default),
|
|
11
|
+
update: () => import("./update-DHZubok3.mjs").then((mod) => mod.default),
|
|
12
|
+
deprovision: () => import("./deprovision-CwxcIT3k.mjs").then((mod) => mod.default)
|
|
13
13
|
}
|
|
14
14
|
});
|
|
15
15
|
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { defineCommand } from "citty";
|
|
2
|
+
|
|
3
|
+
//#region src/commands/db/index.ts
|
|
4
|
+
var db_default = defineCommand({
|
|
5
|
+
meta: {
|
|
6
|
+
name: "db",
|
|
7
|
+
description: "Inspect and sync Metabase databases",
|
|
8
|
+
alias: "database"
|
|
9
|
+
},
|
|
10
|
+
subCommands: {
|
|
11
|
+
list: () => import("./list-DZ8fNUoQ.mjs").then((m) => m.default),
|
|
12
|
+
get: () => import("./get-CzuzeKSe.mjs").then((m) => m.default),
|
|
13
|
+
metadata: () => import("./metadata-B8ZSF9LA.mjs").then((m) => m.default),
|
|
14
|
+
schemas: () => import("./schemas-DUgGpAyB.mjs").then((m) => m.default),
|
|
15
|
+
"schema-tables": () => import("./schema-tables-CaWinbuK.mjs").then((m) => m.default),
|
|
16
|
+
"sync-schema": () => import("./sync-schema-Ba8M3DiX.mjs").then((m) => m.default),
|
|
17
|
+
"rescan-values": () => import("./rescan-values-C0FDsjT7.mjs").then((m) => m.default)
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
//#endregion
|
|
22
|
+
export { db_default as default };
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import {
|
|
4
|
-
import "./
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import "./poll-
|
|
9
|
-
import "./process-
|
|
10
|
-
import { checkDockerReady, containerNameFor, removeContainer, removeVolume, volumeNameFor } from "./docker-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { outputFlags } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import { renderItem } from "./render-CfznwleY.mjs";
|
|
6
|
+
import { promptConfirm } from "./prompt-CFKoys7k.mjs";
|
|
7
|
+
import { parseId } from "./parse-id-lk_K-CEF.mjs";
|
|
8
|
+
import "./poll-DHKDpCiq.mjs";
|
|
9
|
+
import "./process-C7V8LJ-j.mjs";
|
|
10
|
+
import { checkDockerReady, containerNameFor, removeContainer, removeVolume, volumeNameFor } from "./docker-Oq80q3tu.mjs";
|
|
11
11
|
import { z } from "zod";
|
|
12
12
|
|
|
13
|
-
//#region src/commands/workspace/
|
|
14
|
-
const
|
|
13
|
+
//#region src/commands/workspace/delete.ts
|
|
14
|
+
const DeleteResult = z.object({
|
|
15
15
|
workspace_id: z.number().int().positive(),
|
|
16
16
|
container_name: z.string(),
|
|
17
17
|
volume_name: z.string(),
|
|
18
18
|
removed_container: z.boolean(),
|
|
19
19
|
removed_volume: z.boolean()
|
|
20
20
|
});
|
|
21
|
-
const
|
|
22
|
-
compactPick:
|
|
21
|
+
const deleteResultView = {
|
|
22
|
+
compactPick: DeleteResult.pick({
|
|
23
23
|
workspace_id: true,
|
|
24
24
|
removed_container: true,
|
|
25
25
|
removed_volume: true
|
|
@@ -47,11 +47,12 @@ const removeResultView = {
|
|
|
47
47
|
}
|
|
48
48
|
]
|
|
49
49
|
};
|
|
50
|
-
var
|
|
50
|
+
var delete_default = defineMetabaseCommand({
|
|
51
51
|
meta: {
|
|
52
|
-
name: "
|
|
52
|
+
name: "delete",
|
|
53
53
|
description: "Stop and remove the local container + app-db volume (does not affect remote)"
|
|
54
54
|
},
|
|
55
|
+
capabilities: null,
|
|
55
56
|
args: {
|
|
56
57
|
...outputFlags,
|
|
57
58
|
id: {
|
|
@@ -70,8 +71,8 @@ var remove_default = defineMetabaseCommand({
|
|
|
70
71
|
default: false
|
|
71
72
|
}
|
|
72
73
|
},
|
|
73
|
-
outputSchema:
|
|
74
|
-
examples: ["mb workspace
|
|
74
|
+
outputSchema: DeleteResult,
|
|
75
|
+
examples: ["mb workspace delete 1 --yes", "mb workspace delete 1 --keep-volume --yes"],
|
|
75
76
|
async run({ args, ctx }) {
|
|
76
77
|
const workspaceId = parseId(args.id);
|
|
77
78
|
const containerName = containerNameFor(workspaceId);
|
|
@@ -91,9 +92,9 @@ var remove_default = defineMetabaseCommand({
|
|
|
91
92
|
removed_container: removedContainer,
|
|
92
93
|
removed_volume: removedVolume
|
|
93
94
|
};
|
|
94
|
-
renderItem(result,
|
|
95
|
+
renderItem(result, deleteResultView, ctx);
|
|
95
96
|
}
|
|
96
97
|
});
|
|
97
98
|
|
|
98
99
|
//#endregion
|
|
99
|
-
export {
|
|
100
|
+
export { delete_default as default };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import "./
|
|
3
|
-
import "./
|
|
4
|
-
import "./
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import "./
|
|
8
|
-
import { DeleteResult, confirmAndDelete } from "./delete-runtime-
|
|
1
|
+
import "./command-augment-BH9qgQ5u.mjs";
|
|
2
|
+
import { connectionFlags, outputFlags, profileFlag } from "./error-C9S6PN3-.mjs";
|
|
3
|
+
import { defineMetabaseCommand } from "./runtime-Dmv5VtUK.mjs";
|
|
4
|
+
import "./capabilities-7e9MgquN.mjs";
|
|
5
|
+
import "./render-CfznwleY.mjs";
|
|
6
|
+
import "./prompt-CFKoys7k.mjs";
|
|
7
|
+
import { parseId } from "./parse-id-lk_K-CEF.mjs";
|
|
8
|
+
import { DeleteResult, confirmAndDelete } from "./delete-runtime-B6RQo_pw.mjs";
|
|
9
9
|
|
|
10
10
|
//#region src/commands/transform-job/delete.ts
|
|
11
11
|
var delete_default = defineMetabaseCommand({
|
|
@@ -13,6 +13,7 @@ var delete_default = defineMetabaseCommand({
|
|
|
13
13
|
name: "delete",
|
|
14
14
|
description: "Delete a transform job by id"
|
|
15
15
|
},
|
|
16
|
+
capabilities: { minVersion: 59 },
|
|
16
17
|
args: {
|
|
17
18
|
...outputFlags,
|
|
18
19
|
...profileFlag,
|