@xano/sdk 1.0.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/CHANGELOG.md +788 -0
- package/LICENSE +21 -0
- package/README.md +541 -0
- package/dist/.build-fingerprint +1 -0
- package/dist/agent-file-refresh-ZEMK33AX.js +38 -0
- package/dist/answer-shape-K67TAAPY.js +33 -0
- package/dist/backend-dir-2U53CIAL.js +39 -0
- package/dist/backend-slot-7QXW2QYC.js +28 -0
- package/dist/bin.d.ts +1 -0
- package/dist/bin.js +255 -0
- package/dist/branch-NCRNWQBQ.js +61 -0
- package/dist/branch-commands-ACIRCEQJ.js +79 -0
- package/dist/bundle.d.ts +223 -0
- package/dist/bundle.js +153 -0
- package/dist/capture-WAXPD7DR.js +41 -0
- package/dist/chunk-27GWNP2I.js +23 -0
- package/dist/chunk-2CMJZDCL.js +177 -0
- package/dist/chunk-2EZ3ZJZZ.js +302 -0
- package/dist/chunk-2GNFDZA2.js +390 -0
- package/dist/chunk-2MNLRIOX.js +11 -0
- package/dist/chunk-2TFRR6JV.js +104 -0
- package/dist/chunk-2ZUEE4EK.js +408 -0
- package/dist/chunk-36JUQZVQ.js +22 -0
- package/dist/chunk-3DRXWLJ5.js +83 -0
- package/dist/chunk-3JDU4VRL.js +137 -0
- package/dist/chunk-3KZCLN4Z.js +241 -0
- package/dist/chunk-3LDULPRE.js +168 -0
- package/dist/chunk-3M4LFYNQ.js +111 -0
- package/dist/chunk-3XI5CTUE.js +22 -0
- package/dist/chunk-3YW23UFH.js +50 -0
- package/dist/chunk-45UIT5T2.js +862 -0
- package/dist/chunk-4BW2SG2N.js +46 -0
- package/dist/chunk-4KHEMC32.js +79 -0
- package/dist/chunk-4POWHT2K.js +321 -0
- package/dist/chunk-4Q2GN7NW.js +192 -0
- package/dist/chunk-5A2PLKZB.js +70 -0
- package/dist/chunk-5FBYXK5P.js +159 -0
- package/dist/chunk-5HVXPTU4.js +323 -0
- package/dist/chunk-5QU2P5CA.js +304 -0
- package/dist/chunk-5V5XU32D.js +191 -0
- package/dist/chunk-5ZSO4T2G.js +10 -0
- package/dist/chunk-622HUCZT.js +10 -0
- package/dist/chunk-65HWOMGV.js +177 -0
- package/dist/chunk-6ELFRN3P.js +365 -0
- package/dist/chunk-6HO3NCSJ.js +1055 -0
- package/dist/chunk-6IUMKYWI.js +457 -0
- package/dist/chunk-6KEB3C3U.js +65 -0
- package/dist/chunk-6MR5TI5V.js +987 -0
- package/dist/chunk-6NNTNXN7.js +157 -0
- package/dist/chunk-6PBR37LN.js +97 -0
- package/dist/chunk-6QXLMMT3.js +155 -0
- package/dist/chunk-6ZGJCBZS.js +224 -0
- package/dist/chunk-73IVBKMA.js +250 -0
- package/dist/chunk-7G3CTU7I.js +286 -0
- package/dist/chunk-A3UDOZB6.js +222 -0
- package/dist/chunk-A6E77GDW.js +85 -0
- package/dist/chunk-AHJWCYQO.js +660 -0
- package/dist/chunk-AKNCFVKZ.js +36 -0
- package/dist/chunk-AM4FKL4J.js +237 -0
- package/dist/chunk-AN6BL47T.js +26 -0
- package/dist/chunk-AOSYVMUS.js +147 -0
- package/dist/chunk-APWXY5SL.js +182 -0
- package/dist/chunk-AWEIIR2U.js +218 -0
- package/dist/chunk-AWQ7BQTQ.js +73 -0
- package/dist/chunk-BAUZOWGX.js +393 -0
- package/dist/chunk-BHACRS6R.js +940 -0
- package/dist/chunk-BWPNT55T.js +680 -0
- package/dist/chunk-C6RIMRU4.js +187 -0
- package/dist/chunk-CGVQZXYG.js +263 -0
- package/dist/chunk-CIMQZRRE.js +162 -0
- package/dist/chunk-CJHQKJU4.js +113 -0
- package/dist/chunk-CTMO46PK.js +1897 -0
- package/dist/chunk-D53J55C5.js +106 -0
- package/dist/chunk-D7VGG3WS.js +90 -0
- package/dist/chunk-DAD3ONIS.js +245 -0
- package/dist/chunk-DGWHAVRG.js +162 -0
- package/dist/chunk-DX4QR4B2.js +483 -0
- package/dist/chunk-EHP3WPEG.js +21 -0
- package/dist/chunk-ELP2HMXC.js +432 -0
- package/dist/chunk-ERVIASGL.js +21 -0
- package/dist/chunk-ET4Y4XCB.js +865 -0
- package/dist/chunk-ETO6LGLD.js +4750 -0
- package/dist/chunk-EUUUMY7J.js +24 -0
- package/dist/chunk-FQJ2TTHP.js +218 -0
- package/dist/chunk-FQOF7E2E.js +133 -0
- package/dist/chunk-FWD7AL6N.js +21 -0
- package/dist/chunk-FXFV3KU6.js +138 -0
- package/dist/chunk-FXRQOWTE.js +171 -0
- package/dist/chunk-G554NZNI.js +210 -0
- package/dist/chunk-GSGDWJB5.js +13 -0
- package/dist/chunk-H2V3N23D.js +66 -0
- package/dist/chunk-H5C7MBCR.js +159 -0
- package/dist/chunk-HHN734BU.js +371 -0
- package/dist/chunk-HRVBLCVJ.js +243 -0
- package/dist/chunk-HVRUQXGD.js +1264 -0
- package/dist/chunk-I4F5TCJH.js +130 -0
- package/dist/chunk-IDOTCMDV.js +57 -0
- package/dist/chunk-IGOLHKWF.js +427 -0
- package/dist/chunk-JGE7CAWB.js +148 -0
- package/dist/chunk-JTUKLCXS.js +92 -0
- package/dist/chunk-JZGVVJSI.js +66 -0
- package/dist/chunk-K4WX6UUU.js +923 -0
- package/dist/chunk-K5BBGTYZ.js +217 -0
- package/dist/chunk-K6RXBGUB.js +427 -0
- package/dist/chunk-KTSDSD36.js +165 -0
- package/dist/chunk-L5JYN3NM.js +1038 -0
- package/dist/chunk-LIEOKXKD.js +354 -0
- package/dist/chunk-LLNZGEFK.js +51 -0
- package/dist/chunk-LPECSJ2J.js +55 -0
- package/dist/chunk-LQCMKAJ7.js +413 -0
- package/dist/chunk-LRN4ZJCQ.js +1145 -0
- package/dist/chunk-MJ4ZVHKN.js +17 -0
- package/dist/chunk-MXHSQOC4.js +3061 -0
- package/dist/chunk-N5GKCWE5.js +367 -0
- package/dist/chunk-NA3PXMEF.js +10 -0
- package/dist/chunk-NAQDMEHV.js +76 -0
- package/dist/chunk-NWKXM5RD.js +109 -0
- package/dist/chunk-NZOWWHU5.js +196 -0
- package/dist/chunk-OHX6MIUZ.js +184 -0
- package/dist/chunk-OOXWYAA4.js +15 -0
- package/dist/chunk-OPHB5ORL.js +1990 -0
- package/dist/chunk-OXA6PSZT.js +1725 -0
- package/dist/chunk-P2HAGF6H.js +73 -0
- package/dist/chunk-PTHVMXZI.js +3036 -0
- package/dist/chunk-PZ5AY32C.js +10 -0
- package/dist/chunk-Q325JKYB.js +189 -0
- package/dist/chunk-Q7DGTQ5G.js +255 -0
- package/dist/chunk-QCNYHBL7.js +601 -0
- package/dist/chunk-QO6BVGS5.js +145 -0
- package/dist/chunk-QXTKSOFI.js +76 -0
- package/dist/chunk-ROY4YAEQ.js +66 -0
- package/dist/chunk-RTJRZFFY.js +447 -0
- package/dist/chunk-SAVJUS2X.js +128 -0
- package/dist/chunk-SFLHVCKX.js +173 -0
- package/dist/chunk-STSFNCY4.js +127 -0
- package/dist/chunk-SWBF2LTK.js +170 -0
- package/dist/chunk-T5KELPAR.js +109 -0
- package/dist/chunk-TFFGOFVZ.js +1481 -0
- package/dist/chunk-TLHIFK4M.js +256 -0
- package/dist/chunk-TLQE7ZN3.js +156 -0
- package/dist/chunk-TPHWJ7UG.js +1981 -0
- package/dist/chunk-TRJCALW3.js +291 -0
- package/dist/chunk-TTEIYD5P.js +133 -0
- package/dist/chunk-U64O2MXY.js +407 -0
- package/dist/chunk-UCQ2VUTG.js +630 -0
- package/dist/chunk-UTI5G6OJ.js +44 -0
- package/dist/chunk-UVHDMMIP.js +188 -0
- package/dist/chunk-UZ6QQWJT.js +120 -0
- package/dist/chunk-VAX3UZOY.js +686 -0
- package/dist/chunk-W3HBUKFO.js +57 -0
- package/dist/chunk-WKQLGKCL.js +2823 -0
- package/dist/chunk-WQFNASK4.js +560 -0
- package/dist/chunk-WRBKLYSJ.js +224 -0
- package/dist/chunk-WTPZRR4I.js +17 -0
- package/dist/chunk-WZDJ2LLX.js +2385 -0
- package/dist/chunk-X2NL4KUO.js +14 -0
- package/dist/chunk-X4DVXBFY.js +38 -0
- package/dist/chunk-X677DMZM.js +7050 -0
- package/dist/chunk-XBKMWY7F.js +612 -0
- package/dist/chunk-XNCP4KYO.js +78 -0
- package/dist/chunk-XVBGLISP.js +35 -0
- package/dist/chunk-XW6KISBB.js +1192 -0
- package/dist/chunk-YGZHHAAB.js +8156 -0
- package/dist/chunk-YHEFQUQB.js +186 -0
- package/dist/chunk-YLDALTWZ.js +653 -0
- package/dist/chunk-YU4HSQW7.js +229 -0
- package/dist/chunk-ZDPP6RKB.js +27 -0
- package/dist/chunk-ZFDZKNGG.js +194 -0
- package/dist/chunk-ZIY7RNUT.js +49 -0
- package/dist/chunk-ZYJP6BOO.js +30 -0
- package/dist/cli.d.ts +1111 -0
- package/dist/cli.js +165 -0
- package/dist/codegen-command-VR2GWR6C.js +173 -0
- package/dist/codegen.d.ts +115 -0
- package/dist/codegen.js +19 -0
- package/dist/commands-GJMJ4XYZ.js +76 -0
- package/dist/completion-ZQLO6PB6.js +738 -0
- package/dist/config-MBYGCAFK.js +136 -0
- package/dist/deploy-command-JVZPWHMK.js +180 -0
- package/dist/deploy-source-3W45CXMP.js +81 -0
- package/dist/dev-env-sync-HN44K4D5.js +188 -0
- package/dist/diagnostics-UEAAHWVF.js +30 -0
- package/dist/display-name-hint-ABBPVQIR.js +46 -0
- package/dist/emit-CyhBDxli.d.ts +7007 -0
- package/dist/env-example-refresh-ET5HMMDW.js +126 -0
- package/dist/env-pull-command-TNMNB3CV.js +323 -0
- package/dist/env-target-O4HRKTGZ.js +40 -0
- package/dist/env-var-command-ZIRDCAZA.js +427 -0
- package/dist/ephemeral-P7F3PMAD.js +54 -0
- package/dist/ephemeral-command-CLJJKOFT.js +592 -0
- package/dist/ephemeral-state-PYCBSOGX.js +61 -0
- package/dist/file-lock-PT74GWYW.js +10 -0
- package/dist/generate-command-AYEOLA26.js +510 -0
- package/dist/gitignore-3SJ3WNRG.js +51 -0
- package/dist/guards-4EBNCZDC.js +162 -0
- package/dist/hosted-file-PSHJB3HX.js +28 -0
- package/dist/impersonate-command-5JAS3WSV.js +152 -0
- package/dist/import-EQSFU6JC.js +19 -0
- package/dist/index.d.ts +5470 -0
- package/dist/index.js +371 -0
- package/dist/init-command-X2FR4UAK.js +125 -0
- package/dist/init-modules-RY7UHAOL.js +50 -0
- package/dist/init-web-M4YZSZK6.js +42 -0
- package/dist/internal.d.ts +179 -0
- package/dist/internal.js +2634 -0
- package/dist/io-RC56QSN5.js +26 -0
- package/dist/keep-data-merge-7MPLVAVI.js +1119 -0
- package/dist/lambda-config-reconcile-OUZ4OYAB.js +116 -0
- package/dist/landed-753YLJ5H.js +40 -0
- package/dist/landing-record-SU52SKXU.js +61 -0
- package/dist/live-diff-YONW2VI3.js +65 -0
- package/dist/local-engine-choice-CH5X3W7E.js +79 -0
- package/dist/local-engine-command-Z3OL7VOD.js +766 -0
- package/dist/local-engine-config-5U3SC434.js +39 -0
- package/dist/local-engine-deploy-PCQ4SNPB.js +39 -0
- package/dist/local-engine-process-EHTE5LLU.js +63 -0
- package/dist/local-engine-state-A4FTRFAF.js +32 -0
- package/dist/local-engine-update-check-6L645VBL.js +162 -0
- package/dist/lock-MRRHW5GS.js +87 -0
- package/dist/lock-commands-2QG25HL7.js +963 -0
- package/dist/login-command-QPYRWOXZ.js +538 -0
- package/dist/logout-command-WOIQLDP6.js +56 -0
- package/dist/loop-ALIZLOSX.js +191 -0
- package/dist/marketplace-command-K5YL42NO.js +977 -0
- package/dist/marketplace-resolve-LY32JES5.js +40 -0
- package/dist/meta-client-YXGPW53C.js +244 -0
- package/dist/module-manifest-JFGHU2TC.js +38 -0
- package/dist/near-key.d.ts +13 -0
- package/dist/near-key.js +8 -0
- package/dist/node.d.ts +95 -0
- package/dist/node.js +969 -0
- package/dist/operation-outcome-TZSESNC7.js +51 -0
- package/dist/output-target-AL3I44GG.js +47 -0
- package/dist/package-manager-PRAHUSCN.js +34 -0
- package/dist/plan-disclosure-6G4MLZKD.js +114 -0
- package/dist/plugin-contributions-WRNY5ABG.js +28 -0
- package/dist/plugin-prompt-4VA3B4FF.js +20 -0
- package/dist/plugin-questions-JTSYA74Q.js +24 -0
- package/dist/plugin.d.ts +396 -0
- package/dist/plugin.js +1 -0
- package/dist/preflight-command-2T5Z36MI.js +321 -0
- package/dist/profile-command-AH3PIM4X.js +800 -0
- package/dist/profile-pointer-GRWJU3YD.js +31 -0
- package/dist/profile-select-74TRDEPD.js +23 -0
- package/dist/project-dependency-KSH63ODT.js +35 -0
- package/dist/project-sdk-REPPOIBD.js +24 -0
- package/dist/promote-command-PCWT5N6S.js +140 -0
- package/dist/prompt-II3F3LND.js +27 -0
- package/dist/publish-command-TTDUUJI5.js +414 -0
- package/dist/pull-command-VBO7C4S3.js +161 -0
- package/dist/pull-superseded-GJWLG7XO.js +20 -0
- package/dist/release-command-N4ZPKMHR.js +146 -0
- package/dist/release-ns-command-3KFDMZ6G.js +1745 -0
- package/dist/response-HlXahv4K.d.ts +925 -0
- package/dist/retry-command-AS5EVREX.js +34 -0
- package/dist/routes-manifest-SNWUVBT6.js +43 -0
- package/dist/runtime-XETHVF33.js +14 -0
- package/dist/scaffold.d.ts +1911 -0
- package/dist/scaffold.js +107 -0
- package/dist/secrets-file-LVZD6IIM.js +56 -0
- package/dist/secrets-fill-command-TTCPSVXN.js +218 -0
- package/dist/seed-VU7C3QYS.js +46 -0
- package/dist/sent-writes-N7X4OVXT.js +22 -0
- package/dist/source-resolve-S2XA3XZF.js +83 -0
- package/dist/static-host-B2Y6AG3W.js +352 -0
- package/dist/status-command-RUDXTF7I.js +554 -0
- package/dist/store-6VNCD4D7.js +20 -0
- package/dist/store-ARM6VMO5.js +98 -0
- package/dist/store-DuYfzKlW.d.ts +3144 -0
- package/dist/suggest-6FOOYKHG.js +12 -0
- package/dist/sveltekit.d.ts +154 -0
- package/dist/sveltekit.js +109 -0
- package/dist/sync-contributions-UCEROO26.js +415 -0
- package/dist/table-ENAVMITR.js +42 -0
- package/dist/tables-command-GUPXXSB5.js +156 -0
- package/dist/tenant-IIHPOHGP.js +42 -0
- package/dist/tenant-command-D5HGI2X4.js +965 -0
- package/dist/test-command-TIKZMDPZ.js +476 -0
- package/dist/tests-BGGIOK3L.js +26 -0
- package/dist/token-NICJUTMT.js +72 -0
- package/dist/toolchain-hooks-GHKLUJOH.js +96 -0
- package/dist/toolchain-modules-5EAZUONB.js +24 -0
- package/dist/tracked-backend-EIBUMDZA.js +80 -0
- package/dist/update-check-2W2NLDTC.js +136 -0
- package/dist/upgrade-command-QHNFWM7O.js +531 -0
- package/dist/verify-rollout-DRCK5TDD.js +61 -0
- package/dist/whoami-command-STGINTXH.js +51 -0
- package/dist/workspace-2CLHU2LK.js +93 -0
- package/dist/workspace-binding-56PIIPCP.js +54 -0
- package/dist/workspace-command-JEXQETJD.js +535 -0
- package/dist/workspace-env-F2RFMSC5.js +70 -0
- package/dist/workspace-export-OJSH2HIW.js +21 -0
- package/dist/writable-VA7OISSK.js +25 -0
- package/dist/xano-ICFUSPFR.js +42 -0
- package/dist/xanosdk-import-GN42TO2B.js +56 -0
- package/dist/xanosdk-project-S6DXJONQ.js +41 -0
- package/dist/xdo-CxDr2Q1C.d.ts +1371 -0
- package/guides/README.md +33 -0
- package/guides/authoring.md +921 -0
- package/guides/cli.md +401 -0
- package/guides/codegen.md +177 -0
- package/guides/codes.md +404 -0
- package/guides/coverage.md +74 -0
- package/guides/deploying.md +1525 -0
- package/guides/environment.md +400 -0
- package/guides/marketplace.md +415 -0
- package/guides/module-contract.md +558 -0
- package/guides/object-kinds.md +433 -0
- package/guides/project-structure.md +43 -0
- package/guides/scaffold.md +351 -0
- package/guides/typed-frontend.md +242 -0
- package/llms/client.md +63 -0
- package/llms/errors.md +56 -0
- package/llms/fields.md +176 -0
- package/llms/filters.md +183 -0
- package/llms/kinds-agent-mcp.md +30 -0
- package/llms/kinds-core.md +100 -0
- package/llms/kinds-knowledge.md +20 -0
- package/llms/kinds-realtime.md +76 -0
- package/llms/lambda.md +94 -0
- package/llms/legacy.md +44 -0
- package/llms/lock.md +40 -0
- package/llms/object-kinds.md +34 -0
- package/llms/statements-calls.md +62 -0
- package/llms/statements-catalog.md +320 -0
- package/llms/statements-data.md +66 -0
- package/llms/statements-runtime.md +68 -0
- package/llms/tests.md +59 -0
- package/llms/toolchain.md +16 -0
- package/llms/triggers.md +36 -0
- package/llms/values.md +29 -0
- package/llms-full.txt +2085 -0
- package/llms.txt +493 -0
- package/manifest.json +11224 -0
- package/package.json +162 -0
- package/types/lambda-globals.d.ts +129 -0
|
@@ -0,0 +1,510 @@
|
|
|
1
|
+
import {
|
|
2
|
+
pulledIdentities,
|
|
3
|
+
pulledLock,
|
|
4
|
+
reconcileLock
|
|
5
|
+
} from "./chunk-K4WX6UUU.js";
|
|
6
|
+
import "./chunk-D53J55C5.js";
|
|
7
|
+
import "./chunk-5HVXPTU4.js";
|
|
8
|
+
import "./chunk-W3HBUKFO.js";
|
|
9
|
+
import {
|
|
10
|
+
carriedSeedRows,
|
|
11
|
+
decodeBundle,
|
|
12
|
+
fetchWorkspaceBundle,
|
|
13
|
+
placeGeneratedFiles,
|
|
14
|
+
readBundleFile,
|
|
15
|
+
refuseDuplicateSourceGuids,
|
|
16
|
+
reportSeedRows,
|
|
17
|
+
writeBundleEnvValues,
|
|
18
|
+
writeDocumentationTokens
|
|
19
|
+
} from "./chunk-X677DMZM.js";
|
|
20
|
+
import "./chunk-LRN4ZJCQ.js";
|
|
21
|
+
import {
|
|
22
|
+
ROUTES_MANIFEST_BASENAME
|
|
23
|
+
} from "./chunk-RTJRZFFY.js";
|
|
24
|
+
import {
|
|
25
|
+
confirm
|
|
26
|
+
} from "./chunk-65HWOMGV.js";
|
|
27
|
+
import "./chunk-TPHWJ7UG.js";
|
|
28
|
+
import {
|
|
29
|
+
fetchSourceArchive
|
|
30
|
+
} from "./chunk-AOSYVMUS.js";
|
|
31
|
+
import "./chunk-CJHQKJU4.js";
|
|
32
|
+
import {
|
|
33
|
+
decodeWorkspaceArchive
|
|
34
|
+
} from "./chunk-3DRXWLJ5.js";
|
|
35
|
+
import "./chunk-X4DVXBFY.js";
|
|
36
|
+
import "./chunk-TRJCALW3.js";
|
|
37
|
+
import "./chunk-LIEOKXKD.js";
|
|
38
|
+
import "./chunk-D7VGG3WS.js";
|
|
39
|
+
import "./chunk-2TFRR6JV.js";
|
|
40
|
+
import "./chunk-HRVBLCVJ.js";
|
|
41
|
+
import {
|
|
42
|
+
ensureSecretPathGitignored
|
|
43
|
+
} from "./chunk-YHEFQUQB.js";
|
|
44
|
+
import {
|
|
45
|
+
readVersion
|
|
46
|
+
} from "./chunk-ETO6LGLD.js";
|
|
47
|
+
import "./chunk-ZIY7RNUT.js";
|
|
48
|
+
import {
|
|
49
|
+
WORKSPACE_ENV_BASENAME
|
|
50
|
+
} from "./chunk-DAD3ONIS.js";
|
|
51
|
+
import {
|
|
52
|
+
memoCredential,
|
|
53
|
+
refuseProfileForLocal
|
|
54
|
+
} from "./chunk-HHN734BU.js";
|
|
55
|
+
import "./chunk-LPECSJ2J.js";
|
|
56
|
+
import "./chunk-6NNTNXN7.js";
|
|
57
|
+
import "./chunk-QCNYHBL7.js";
|
|
58
|
+
import "./chunk-2ZUEE4EK.js";
|
|
59
|
+
import "./chunk-AN6BL47T.js";
|
|
60
|
+
import {
|
|
61
|
+
getAccessToken
|
|
62
|
+
} from "./chunk-ET4Y4XCB.js";
|
|
63
|
+
import "./chunk-SWBF2LTK.js";
|
|
64
|
+
import "./chunk-UZ6QQWJT.js";
|
|
65
|
+
import "./chunk-A3UDOZB6.js";
|
|
66
|
+
import "./chunk-2MNLRIOX.js";
|
|
67
|
+
import "./chunk-3M4LFYNQ.js";
|
|
68
|
+
import "./chunk-AM4FKL4J.js";
|
|
69
|
+
import "./chunk-Q325JKYB.js";
|
|
70
|
+
import {
|
|
71
|
+
parseSlot,
|
|
72
|
+
requireBackendSlot,
|
|
73
|
+
slotValueMissing
|
|
74
|
+
} from "./chunk-STSFNCY4.js";
|
|
75
|
+
import "./chunk-I4F5TCJH.js";
|
|
76
|
+
import "./chunk-5QU2P5CA.js";
|
|
77
|
+
import "./chunk-ZYJP6BOO.js";
|
|
78
|
+
import "./chunk-QO6BVGS5.js";
|
|
79
|
+
import "./chunk-JZGVVJSI.js";
|
|
80
|
+
import "./chunk-7G3CTU7I.js";
|
|
81
|
+
import "./chunk-6PBR37LN.js";
|
|
82
|
+
import {
|
|
83
|
+
yesRerun
|
|
84
|
+
} from "./chunk-T5KELPAR.js";
|
|
85
|
+
import "./chunk-622HUCZT.js";
|
|
86
|
+
import {
|
|
87
|
+
contextFlags
|
|
88
|
+
} from "./chunk-NAQDMEHV.js";
|
|
89
|
+
import "./chunk-5A2PLKZB.js";
|
|
90
|
+
import {
|
|
91
|
+
PRESERVED_ON_REFRESH,
|
|
92
|
+
containedWrites,
|
|
93
|
+
describeDecodeReplace,
|
|
94
|
+
filesUnder,
|
|
95
|
+
planDecodeReplace,
|
|
96
|
+
readDecodeRecord,
|
|
97
|
+
removeEmptiedDirs,
|
|
98
|
+
removeFiles
|
|
99
|
+
} from "./chunk-AHJWCYQO.js";
|
|
100
|
+
import "./chunk-DX4QR4B2.js";
|
|
101
|
+
import "./chunk-6QXLMMT3.js";
|
|
102
|
+
import "./chunk-ZFDZKNGG.js";
|
|
103
|
+
import {
|
|
104
|
+
shellWord
|
|
105
|
+
} from "./chunk-FWD7AL6N.js";
|
|
106
|
+
import "./chunk-2GNFDZA2.js";
|
|
107
|
+
import "./chunk-JTUKLCXS.js";
|
|
108
|
+
import "./chunk-4KHEMC32.js";
|
|
109
|
+
import "./chunk-U64O2MXY.js";
|
|
110
|
+
import {
|
|
111
|
+
projectRootFrom
|
|
112
|
+
} from "./chunk-ROY4YAEQ.js";
|
|
113
|
+
import {
|
|
114
|
+
readLockFile,
|
|
115
|
+
writeLockFile
|
|
116
|
+
} from "./chunk-P2HAGF6H.js";
|
|
117
|
+
import "./chunk-TLQE7ZN3.js";
|
|
118
|
+
import "./chunk-WRBKLYSJ.js";
|
|
119
|
+
import "./chunk-3LDULPRE.js";
|
|
120
|
+
import "./chunk-XW6KISBB.js";
|
|
121
|
+
import "./chunk-AWQ7BQTQ.js";
|
|
122
|
+
import "./chunk-EUUUMY7J.js";
|
|
123
|
+
import "./chunk-YLDALTWZ.js";
|
|
124
|
+
import "./chunk-5FBYXK5P.js";
|
|
125
|
+
import "./chunk-LLNZGEFK.js";
|
|
126
|
+
import "./chunk-QXTKSOFI.js";
|
|
127
|
+
import "./chunk-X2NL4KUO.js";
|
|
128
|
+
import "./chunk-3KZCLN4Z.js";
|
|
129
|
+
import "./chunk-FXFV3KU6.js";
|
|
130
|
+
import "./chunk-OPHB5ORL.js";
|
|
131
|
+
import {
|
|
132
|
+
decodeMarkerHead,
|
|
133
|
+
decodeMarkerWith
|
|
134
|
+
} from "./chunk-UCQ2VUTG.js";
|
|
135
|
+
import "./chunk-DGWHAVRG.js";
|
|
136
|
+
import "./chunk-27GWNP2I.js";
|
|
137
|
+
import "./chunk-3YW23UFH.js";
|
|
138
|
+
import "./chunk-JGE7CAWB.js";
|
|
139
|
+
import {
|
|
140
|
+
LocalFileNotFoundError,
|
|
141
|
+
UsageError,
|
|
142
|
+
detail,
|
|
143
|
+
info,
|
|
144
|
+
isMachineOutput,
|
|
145
|
+
relForwardSlash,
|
|
146
|
+
step,
|
|
147
|
+
success,
|
|
148
|
+
terminalText,
|
|
149
|
+
warn,
|
|
150
|
+
writeJson
|
|
151
|
+
} from "./chunk-PTHVMXZI.js";
|
|
152
|
+
import "./chunk-MXHSQOC4.js";
|
|
153
|
+
import "./chunk-6IUMKYWI.js";
|
|
154
|
+
import "./chunk-2CMJZDCL.js";
|
|
155
|
+
import "./chunk-CTMO46PK.js";
|
|
156
|
+
import "./chunk-ZDPP6RKB.js";
|
|
157
|
+
import "./chunk-K5BBGTYZ.js";
|
|
158
|
+
import "./chunk-LQCMKAJ7.js";
|
|
159
|
+
import "./chunk-YGZHHAAB.js";
|
|
160
|
+
import "./chunk-XVBGLISP.js";
|
|
161
|
+
import "./chunk-6HO3NCSJ.js";
|
|
162
|
+
import "./chunk-5V5XU32D.js";
|
|
163
|
+
import {
|
|
164
|
+
safeNames
|
|
165
|
+
} from "./chunk-GSGDWJB5.js";
|
|
166
|
+
import "./chunk-HVRUQXGD.js";
|
|
167
|
+
import "./chunk-ERVIASGL.js";
|
|
168
|
+
import "./chunk-4POWHT2K.js";
|
|
169
|
+
import "./chunk-H2V3N23D.js";
|
|
170
|
+
import {
|
|
171
|
+
WORKSPACE_SECRETS_BASENAME
|
|
172
|
+
} from "./chunk-3JDU4VRL.js";
|
|
173
|
+
import "./chunk-WTPZRR4I.js";
|
|
174
|
+
import "./chunk-UTI5G6OJ.js";
|
|
175
|
+
import "./chunk-2EZ3ZJZZ.js";
|
|
176
|
+
import "./chunk-6MR5TI5V.js";
|
|
177
|
+
import "./chunk-5ZSO4T2G.js";
|
|
178
|
+
import "./chunk-XNCP4KYO.js";
|
|
179
|
+
import "./chunk-AKNCFVKZ.js";
|
|
180
|
+
import "./chunk-YU4HSQW7.js";
|
|
181
|
+
import "./chunk-TFFGOFVZ.js";
|
|
182
|
+
import "./chunk-EHP3WPEG.js";
|
|
183
|
+
import "./chunk-L5JYN3NM.js";
|
|
184
|
+
import "./chunk-Q7DGTQ5G.js";
|
|
185
|
+
import "./chunk-G554NZNI.js";
|
|
186
|
+
import "./chunk-N5GKCWE5.js";
|
|
187
|
+
import "./chunk-OXA6PSZT.js";
|
|
188
|
+
import "./chunk-VAX3UZOY.js";
|
|
189
|
+
import "./chunk-NZOWWHU5.js";
|
|
190
|
+
import "./chunk-4BW2SG2N.js";
|
|
191
|
+
import "./chunk-TTEIYD5P.js";
|
|
192
|
+
import "./chunk-CIMQZRRE.js";
|
|
193
|
+
import "./chunk-OHX6MIUZ.js";
|
|
194
|
+
import "./chunk-36JUQZVQ.js";
|
|
195
|
+
import "./chunk-PZ5AY32C.js";
|
|
196
|
+
|
|
197
|
+
// src/emit/generate-command.ts
|
|
198
|
+
import { existsSync, mkdirSync, readFileSync, statSync, writeFileSync } from "fs";
|
|
199
|
+
import { basename, dirname, isAbsolute, join, resolve, sep } from "path";
|
|
200
|
+
var HINT = { hintFor: { command: "generate" } };
|
|
201
|
+
var PRESERVED = /* @__PURE__ */ new Set([...PRESERVED_ON_REFRESH, ".gitignore"]);
|
|
202
|
+
var DEFAULT_OUT = "xano";
|
|
203
|
+
var CODEGEN_MARKER = ".xanosdk-codegen.json";
|
|
204
|
+
function previousMarker(root) {
|
|
205
|
+
try {
|
|
206
|
+
const parsed = JSON.parse(readFileSync(join(root, CODEGEN_MARKER), "utf8"));
|
|
207
|
+
if (parsed !== null && typeof parsed === "object" && !Array.isArray(parsed)) return parsed;
|
|
208
|
+
} catch {
|
|
209
|
+
}
|
|
210
|
+
return {};
|
|
211
|
+
}
|
|
212
|
+
async function loadSource(args, raw, cwd) {
|
|
213
|
+
const slot = requireBackendSlot("generate", void 0, "subject");
|
|
214
|
+
const source = parseSlot(slot, raw);
|
|
215
|
+
if (source.kind === "file") {
|
|
216
|
+
if (args.branch !== void 0) {
|
|
217
|
+
throw new UsageError(
|
|
218
|
+
"`--branch` does not apply to a bundle file: it is one archive already exported from one branch. Re-export it with `xanosdk workspace export --branch <label>`, or generate from `workspace --branch <label>`.",
|
|
219
|
+
HINT
|
|
220
|
+
);
|
|
221
|
+
}
|
|
222
|
+
step(`Reading ${raw}`);
|
|
223
|
+
return { bundle: readBundleFile(source.path), label: raw, kind: "file" };
|
|
224
|
+
}
|
|
225
|
+
refuseProfileForLocal(args.profile, [source.kind], slot);
|
|
226
|
+
const credential = memoCredential(() => getAccessToken(args));
|
|
227
|
+
if (source.kind === "workspace" && args.branch !== void 0) {
|
|
228
|
+
return {
|
|
229
|
+
bundle: await fetchWorkspaceBundle(await credential(), args.branch),
|
|
230
|
+
label: `workspace branch "${args.branch}"`,
|
|
231
|
+
kind: "workspace",
|
|
232
|
+
backend: { selector: "workspace", workspaceId: (await credential()).workspaceId }
|
|
233
|
+
};
|
|
234
|
+
}
|
|
235
|
+
if (args.branch !== void 0) {
|
|
236
|
+
throw new UsageError(
|
|
237
|
+
`\`--branch\` applies to \`workspace\` only. "${raw}" carries the logic it was built from, not a branch to choose between.`,
|
|
238
|
+
HINT
|
|
239
|
+
);
|
|
240
|
+
}
|
|
241
|
+
step(`Reading ${raw}`);
|
|
242
|
+
const { projectDirFrom } = await import("./xanosdk-project-S6DXJONQ.js");
|
|
243
|
+
const fetched = await fetchSourceArchive(credential, raw, projectDirFrom(cwd) ?? cwd);
|
|
244
|
+
const bundle = decodeWorkspaceArchive(fetched.archive);
|
|
245
|
+
return {
|
|
246
|
+
bundle,
|
|
247
|
+
label: fetched.label,
|
|
248
|
+
kind: source.kind,
|
|
249
|
+
// The provenance is the selector of whatever backend was read; a release is not one.
|
|
250
|
+
backend: {
|
|
251
|
+
...source.kind === "release" ? {} : { selector: fetched.provenance },
|
|
252
|
+
...source.kind === "local-engine" ? {} : { workspaceId: (await credential()).workspaceId }
|
|
253
|
+
},
|
|
254
|
+
seed: {
|
|
255
|
+
rows: carriedSeedRows(fetched.archive, bundle.payload ?? {}),
|
|
256
|
+
provenance: fetched.provenance
|
|
257
|
+
}
|
|
258
|
+
};
|
|
259
|
+
}
|
|
260
|
+
function ignoreRootFor(root) {
|
|
261
|
+
const project = projectRootFrom(dirname(root));
|
|
262
|
+
const isProject = existsSync(join(project, "package.json")) || existsSync(join(project, ".git"));
|
|
263
|
+
return isProject ? project : root;
|
|
264
|
+
}
|
|
265
|
+
async function runGenerateCommand(args) {
|
|
266
|
+
const cwd = process.cwd();
|
|
267
|
+
const raw = args.positionals[0];
|
|
268
|
+
if (raw === void 0) {
|
|
269
|
+
throw slotValueMissing(requireBackendSlot("generate", void 0, "subject"));
|
|
270
|
+
}
|
|
271
|
+
if (args.out === "-") {
|
|
272
|
+
throw new UsageError("`generate` writes a tree of files, so `--out -` (stdout) has no meaning here \u2014 name a directory.", {
|
|
273
|
+
hintFor: { command: "generate" }
|
|
274
|
+
});
|
|
275
|
+
}
|
|
276
|
+
const typed = parseSlot(requireBackendSlot("generate", void 0, "subject"), raw);
|
|
277
|
+
if (typed.kind === "file" && !existsSync(resolve(cwd, typed.path))) {
|
|
278
|
+
throw new LocalFileNotFoundError(`No bundle file at "${resolve(cwd, typed.path)}".`);
|
|
279
|
+
}
|
|
280
|
+
const outArg = args.out ?? DEFAULT_OUT;
|
|
281
|
+
const root = resolve(cwd, outArg);
|
|
282
|
+
const shown = (isAbsolute(outArg) ? "" : relForwardSlash(cwd, root)) || root;
|
|
283
|
+
if (existsSync(root) && !statSync(root).isDirectory()) {
|
|
284
|
+
throw new UsageError(
|
|
285
|
+
`--out ${shown} is a file, not a directory. Nothing was written. Pick an empty or new directory with \`--out <dir>\`.`,
|
|
286
|
+
HINT
|
|
287
|
+
);
|
|
288
|
+
}
|
|
289
|
+
const existing = filesUnder(root);
|
|
290
|
+
const replaceable = existing.filter((p) => !PRESERVED.has(p));
|
|
291
|
+
if (replaceable.length > 0) {
|
|
292
|
+
const cwdWithin = cwd === root || cwd.startsWith(`${root}${sep}`);
|
|
293
|
+
if (cwdWithin || !existing.includes(CODEGEN_MARKER)) {
|
|
294
|
+
const why = cwdWithin ? `it is the working directory or above it, and generate never replaces the directory it runs in` + (existing.includes(CODEGEN_MARKER) ? "" : ` (and it holds no ${CODEGEN_MARKER})`) : `it is not a backend tree a decode wrote \u2014 no ${CODEGEN_MARKER}`;
|
|
295
|
+
throw new UsageError(
|
|
296
|
+
`${shown}/ is not empty and ${why}. Nothing was written. Pick an empty or new directory with \`--out <dir>\`${cwdWithin && existing.includes(CODEGEN_MARKER) ? `, or run from outside it` : ""}.`
|
|
297
|
+
);
|
|
298
|
+
}
|
|
299
|
+
if (args.force !== true) {
|
|
300
|
+
throw new UsageError(
|
|
301
|
+
`${shown}/ already holds a backend tree. Re-run with \`--force\` to replace it (${[...PRESERVED].join(", ")} are kept), or pick another directory with \`--out <dir>\`.`
|
|
302
|
+
);
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
const loaded = await loadSource(args, raw, cwd);
|
|
306
|
+
const project = decodeBundle(loaded.bundle, { secretsFile: `${shown}/${WORKSPACE_SECRETS_BASENAME}`, writesSecrets: args.noSecrets !== true });
|
|
307
|
+
refuseDuplicateSourceGuids(project);
|
|
308
|
+
const projectRelative = !isAbsolute(outArg) && !isAbsolute(shown) && shown !== ".." && !shown.startsWith("../");
|
|
309
|
+
const routesDeferred = [];
|
|
310
|
+
const decoded = placeGeneratedFiles(project, "", projectRelative ? shown : basename(root) || shown, {
|
|
311
|
+
entry: shellWord(`${shown}/index.ts`),
|
|
312
|
+
deferred: routesDeferred
|
|
313
|
+
}).map((f) => ({
|
|
314
|
+
path: f.path.replace(/^\//, ""),
|
|
315
|
+
content: f.content
|
|
316
|
+
}));
|
|
317
|
+
const markerHead = decodeMarkerHead(previousMarker(root), "generate", raw, readVersion(), project.report.toJson());
|
|
318
|
+
const markerFor = (wrote) => `${JSON.stringify(decodeMarkerWith(markerHead, wrote), null, 2)}
|
|
319
|
+
`;
|
|
320
|
+
const files = [...decoded, { path: CODEGEN_MARKER, content: markerFor(decoded) }];
|
|
321
|
+
const planned = containedWrites(
|
|
322
|
+
root,
|
|
323
|
+
files,
|
|
324
|
+
(path) => new UsageError(
|
|
325
|
+
`${loaded.label} carries a file that would be written outside ${shown}/ ("${path}"). Nothing was written.`
|
|
326
|
+
)
|
|
327
|
+
);
|
|
328
|
+
const lockPath = join(root, "xano.lock");
|
|
329
|
+
const lock = existsSync(lockPath) ? readLockFile(lockPath) : void 0;
|
|
330
|
+
const reconciliation = lock === void 0 ? void 0 : reconcileLock(lock, pulledIdentities(loaded.bundle.payload));
|
|
331
|
+
const incoming = new Map(decoded.map((f) => [f.path, f.content]));
|
|
332
|
+
const plan = planDecodeReplace(
|
|
333
|
+
root,
|
|
334
|
+
incoming,
|
|
335
|
+
replaceable.filter((p) => p !== CODEGEN_MARKER),
|
|
336
|
+
readDecodeRecord(root, [])
|
|
337
|
+
);
|
|
338
|
+
const removed = plan.removals;
|
|
339
|
+
const kept = plan.kept;
|
|
340
|
+
if (plan.removedEdited.length > 0 || plan.edited.length > 0) {
|
|
341
|
+
describeDecodeReplace(plan, shown, loaded.label, (line, files2) => warn(line, "generate.replace", files2));
|
|
342
|
+
if (args.yes !== true) {
|
|
343
|
+
const files2 = [...plan.removedEdited, ...plan.edited].map((p) => `${shown}/${p}`);
|
|
344
|
+
const { rerun, note } = yesRerun(args, "generate");
|
|
345
|
+
const ok = await confirm(`Replace ${shown}/ from ${loaded.label}, losing those edits?`, {
|
|
346
|
+
flag: "--yes",
|
|
347
|
+
refusal: { details: { written: false, files: files2 }, rerun, note }
|
|
348
|
+
});
|
|
349
|
+
if (!ok) {
|
|
350
|
+
info("Generate cancelled. Nothing was written.");
|
|
351
|
+
if (isMachineOutput(args)) {
|
|
352
|
+
writeJson({
|
|
353
|
+
source: raw,
|
|
354
|
+
out: root,
|
|
355
|
+
declined: true,
|
|
356
|
+
files: 0,
|
|
357
|
+
removed: [],
|
|
358
|
+
removedEdited: [],
|
|
359
|
+
rewrittenEdited: [],
|
|
360
|
+
kept: []
|
|
361
|
+
});
|
|
362
|
+
}
|
|
363
|
+
return;
|
|
364
|
+
}
|
|
365
|
+
}
|
|
366
|
+
}
|
|
367
|
+
removeFiles(root, removed);
|
|
368
|
+
removeEmptiedDirs(root, removed);
|
|
369
|
+
step(`Writing ${shown}/ from ${loaded.label}`);
|
|
370
|
+
const marker = planned.at(-1);
|
|
371
|
+
const write = (file) => {
|
|
372
|
+
mkdirSync(dirname(file.full), { recursive: true });
|
|
373
|
+
writeFileSync(file.full, file.content, "utf8");
|
|
374
|
+
};
|
|
375
|
+
const unwritten = (file, err) => `${shown}/${relForwardSlash(root, file.full)} could not be written (${err?.code ?? (err instanceof Error ? err.message : String(err))})`;
|
|
376
|
+
write(marker);
|
|
377
|
+
const routesFull = join(root, ROUTES_MANIFEST_BASENAME);
|
|
378
|
+
for (const file of planned.slice(0, -1)) {
|
|
379
|
+
try {
|
|
380
|
+
write(file);
|
|
381
|
+
} catch (err) {
|
|
382
|
+
if (file.full === routesFull) {
|
|
383
|
+
warn(`${unwritten(file, err)}. The tree is complete without it; fix the path and run \`xanosdk routes ${shown}/index.ts --emit ${shown}/${ROUTES_MANIFEST_BASENAME}\`.`, "routes.not-written");
|
|
384
|
+
write({ full: marker.full, content: markerFor(decoded.filter((f) => f.path !== ROUTES_MANIFEST_BASENAME)) });
|
|
385
|
+
continue;
|
|
386
|
+
}
|
|
387
|
+
throw new UsageError(
|
|
388
|
+
`${unwritten(file, err)}. The tree is partial; fix the path and re-run with \`--force\` to replace it.`
|
|
389
|
+
);
|
|
390
|
+
}
|
|
391
|
+
}
|
|
392
|
+
if (lock !== void 0 && reconciliation !== void 0) {
|
|
393
|
+
writeLockFile(lockPath, pulledLock(lock, reconciliation, loaded.bundle.payload));
|
|
394
|
+
}
|
|
395
|
+
const ignoreRoot = ignoreRootFor(root);
|
|
396
|
+
const placement = (basename2) => ({
|
|
397
|
+
root: ignoreRoot,
|
|
398
|
+
label: `${shown}/${basename2}`
|
|
399
|
+
});
|
|
400
|
+
ensureSecretPathGitignored(join(root, WORKSPACE_ENV_BASENAME), placement(WORKSPACE_ENV_BASENAME));
|
|
401
|
+
writeDocumentationTokens(
|
|
402
|
+
root,
|
|
403
|
+
project.documentationTokens,
|
|
404
|
+
args,
|
|
405
|
+
loaded.label,
|
|
406
|
+
join(root, WORKSPACE_SECRETS_BASENAME),
|
|
407
|
+
placement(WORKSPACE_SECRETS_BASENAME)
|
|
408
|
+
);
|
|
409
|
+
const env = writeBundleEnvValues(root, project.env, args, loaded.label, loaded.kind, {
|
|
410
|
+
dir: root,
|
|
411
|
+
rel: `${shown}/${WORKSPACE_ENV_BASENAME}`,
|
|
412
|
+
command: "generate",
|
|
413
|
+
place: placement(WORKSPACE_ENV_BASENAME)
|
|
414
|
+
});
|
|
415
|
+
const valueless = env.declared.filter((n) => project.env[n] === "" && !env.written.includes(n));
|
|
416
|
+
if (valueless.length > 0) {
|
|
417
|
+
warn(
|
|
418
|
+
`${valueless.length} env var${valueless.length === 1 ? "" : "s"} declared with no value in the bundle (${safeNames(valueless)}) \u2014 see ${shown}/.env.example. Supply ${valueless.length === 1 ? "it" : "them"} in ${shown}/${WORKSPACE_ENV_BASENAME} or with \`--env-var\` at deploy.`,
|
|
419
|
+
"workspace-env.valueless"
|
|
420
|
+
);
|
|
421
|
+
}
|
|
422
|
+
if (kept.length > 0) {
|
|
423
|
+
warn(
|
|
424
|
+
`Kept ${kept.length} file${kept.length === 1 ? "" : "s"} no decode wrote \u2014 ${kept.length === 1 ? "it is" : "they are"} yours, and ${kept.length === 1 ? "it is" : "they are"} not part of the decoded tree:`,
|
|
425
|
+
"pull.kept-files",
|
|
426
|
+
[...kept.slice(0, 20).map((p) => ` ${shown}/${p}`), ...kept.length > 20 ? [` \u2026 and ${kept.length - 20} more`] : []]
|
|
427
|
+
);
|
|
428
|
+
}
|
|
429
|
+
if (removed.length > 0) {
|
|
430
|
+
info(
|
|
431
|
+
`Removed ${removed.length} file${removed.length === 1 ? "" : "s"} the previous decode wrote and this one does not:`
|
|
432
|
+
);
|
|
433
|
+
for (const p of removed.slice(0, 20)) detail(` ${shown}/${p}`);
|
|
434
|
+
if (removed.length > 20) detail(` \u2026 and ${removed.length - 20} more`);
|
|
435
|
+
}
|
|
436
|
+
const routesNotes = () => {
|
|
437
|
+
if (routesDeferred.length === 0) return;
|
|
438
|
+
const bare = !existsSync(join(projectRootFrom(dirname(root)), "package.json"));
|
|
439
|
+
for (const line of routesDeferred) {
|
|
440
|
+
warn(
|
|
441
|
+
bare ? `${line} No package.json holds this tree, so that export cannot load \`@xano/sdk\` yet \u2014 run \`npm init -y && npm install @xano/sdk\` here first.` : line,
|
|
442
|
+
"routes.not-written"
|
|
443
|
+
);
|
|
444
|
+
}
|
|
445
|
+
};
|
|
446
|
+
const headline = project.report.headline();
|
|
447
|
+
const reportLine = () => {
|
|
448
|
+
if (headline === "") return;
|
|
449
|
+
const summary = project.report.summarize();
|
|
450
|
+
const line = `Decode report: ${headline} \u2014 listed in ${shown}/README.md.`;
|
|
451
|
+
if (summary.bySeverity.error + summary.bySeverity.warning > 0) warn(line, "decode.findings");
|
|
452
|
+
else info(line);
|
|
453
|
+
const notRecovered = project.report.renderCli({ categories: ["file-not-recovered"], fileBase: `${shown}/` });
|
|
454
|
+
if (notRecovered !== "") process.stderr.write(`${terminalText(notRecovered)}
|
|
455
|
+
`);
|
|
456
|
+
};
|
|
457
|
+
const seedNote = () => {
|
|
458
|
+
if (loaded.seed !== void 0) reportSeedRows(loaded.seed.rows, loaded.label, loaded.seed.provenance, shown, contextFlags(args));
|
|
459
|
+
};
|
|
460
|
+
if (isMachineOutput(args)) {
|
|
461
|
+
routesNotes();
|
|
462
|
+
reportLine();
|
|
463
|
+
seedNote();
|
|
464
|
+
const under = (p) => `${shown}/${p}`;
|
|
465
|
+
writeJson({
|
|
466
|
+
source: raw,
|
|
467
|
+
...loaded.backend,
|
|
468
|
+
out: root,
|
|
469
|
+
declined: false,
|
|
470
|
+
files: files.length,
|
|
471
|
+
removed: removed.map(under),
|
|
472
|
+
removedEdited: plan.removedEdited.map(under),
|
|
473
|
+
// The other half of "your edits were lost": files you edited that this
|
|
474
|
+
// decode REWROTE rather than removed. `--yes` answered for both.
|
|
475
|
+
rewrittenEdited: plan.edited.map(under),
|
|
476
|
+
kept: kept.map(under),
|
|
477
|
+
lockKept: reconciliation?.kept.length ?? 0,
|
|
478
|
+
lockDropped: reconciliation?.dropped.length ?? 0,
|
|
479
|
+
// Names only — a value never reaches stdout.
|
|
480
|
+
env: {
|
|
481
|
+
declared: env.declared,
|
|
482
|
+
written: env.written,
|
|
483
|
+
notWritten: [.../* @__PURE__ */ new Set([...env.notWritten, ...valueless])],
|
|
484
|
+
...env.reason !== void 0 ? { declined: env.reason } : {}
|
|
485
|
+
},
|
|
486
|
+
report: project.report.toJson(),
|
|
487
|
+
seedRows: loaded.seed?.rows ?? []
|
|
488
|
+
});
|
|
489
|
+
return;
|
|
490
|
+
}
|
|
491
|
+
success(`Generated ${shown}/ from ${loaded.label}`);
|
|
492
|
+
detail(`${files.length} files written${removed.length > 0 ? `, ${removed.length} removed` : ""}`);
|
|
493
|
+
routesNotes();
|
|
494
|
+
reportLine();
|
|
495
|
+
seedNote();
|
|
496
|
+
if (reconciliation !== void 0) {
|
|
497
|
+
detail(`lock: ${reconciliation.kept.length} kept, ${reconciliation.dropped.length} dropped`);
|
|
498
|
+
if (reconciliation.disjoint) {
|
|
499
|
+
warn(
|
|
500
|
+
`None of xano.lock's entries appear in ${loaded.label}, so this tree now points at a different backend. Its lock was emptied rather than carried across.`,
|
|
501
|
+
"lock.repointed"
|
|
502
|
+
);
|
|
503
|
+
}
|
|
504
|
+
}
|
|
505
|
+
}
|
|
506
|
+
export {
|
|
507
|
+
CODEGEN_MARKER,
|
|
508
|
+
runGenerateCommand
|
|
509
|
+
};
|
|
510
|
+
//# sourceMappingURL=generate-command-AYEOLA26.js.map
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import {
|
|
2
|
+
ensureExportGitignored,
|
|
3
|
+
ensureGitignoredOrWarn,
|
|
4
|
+
ensureSecretPathGitignored,
|
|
5
|
+
ensureWorkspaceEnvGitignored,
|
|
6
|
+
refuseIfTracked,
|
|
7
|
+
requireSecretPathGitignored,
|
|
8
|
+
secretPathLabel
|
|
9
|
+
} from "./chunk-YHEFQUQB.js";
|
|
10
|
+
import "./chunk-DAD3ONIS.js";
|
|
11
|
+
import "./chunk-5A2PLKZB.js";
|
|
12
|
+
import "./chunk-AHJWCYQO.js";
|
|
13
|
+
import "./chunk-DX4QR4B2.js";
|
|
14
|
+
import "./chunk-6QXLMMT3.js";
|
|
15
|
+
import "./chunk-ZFDZKNGG.js";
|
|
16
|
+
import "./chunk-FWD7AL6N.js";
|
|
17
|
+
import "./chunk-2GNFDZA2.js";
|
|
18
|
+
import "./chunk-JTUKLCXS.js";
|
|
19
|
+
import "./chunk-4KHEMC32.js";
|
|
20
|
+
import "./chunk-ROY4YAEQ.js";
|
|
21
|
+
import "./chunk-WRBKLYSJ.js";
|
|
22
|
+
import "./chunk-3LDULPRE.js";
|
|
23
|
+
import "./chunk-XW6KISBB.js";
|
|
24
|
+
import "./chunk-AWQ7BQTQ.js";
|
|
25
|
+
import "./chunk-EUUUMY7J.js";
|
|
26
|
+
import "./chunk-YLDALTWZ.js";
|
|
27
|
+
import "./chunk-5FBYXK5P.js";
|
|
28
|
+
import "./chunk-LLNZGEFK.js";
|
|
29
|
+
import "./chunk-QXTKSOFI.js";
|
|
30
|
+
import "./chunk-X2NL4KUO.js";
|
|
31
|
+
import "./chunk-UCQ2VUTG.js";
|
|
32
|
+
import "./chunk-DGWHAVRG.js";
|
|
33
|
+
import "./chunk-PTHVMXZI.js";
|
|
34
|
+
import "./chunk-GSGDWJB5.js";
|
|
35
|
+
import "./chunk-UTI5G6OJ.js";
|
|
36
|
+
import "./chunk-2EZ3ZJZZ.js";
|
|
37
|
+
import "./chunk-5ZSO4T2G.js";
|
|
38
|
+
import "./chunk-TFFGOFVZ.js";
|
|
39
|
+
import "./chunk-OHX6MIUZ.js";
|
|
40
|
+
import "./chunk-36JUQZVQ.js";
|
|
41
|
+
import "./chunk-PZ5AY32C.js";
|
|
42
|
+
export {
|
|
43
|
+
ensureExportGitignored,
|
|
44
|
+
ensureGitignoredOrWarn,
|
|
45
|
+
ensureSecretPathGitignored,
|
|
46
|
+
ensureWorkspaceEnvGitignored,
|
|
47
|
+
refuseIfTracked,
|
|
48
|
+
requireSecretPathGitignored,
|
|
49
|
+
secretPathLabel
|
|
50
|
+
};
|
|
51
|
+
//# sourceMappingURL=gitignore-3SJ3WNRG.js.map
|