@unbrained/pm-cli 2026.6.11 → 2026.6.13
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 +47 -0
- package/README.md +1 -1
- package/dist/cli/commands/completion.js +20 -8
- package/dist/cli/commands/completion.js.map +1 -1
- package/dist/cli/commands/create.js +13 -3
- package/dist/cli/commands/create.js.map +1 -1
- package/dist/cli/commands/docs.d.ts +2 -0
- package/dist/cli/commands/docs.js +2 -2
- package/dist/cli/commands/docs.js.map +1 -1
- package/dist/cli/commands/files.d.ts +2 -0
- package/dist/cli/commands/files.js +2 -2
- package/dist/cli/commands/files.js.map +1 -1
- package/dist/cli/commands/health.d.ts +1 -1
- package/dist/cli/commands/health.js +77 -2
- package/dist/cli/commands/health.js.map +1 -1
- package/dist/cli/commands/history-repair.d.ts +36 -0
- package/dist/cli/commands/history-repair.js +68 -3
- package/dist/cli/commands/history-repair.js.map +1 -1
- package/dist/cli/commands/index.d.ts +1 -1
- package/dist/cli/commands/index.js +3 -3
- package/dist/cli/commands/index.js.map +1 -1
- package/dist/cli/commands/linked-artifacts.d.ts +18 -0
- package/dist/cli/commands/linked-artifacts.js +26 -3
- package/dist/cli/commands/linked-artifacts.js.map +1 -1
- package/dist/cli/commands/plan.d.ts +6 -0
- package/dist/cli/commands/plan.js +93 -32
- package/dist/cli/commands/plan.js.map +1 -1
- package/dist/cli/commands/validate.d.ts +20 -0
- package/dist/cli/commands/validate.js +292 -28
- package/dist/cli/commands/validate.js.map +1 -1
- package/dist/cli/error-guidance.js +29 -2
- package/dist/cli/error-guidance.js.map +1 -1
- package/dist/cli/help-content.js +7 -3
- package/dist/cli/help-content.js.map +1 -1
- package/dist/cli/main.js +13 -3
- package/dist/cli/main.js.map +1 -1
- package/dist/cli/register-mutation.js +47 -16
- package/dist/cli/register-mutation.js.map +1 -1
- package/dist/cli/register-operations.js +10 -2
- package/dist/cli/register-operations.js.map +1 -1
- package/dist/cli/register-setup.js +16 -16
- package/dist/cli/register-setup.js.map +1 -1
- package/dist/cli-bundle/chunks/{activity-XADJOG6G.js → activity-PPO7QWJF.js} +11 -11
- package/dist/cli-bundle/chunks/activity-XIOTGZMU.js +16 -0
- package/dist/cli-bundle/chunks/{aggregate-6OTS3AOO.js → aggregate-IRHJWEKG.js} +10 -10
- package/dist/cli-bundle/chunks/{aggregate-OD36DJU5.js → aggregate-XEBW22UQ.js} +10 -10
- package/dist/cli-bundle/chunks/{append-JYWO4P7W.js → append-N2AWXKZC.js} +8 -8
- package/dist/cli-bundle/chunks/{append-KG55G7S3.js → append-NL67JNJU.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-IH4MBKK7.js → chunk-2ANTZBYF.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-F75JSIOZ.js → chunk-2J2AH4V5.js} +6 -6
- package/dist/cli-bundle/chunks/{chunk-CCX4RSYZ.js → chunk-32XSW44C.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-DY6C42S6.js → chunk-36BCSMKP.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-XUC4C4PT.js → chunk-3CQPVBK3.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-SXKNJPQ7.js → chunk-3FMQMHAG.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-I7NYDZDV.js → chunk-3VULHQNS.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-HHHJ2GI3.js → chunk-4FHLNNW7.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-RXAP6JL5.js → chunk-4JHJ7YG2.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-P5BJOMBB.js → chunk-4TPFXE2R.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-XJDGS74Y.js → chunk-4ZKKZMLH.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-XJDGS74Y.js.map → chunk-4ZKKZMLH.js.map} +1 -1
- package/dist/cli-bundle/chunks/{chunk-3SLOMKCJ.js → chunk-5HSAHRYA.js} +12 -12
- package/dist/cli-bundle/chunks/{chunk-ZLMIWZUG.js → chunk-5LMF75Q7.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-TK5VZFHY.js → chunk-6TBR5AZ2.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-ATEES5SX.js → chunk-6ZFTM65G.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-P2PSODAQ.js → chunk-7CRFV6JR.js} +111 -10
- package/dist/cli-bundle/chunks/chunk-7CRFV6JR.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-VFUZV5EB.js → chunk-7SM7VA5I.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-GKIZW7SM.js → chunk-AAUYXSFF.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-FXRU333M.js → chunk-AGG32LKL.js} +111 -10
- package/dist/cli-bundle/chunks/chunk-AGG32LKL.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-OASDW5UI.js → chunk-AUDDXKNX.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-ZMW77VWV.js → chunk-BVL5KGVA.js} +9 -9
- package/dist/cli-bundle/chunks/{chunk-4JCSYR6F.js → chunk-C24PWDFG.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-4HFU4UO2.js → chunk-CEGUH2E5.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-Y3YKK7CY.js → chunk-DWG4FHPY.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-EKS6O2IR.js +217 -0
- package/dist/cli-bundle/chunks/chunk-EKS6O2IR.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-YW6Q3RYZ.js → chunk-GFBEXDCQ.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-XMBI6TNW.js → chunk-GOO4UXBI.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-IGVJRZ6H.js → chunk-GRZGHGRG.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-E5DUIJA4.js → chunk-HLEGAQXT.js} +20 -7
- package/dist/cli-bundle/chunks/chunk-HLEGAQXT.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-HWHONML5.js +190 -0
- package/dist/cli-bundle/chunks/chunk-HWHONML5.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-TNAP7EJX.js → chunk-HZOX5BYD.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-VSRZRLG3.js → chunk-IIOIBAQW.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-IUKD4W6Z.js → chunk-IXVSSHGV.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-WUNFKP7M.js → chunk-IZHCCG4S.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-VAOUX6TK.js → chunk-JCTZV7TO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-ZYNJNPYD.js → chunk-JE5IZXDS.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-QNJSITCX.js → chunk-JW7D6437.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-B65UUCGQ.js → chunk-JWXTOYBI.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-7RIT3OCD.js → chunk-KHGTYCJ6.js} +12 -12
- package/dist/cli-bundle/chunks/{chunk-HI7STVF2.js → chunk-L6YQONLM.js} +11 -27
- package/dist/cli-bundle/chunks/chunk-L6YQONLM.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-FY4SPXSC.js → chunk-LFW5NQUP.js} +59 -86
- package/dist/cli-bundle/chunks/chunk-LFW5NQUP.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-VPEAS7PS.js → chunk-LGOXXQUW.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-I2IJY2NL.js → chunk-LOAR5TKX.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-S26FESD4.js → chunk-LSSTKL3Y.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-CW6E4NAT.js → chunk-LYNQ3NGI.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-4YFAGDRH.js → chunk-M3SI2REU.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-73ZPG2I3.js → chunk-MACCNKSZ.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-IKOH24GZ.js → chunk-MGAQ6KZG.js} +20 -15
- package/dist/cli-bundle/chunks/{chunk-IKOH24GZ.js.map → chunk-MGAQ6KZG.js.map} +2 -2
- package/dist/cli-bundle/chunks/chunk-NAWVUHXH.js +220 -0
- package/dist/cli-bundle/chunks/chunk-NAWVUHXH.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-P5U5EOMA.js → chunk-NN6RKGFW.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-GWZSYR6X.js → chunk-O3YCJOVX.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-7UGSRQCL.js → chunk-PEH7SZD2.js} +7 -7
- package/dist/cli-bundle/chunks/{chunk-7UGSRQCL.js.map → chunk-PEH7SZD2.js.map} +2 -2
- package/dist/cli-bundle/chunks/{chunk-UOO6BYIA.js → chunk-PNYAAB4S.js} +21 -188
- package/dist/cli-bundle/chunks/chunk-PNYAAB4S.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-UUWGCWBU.js → chunk-QQG4HEX7.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-XTKJSVWH.js → chunk-QU3OPNVV.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-LCSCXBGT.js → chunk-R4VWYWRN.js} +19 -193
- package/dist/cli-bundle/chunks/chunk-R4VWYWRN.js.map +7 -0
- package/dist/cli-bundle/chunks/{chunk-PSD7F7DX.js → chunk-RFR2YQGO.js} +21 -8
- package/dist/cli-bundle/chunks/chunk-RFR2YQGO.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-EWFY7SLA.js → chunk-RHYBR6G7.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-A6LXQFO7.js → chunk-S2CDTRJ6.js} +52 -79
- package/dist/cli-bundle/chunks/chunk-S2CDTRJ6.js.map +1 -0
- package/dist/cli-bundle/chunks/{chunk-J3GD64J2.js → chunk-SGMGMCIF.js} +21 -16
- package/dist/cli-bundle/chunks/{chunk-J3GD64J2.js.map → chunk-SGMGMCIF.js.map} +1 -1
- package/dist/cli-bundle/chunks/{chunk-S2ZLDYGS.js → chunk-SOHXUA2Q.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-KWAXVAXX.js → chunk-SQDKAEKG.js} +4 -4
- package/dist/cli-bundle/chunks/{chunk-7IYFN5R7.js → chunk-TOX7YQ7X.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-FDH2X65L.js → chunk-TSXWFN3L.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-OLKBSY4N.js → chunk-UCVJP4JL.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-AVGHVVF7.js → chunk-V4KP3TCN.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-QKW5D45B.js → chunk-VNC2HBL4.js} +5 -5
- package/dist/cli-bundle/chunks/{chunk-QJMGRZO2.js → chunk-VYZNX4C5.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-5SCT2JCT.js → chunk-W6KNFAMZ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-I53JBTJW.js → chunk-WLH7X4RN.js} +6 -6
- package/dist/cli-bundle/chunks/{chunk-ESANVZF4.js → chunk-XOYHMHFF.js} +3 -3
- package/dist/cli-bundle/chunks/{chunk-HGLC63AU.js → chunk-XWDZVCBJ.js} +8 -8
- package/dist/cli-bundle/chunks/{chunk-3KLPFWZ4.js → chunk-XXLMJDUB.js} +10 -26
- package/dist/cli-bundle/chunks/chunk-XXLMJDUB.js.map +7 -0
- package/dist/cli-bundle/chunks/chunk-Z647PYLD.js +187 -0
- package/dist/cli-bundle/chunks/chunk-Z647PYLD.js.map +1 -0
- package/dist/cli-bundle/chunks/{claim-MJ7DZFC3.js → claim-HE6KEGJW.js} +10 -10
- package/dist/cli-bundle/chunks/{claim-2RDYMCTP.js → claim-QJOQBH7J.js} +10 -10
- package/dist/cli-bundle/chunks/{close-XLEKIQSW.js → close-SPUFW5QR.js} +8 -8
- package/dist/cli-bundle/chunks/close-WOG5WTMZ.js +13 -0
- package/dist/cli-bundle/chunks/{close-many-AOD4HSAZ.js → close-many-GKAJX54X.js} +15 -15
- package/dist/cli-bundle/chunks/{close-many-XKAQY5CQ.js → close-many-GL6NRUU5.js} +15 -15
- package/dist/cli-bundle/chunks/{comments-RN5TG4ZN.js → comments-5FPT6L7N.js} +10 -10
- package/dist/cli-bundle/chunks/{comments-B4RWWDJT.js → comments-TOLOYWNI.js} +10 -10
- package/dist/cli-bundle/chunks/{config-3JXJ3XZ7.js → config-4MN45TIH.js} +8 -8
- package/dist/cli-bundle/chunks/{config-FZ4UDC4B.js → config-7N6D7YJE.js} +8 -8
- package/dist/cli-bundle/chunks/{context-QBPO3BFM.js → context-AQSLE7DZ.js} +13 -13
- package/dist/cli-bundle/chunks/{context-L36PIN35.js → context-U3PUJMVN.js} +13 -13
- package/dist/cli-bundle/chunks/{contracts-MIXBWJIB.js → contracts-H7KCQXLY.js} +4 -4
- package/dist/cli-bundle/chunks/{contracts-3NKWYKKU.js → contracts-ITSJXO3O.js} +4 -4
- package/dist/cli-bundle/chunks/{copy-ALU5WMHA.js → copy-C4W522JM.js} +7 -7
- package/dist/cli-bundle/chunks/{copy-FWIVTLBO.js → copy-EB3MUCSW.js} +7 -7
- package/dist/cli-bundle/chunks/{create-IFA26O2I.js → create-4EQNELMY.js} +13 -13
- package/dist/cli-bundle/chunks/create-NW3K7LVG.js +27 -0
- package/dist/cli-bundle/chunks/{delete-IYTIYAJS.js → delete-X5QLXIQX.js} +7 -7
- package/dist/cli-bundle/chunks/{delete-Y2SGJBGY.js → delete-ZLGUYIXU.js} +7 -7
- package/dist/cli-bundle/chunks/{deps-CZ4PTVXU.js → deps-GPB3LGWN.js} +7 -7
- package/dist/cli-bundle/chunks/{deps-6TSPOSGU.js → deps-HV2C2L46.js} +7 -7
- package/dist/cli-bundle/chunks/{docs-5WMBVQT2.js → docs-RJQPLROO.js} +11 -11
- package/dist/cli-bundle/chunks/docs-RJQPLROO.js.map +1 -0
- package/dist/cli-bundle/chunks/{docs-MB53UJAJ.js → docs-SRTLCQOL.js} +10 -10
- package/dist/cli-bundle/chunks/docs-SRTLCQOL.js.map +7 -0
- package/dist/cli-bundle/chunks/{extension-Q34OEWO5.js → extension-MM3TVWOO.js} +5 -5
- package/dist/cli-bundle/chunks/{extension-WH2FOIOZ.js → extension-WKPVPNCC.js} +5 -5
- package/dist/cli-bundle/chunks/{files-GVMNVLCB.js → files-LIFDKNCN.js} +10 -10
- package/dist/cli-bundle/chunks/files-LIFDKNCN.js.map +7 -0
- package/dist/cli-bundle/chunks/{files-DLB5LJEP.js → files-OIFN3DQX.js} +11 -11
- package/dist/cli-bundle/chunks/files-OIFN3DQX.js.map +1 -0
- package/dist/cli-bundle/chunks/{gc-4Z3IKHAZ.js → gc-DL6AVOX5.js} +12 -181
- package/dist/cli-bundle/chunks/gc-DL6AVOX5.js.map +7 -0
- package/dist/cli-bundle/chunks/{gc-2WEPW6D6.js → gc-NRFHLVFT.js} +14 -176
- package/dist/cli-bundle/chunks/gc-NRFHLVFT.js.map +1 -0
- package/dist/cli-bundle/chunks/{get-QARTE6BL.js → get-K7UULTQF.js} +11 -11
- package/dist/cli-bundle/chunks/{get-PCHS7RA6.js → get-SAB7CRBG.js} +11 -11
- package/dist/cli-bundle/chunks/{health-4ZYB3IYQ.js → health-NUVZYIEV.js} +83 -16
- package/dist/cli-bundle/chunks/health-NUVZYIEV.js.map +1 -0
- package/dist/cli-bundle/chunks/{health-YO5LRWN4.js → health-VJWH3ZFK.js} +82 -15
- package/dist/cli-bundle/chunks/health-VJWH3ZFK.js.map +7 -0
- package/dist/cli-bundle/chunks/{history-7WUAEWHW.js → history-GYFD2DJW.js} +10 -10
- package/dist/cli-bundle/chunks/history-IUVN4NTN.js +20 -0
- package/dist/cli-bundle/chunks/{history-compact-3EJ3L2O7.js → history-compact-SLL6ESXH.js} +11 -11
- package/dist/cli-bundle/chunks/{history-compact-LW27IPFK.js → history-compact-WQZQ6KXM.js} +11 -11
- package/dist/cli-bundle/chunks/history-redact-75KIIJUJ.js +19 -0
- package/dist/cli-bundle/chunks/{history-redact-G72A4EJ4.js → history-redact-SDTDR6WM.js} +11 -11
- package/dist/cli-bundle/chunks/{history-repair-RUGKD3YR.js → history-repair-BJCGM6Q3.js} +72 -14
- package/dist/cli-bundle/chunks/history-repair-BJCGM6Q3.js.map +1 -0
- package/dist/cli-bundle/chunks/{history-repair-KVPFJKOS.js → history-repair-UCYS55ZX.js} +71 -13
- package/dist/cli-bundle/chunks/history-repair-UCYS55ZX.js.map +7 -0
- package/dist/cli-bundle/chunks/init-JJFYRUKG.js +17 -0
- package/dist/cli-bundle/chunks/{init-S5WEGUJY.js → init-MXV57LKL.js} +9 -9
- package/dist/cli-bundle/chunks/{learnings-HQXSSKZ5.js → learnings-L6KTZGOT.js} +10 -10
- package/dist/cli-bundle/chunks/{learnings-XK3P4ZDR.js → learnings-QKJOKEAO.js} +10 -10
- package/dist/cli-bundle/chunks/{list-6CL3XFT6.js → list-GGVPXEV6.js} +10 -10
- package/dist/cli-bundle/chunks/list-VOQDQHA4.js +19 -0
- package/dist/cli-bundle/chunks/{notes-5T6P7C5V.js → notes-3NLK7WTZ.js} +10 -10
- package/dist/cli-bundle/chunks/{notes-U5FZCSBT.js → notes-HMCB7TK6.js} +10 -10
- package/dist/cli-bundle/chunks/{plan-VNUG3WZZ.js → plan-DWBYI5C6.js} +63 -23
- package/dist/cli-bundle/chunks/plan-DWBYI5C6.js.map +1 -0
- package/dist/cli-bundle/chunks/{plan-FQLMJRLZ.js → plan-NANUWH4T.js} +62 -22
- package/dist/cli-bundle/chunks/plan-NANUWH4T.js.map +7 -0
- package/dist/cli-bundle/chunks/{register-list-query-VHDXWEPP.js → register-list-query-PWQ5F2VI.js} +18 -18
- package/dist/cli-bundle/chunks/{register-list-query-NPE3ECJQ.js → register-list-query-SMMMLSWW.js} +18 -18
- package/dist/cli-bundle/chunks/{register-mutation-EAYNLGOS.js → register-mutation-QKFPTIZG.js} +64 -47
- package/dist/cli-bundle/chunks/{register-mutation-EAYNLGOS.js.map → register-mutation-QKFPTIZG.js.map} +2 -2
- package/dist/cli-bundle/chunks/{register-mutation-DG53FCBV.js → register-mutation-ZYJQ4DVP.js} +65 -48
- package/dist/cli-bundle/chunks/{register-mutation-DG53FCBV.js.map → register-mutation-ZYJQ4DVP.js.map} +1 -1
- package/dist/cli-bundle/chunks/{register-operations-FWFE64JG.js → register-operations-2FMZ6WEF.js} +37 -33
- package/dist/cli-bundle/chunks/{register-operations-FWFE64JG.js.map → register-operations-2FMZ6WEF.js.map} +2 -2
- package/dist/cli-bundle/chunks/{register-operations-AM6KTWB6.js → register-operations-BAFQURZG.js} +38 -34
- package/dist/cli-bundle/chunks/register-operations-BAFQURZG.js.map +1 -0
- package/dist/cli-bundle/chunks/{register-setup-G4QYI3RX.js → register-setup-DQEIKBIP.js} +30 -30
- package/dist/cli-bundle/chunks/register-setup-DQEIKBIP.js.map +7 -0
- package/dist/cli-bundle/chunks/{register-setup-IKX5524L.js → register-setup-QN2XV7UL.js} +31 -31
- package/dist/cli-bundle/chunks/register-setup-QN2XV7UL.js.map +1 -0
- package/dist/cli-bundle/chunks/restore-DRBNXJJH.js +17 -0
- package/dist/cli-bundle/chunks/{restore-M6AFHMV4.js → restore-FJQWXMPY.js} +11 -11
- package/dist/cli-bundle/chunks/{schema-AINZ2IMM.js → schema-RNVJ55V2.js} +8 -8
- package/dist/cli-bundle/chunks/{schema-76HDZJCC.js → schema-ZZ7ZDM2X.js} +8 -8
- package/dist/cli-bundle/chunks/{search-JMLFQEPJ.js → search-BJ457C2A.js} +10 -10
- package/dist/cli-bundle/chunks/{search-NL3TSCYB.js → search-FQDZXX7P.js} +10 -10
- package/dist/cli-bundle/chunks/{stats-UBD56TGK.js → stats-CUG3ZHOI.js} +7 -7
- package/dist/cli-bundle/chunks/{stats-BKXCBIGT.js → stats-DUQWCVOS.js} +7 -7
- package/dist/cli-bundle/chunks/{telemetry-ZJXK3H7X.js → telemetry-33MRGX4Z.js} +4 -4
- package/dist/cli-bundle/chunks/{telemetry-N454RHG5.js → telemetry-RK2VX75A.js} +4 -4
- package/dist/cli-bundle/chunks/test-SDMYEQHH.js +32 -0
- package/dist/cli-bundle/chunks/{test-BQAKIXAT.js → test-Y3CTFMEC.js} +14 -14
- package/dist/cli-bundle/chunks/{test-all-7LV3I6S5.js → test-all-ANYQ33O2.js} +14 -14
- package/dist/cli-bundle/chunks/{test-all-TDYCCBA4.js → test-all-ARSMX33Q.js} +14 -14
- package/dist/cli-bundle/chunks/{test-runs-E64M6XS3.js → test-runs-5URSD34O.js} +5 -5
- package/dist/cli-bundle/chunks/{test-runs-LXZLULCI.js → test-runs-XNACGSNQ.js} +5 -5
- package/dist/cli-bundle/chunks/update-PD46VOXI.js +21 -0
- package/dist/cli-bundle/chunks/update-U235A7WP.js +25 -0
- package/dist/cli-bundle/chunks/{update-many-V4LA3C4H.js → update-many-6B7PJ33I.js} +22 -22
- package/dist/cli-bundle/chunks/{update-many-TUGU5YXQ.js → update-many-724JCVDE.js} +22 -22
- package/dist/cli-bundle/chunks/{upgrade-37F7JKES.js → upgrade-ALBEZAI7.js} +5 -5
- package/dist/cli-bundle/chunks/{upgrade-L32JA4TZ.js → upgrade-QHRGDBSA.js} +5 -5
- package/dist/cli-bundle/chunks/{validate-EQTT6WVX.js → validate-IQRYFXIV.js} +462 -50
- package/dist/cli-bundle/chunks/validate-IQRYFXIV.js.map +1 -0
- package/dist/cli-bundle/chunks/{validate-XN4I4DPL.js → validate-UY6DRCG5.js} +482 -49
- package/dist/cli-bundle/chunks/validate-UY6DRCG5.js.map +7 -0
- package/dist/cli-bundle/main.js +72 -24
- package/dist/cli-bundle/main.js.map +3 -3
- package/dist/core/diagnostics/remediation.js +19 -6
- package/dist/core/diagnostics/remediation.js.map +1 -1
- package/dist/core/extensions/extension-capability-aliases.js +7 -33
- package/dist/core/extensions/extension-capability-aliases.js.map +1 -1
- package/dist/core/lock/lock-gc.d.ts +31 -0
- package/dist/core/lock/lock-gc.js +120 -62
- package/dist/core/lock/lock-gc.js.map +1 -1
- package/dist/core/search/background-refresh.js +3 -3
- package/dist/core/search/background-refresh.js.map +1 -1
- package/dist/core/shared/errors.d.ts +3 -0
- package/dist/core/shared/errors.js +2 -2
- package/dist/core/shared/errors.js.map +1 -1
- package/dist/core/store/item-store.js +6 -22
- package/dist/core/store/item-store.js.map +1 -1
- package/dist/core/telemetry/consent.js +18 -3
- package/dist/core/telemetry/consent.js.map +1 -1
- package/dist/core/validate/fix-planning.d.ts +130 -0
- package/dist/core/validate/fix-planning.js +202 -0
- package/dist/core/validate/fix-planning.js.map +1 -0
- package/dist/core/validate/missing-by-type.d.ts +21 -0
- package/dist/core/validate/missing-by-type.js +39 -0
- package/dist/core/validate/missing-by-type.js.map +1 -0
- package/dist/core/validate/stale-file-classification.d.ts +41 -0
- package/dist/core/validate/stale-file-classification.js +73 -0
- package/dist/core/validate/stale-file-classification.js.map +1 -0
- package/dist/mcp/server.d.ts +1 -0
- package/dist/mcp/server.js +62 -9
- package/dist/mcp/server.js.map +1 -1
- package/dist/sdk/cli-contracts/tool-parameter-tables.js +38 -2
- package/dist/sdk/cli-contracts/tool-parameter-tables.js.map +1 -1
- package/dist/sdk/cli-contracts.d.ts +6 -1
- package/dist/sdk/cli-contracts.js +74 -7
- package/dist/sdk/cli-contracts.js.map +1 -1
- package/docs/AGENT_GUIDE.md +6 -1
- package/docs/COMMANDS.md +23 -1
- package/package.json +1 -1
- package/plugins/pm-claude/README.md +4 -12
- package/dist/cli-bundle/chunks/activity-XZIUPGZH.js +0 -16
- package/dist/cli-bundle/chunks/chunk-3KLPFWZ4.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-A6LXQFO7.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-E5DUIJA4.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-FXRU333M.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-FY4SPXSC.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-HI7STVF2.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-LCSCXBGT.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-P2PSODAQ.js.map +0 -7
- package/dist/cli-bundle/chunks/chunk-PSD7F7DX.js.map +0 -1
- package/dist/cli-bundle/chunks/chunk-UOO6BYIA.js.map +0 -1
- package/dist/cli-bundle/chunks/close-4FMAPEMY.js +0 -13
- package/dist/cli-bundle/chunks/create-JVXYHYH4.js +0 -27
- package/dist/cli-bundle/chunks/docs-5WMBVQT2.js.map +0 -1
- package/dist/cli-bundle/chunks/docs-MB53UJAJ.js.map +0 -7
- package/dist/cli-bundle/chunks/files-DLB5LJEP.js.map +0 -1
- package/dist/cli-bundle/chunks/files-GVMNVLCB.js.map +0 -7
- package/dist/cli-bundle/chunks/gc-2WEPW6D6.js.map +0 -1
- package/dist/cli-bundle/chunks/gc-4Z3IKHAZ.js.map +0 -7
- package/dist/cli-bundle/chunks/health-4ZYB3IYQ.js.map +0 -1
- package/dist/cli-bundle/chunks/health-YO5LRWN4.js.map +0 -7
- package/dist/cli-bundle/chunks/history-L2FQFRTU.js +0 -20
- package/dist/cli-bundle/chunks/history-redact-QWQCX5DZ.js +0 -19
- package/dist/cli-bundle/chunks/history-repair-KVPFJKOS.js.map +0 -7
- package/dist/cli-bundle/chunks/history-repair-RUGKD3YR.js.map +0 -1
- package/dist/cli-bundle/chunks/init-4BKRHGWW.js +0 -17
- package/dist/cli-bundle/chunks/list-BYNN4ZEO.js +0 -19
- package/dist/cli-bundle/chunks/plan-FQLMJRLZ.js.map +0 -7
- package/dist/cli-bundle/chunks/plan-VNUG3WZZ.js.map +0 -1
- package/dist/cli-bundle/chunks/register-operations-AM6KTWB6.js.map +0 -1
- package/dist/cli-bundle/chunks/register-setup-G4QYI3RX.js.map +0 -7
- package/dist/cli-bundle/chunks/register-setup-IKX5524L.js.map +0 -1
- package/dist/cli-bundle/chunks/restore-CHIOQAQL.js +0 -17
- package/dist/cli-bundle/chunks/test-O74JFUH5.js +0 -32
- package/dist/cli-bundle/chunks/update-2EVXOC7V.js +0 -21
- package/dist/cli-bundle/chunks/update-5A2B6QYB.js +0 -25
- package/dist/cli-bundle/chunks/validate-EQTT6WVX.js.map +0 -1
- package/dist/cli-bundle/chunks/validate-XN4I4DPL.js.map +0 -7
- /package/dist/cli-bundle/chunks/{activity-XADJOG6G.js.map → activity-PPO7QWJF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{activity-XZIUPGZH.js.map → activity-XIOTGZMU.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{aggregate-6OTS3AOO.js.map → aggregate-IRHJWEKG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{aggregate-OD36DJU5.js.map → aggregate-XEBW22UQ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{append-JYWO4P7W.js.map → append-N2AWXKZC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{append-KG55G7S3.js.map → append-NL67JNJU.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-IH4MBKK7.js.map → chunk-2ANTZBYF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-F75JSIOZ.js.map → chunk-2J2AH4V5.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-CCX4RSYZ.js.map → chunk-32XSW44C.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-DY6C42S6.js.map → chunk-36BCSMKP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-XUC4C4PT.js.map → chunk-3CQPVBK3.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-SXKNJPQ7.js.map → chunk-3FMQMHAG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-I7NYDZDV.js.map → chunk-3VULHQNS.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-HHHJ2GI3.js.map → chunk-4FHLNNW7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-RXAP6JL5.js.map → chunk-4JHJ7YG2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-P5BJOMBB.js.map → chunk-4TPFXE2R.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-3SLOMKCJ.js.map → chunk-5HSAHRYA.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ZLMIWZUG.js.map → chunk-5LMF75Q7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-TK5VZFHY.js.map → chunk-6TBR5AZ2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ATEES5SX.js.map → chunk-6ZFTM65G.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-VFUZV5EB.js.map → chunk-7SM7VA5I.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-GKIZW7SM.js.map → chunk-AAUYXSFF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-OASDW5UI.js.map → chunk-AUDDXKNX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ZMW77VWV.js.map → chunk-BVL5KGVA.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-4JCSYR6F.js.map → chunk-C24PWDFG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-4HFU4UO2.js.map → chunk-CEGUH2E5.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-Y3YKK7CY.js.map → chunk-DWG4FHPY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-YW6Q3RYZ.js.map → chunk-GFBEXDCQ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-XMBI6TNW.js.map → chunk-GOO4UXBI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-IGVJRZ6H.js.map → chunk-GRZGHGRG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-TNAP7EJX.js.map → chunk-HZOX5BYD.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-VSRZRLG3.js.map → chunk-IIOIBAQW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-IUKD4W6Z.js.map → chunk-IXVSSHGV.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-WUNFKP7M.js.map → chunk-IZHCCG4S.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-VAOUX6TK.js.map → chunk-JCTZV7TO.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ZYNJNPYD.js.map → chunk-JE5IZXDS.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-QNJSITCX.js.map → chunk-JW7D6437.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-B65UUCGQ.js.map → chunk-JWXTOYBI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-7RIT3OCD.js.map → chunk-KHGTYCJ6.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-VPEAS7PS.js.map → chunk-LGOXXQUW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-I2IJY2NL.js.map → chunk-LOAR5TKX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-S26FESD4.js.map → chunk-LSSTKL3Y.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-CW6E4NAT.js.map → chunk-LYNQ3NGI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-4YFAGDRH.js.map → chunk-M3SI2REU.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-73ZPG2I3.js.map → chunk-MACCNKSZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-P5U5EOMA.js.map → chunk-NN6RKGFW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-GWZSYR6X.js.map → chunk-O3YCJOVX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-UUWGCWBU.js.map → chunk-QQG4HEX7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-XTKJSVWH.js.map → chunk-QU3OPNVV.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-EWFY7SLA.js.map → chunk-RHYBR6G7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-S2ZLDYGS.js.map → chunk-SOHXUA2Q.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-KWAXVAXX.js.map → chunk-SQDKAEKG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-7IYFN5R7.js.map → chunk-TOX7YQ7X.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-FDH2X65L.js.map → chunk-TSXWFN3L.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-OLKBSY4N.js.map → chunk-UCVJP4JL.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-AVGHVVF7.js.map → chunk-V4KP3TCN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-QKW5D45B.js.map → chunk-VNC2HBL4.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-QJMGRZO2.js.map → chunk-VYZNX4C5.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-5SCT2JCT.js.map → chunk-W6KNFAMZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-I53JBTJW.js.map → chunk-WLH7X4RN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-ESANVZF4.js.map → chunk-XOYHMHFF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{chunk-HGLC63AU.js.map → chunk-XWDZVCBJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{claim-MJ7DZFC3.js.map → claim-HE6KEGJW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{claim-2RDYMCTP.js.map → claim-QJOQBH7J.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-XLEKIQSW.js.map → close-SPUFW5QR.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-4FMAPEMY.js.map → close-WOG5WTMZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-many-AOD4HSAZ.js.map → close-many-GKAJX54X.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{close-many-XKAQY5CQ.js.map → close-many-GL6NRUU5.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{comments-RN5TG4ZN.js.map → comments-5FPT6L7N.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{comments-B4RWWDJT.js.map → comments-TOLOYWNI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{config-3JXJ3XZ7.js.map → config-4MN45TIH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{config-FZ4UDC4B.js.map → config-7N6D7YJE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{context-QBPO3BFM.js.map → context-AQSLE7DZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{context-L36PIN35.js.map → context-U3PUJMVN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{contracts-MIXBWJIB.js.map → contracts-H7KCQXLY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{contracts-3NKWYKKU.js.map → contracts-ITSJXO3O.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{copy-ALU5WMHA.js.map → copy-C4W522JM.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{copy-FWIVTLBO.js.map → copy-EB3MUCSW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{create-IFA26O2I.js.map → create-4EQNELMY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{create-JVXYHYH4.js.map → create-NW3K7LVG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{delete-IYTIYAJS.js.map → delete-X5QLXIQX.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{delete-Y2SGJBGY.js.map → delete-ZLGUYIXU.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{deps-CZ4PTVXU.js.map → deps-GPB3LGWN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{deps-6TSPOSGU.js.map → deps-HV2C2L46.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{extension-Q34OEWO5.js.map → extension-MM3TVWOO.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{extension-WH2FOIOZ.js.map → extension-WKPVPNCC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{get-QARTE6BL.js.map → get-K7UULTQF.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{get-PCHS7RA6.js.map → get-SAB7CRBG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-7WUAEWHW.js.map → history-GYFD2DJW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-L2FQFRTU.js.map → history-IUVN4NTN.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-compact-3EJ3L2O7.js.map → history-compact-SLL6ESXH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-compact-LW27IPFK.js.map → history-compact-WQZQ6KXM.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-redact-QWQCX5DZ.js.map → history-redact-75KIIJUJ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{history-redact-G72A4EJ4.js.map → history-redact-SDTDR6WM.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{init-4BKRHGWW.js.map → init-JJFYRUKG.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{init-S5WEGUJY.js.map → init-MXV57LKL.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{learnings-HQXSSKZ5.js.map → learnings-L6KTZGOT.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{learnings-XK3P4ZDR.js.map → learnings-QKJOKEAO.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{list-6CL3XFT6.js.map → list-GGVPXEV6.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{list-BYNN4ZEO.js.map → list-VOQDQHA4.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{notes-5T6P7C5V.js.map → notes-3NLK7WTZ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{notes-U5FZCSBT.js.map → notes-HMCB7TK6.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-list-query-VHDXWEPP.js.map → register-list-query-PWQ5F2VI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{register-list-query-NPE3ECJQ.js.map → register-list-query-SMMMLSWW.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{restore-CHIOQAQL.js.map → restore-DRBNXJJH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{restore-M6AFHMV4.js.map → restore-FJQWXMPY.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{schema-AINZ2IMM.js.map → schema-RNVJ55V2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{schema-76HDZJCC.js.map → schema-ZZ7ZDM2X.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{search-JMLFQEPJ.js.map → search-BJ457C2A.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{search-NL3TSCYB.js.map → search-FQDZXX7P.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{stats-UBD56TGK.js.map → stats-CUG3ZHOI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{stats-BKXCBIGT.js.map → stats-DUQWCVOS.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{telemetry-ZJXK3H7X.js.map → telemetry-33MRGX4Z.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{telemetry-N454RHG5.js.map → telemetry-RK2VX75A.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-O74JFUH5.js.map → test-SDMYEQHH.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-BQAKIXAT.js.map → test-Y3CTFMEC.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-all-7LV3I6S5.js.map → test-all-ANYQ33O2.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-all-TDYCCBA4.js.map → test-all-ARSMX33Q.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-runs-E64M6XS3.js.map → test-runs-5URSD34O.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{test-runs-LXZLULCI.js.map → test-runs-XNACGSNQ.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-2EVXOC7V.js.map → update-PD46VOXI.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-5A2B6QYB.js.map → update-U235A7WP.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-many-V4LA3C4H.js.map → update-many-6B7PJ33I.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{update-many-TUGU5YXQ.js.map → update-many-724JCVDE.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{upgrade-37F7JKES.js.map → upgrade-ALBEZAI7.js.map} +0 -0
- /package/dist/cli-bundle/chunks/{upgrade-L32JA4TZ.js.map → upgrade-QHRGDBSA.js.map} +0 -0
|
@@ -1,6 +1,9 @@
|
|
|
1
|
+
import {
|
|
2
|
+
runLockGc
|
|
3
|
+
} from "./chunk-NAWVUHXH.js";
|
|
1
4
|
import {
|
|
2
5
|
nowIso
|
|
3
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-IXVSSHGV.js";
|
|
4
7
|
import {
|
|
5
8
|
EXIT_CODE,
|
|
6
9
|
PmCliError,
|
|
@@ -11,183 +14,11 @@ import {
|
|
|
11
14
|
runActiveOnIndexHooks,
|
|
12
15
|
runActiveOnReadHooks,
|
|
13
16
|
runActiveOnWriteHooks
|
|
14
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-LFW5NQUP.js";
|
|
15
18
|
|
|
16
19
|
// dist/cli/commands/gc.js
|
|
17
|
-
import fs2 from "node:fs/promises";
|
|
18
|
-
import path2 from "node:path";
|
|
19
|
-
|
|
20
|
-
// dist/core/lock/lock-gc.js
|
|
21
20
|
import fs from "node:fs/promises";
|
|
22
21
|
import path from "node:path";
|
|
23
|
-
!(function() {
|
|
24
|
-
try {
|
|
25
|
-
var e = "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof globalThis ? globalThis : "undefined" != typeof self ? self : {}, n = new e.Error().stack;
|
|
26
|
-
n && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[n] = "1a412027-5c73-58d4-b696-4a909dde88a8");
|
|
27
|
-
} catch (e2) {
|
|
28
|
-
}
|
|
29
|
-
})();
|
|
30
|
-
function parseLock(raw) {
|
|
31
|
-
let parsed;
|
|
32
|
-
try {
|
|
33
|
-
parsed = JSON.parse(raw);
|
|
34
|
-
} catch {
|
|
35
|
-
return null;
|
|
36
|
-
}
|
|
37
|
-
if (typeof parsed !== "object" || parsed === null || Array.isArray(parsed)) {
|
|
38
|
-
return null;
|
|
39
|
-
}
|
|
40
|
-
const candidate = parsed;
|
|
41
|
-
const { id, owner, created_at, ttl_seconds } = candidate;
|
|
42
|
-
if (typeof id !== "string" || typeof owner !== "string" || typeof created_at !== "string" || typeof ttl_seconds !== "number" || !Number.isFinite(ttl_seconds)) {
|
|
43
|
-
return null;
|
|
44
|
-
}
|
|
45
|
-
return { id, owner, created_at, ttl_seconds };
|
|
46
|
-
}
|
|
47
|
-
function isErrno(error, code) {
|
|
48
|
-
return typeof error === "object" && error !== null && "code" in error && error.code === code;
|
|
49
|
-
}
|
|
50
|
-
async function runLockGc(pmRoot, options) {
|
|
51
|
-
const { dryRun, hooks } = options;
|
|
52
|
-
const nowMs = options.now ?? Date.now();
|
|
53
|
-
const locksDir = path.join(pmRoot, "locks");
|
|
54
|
-
const result = {
|
|
55
|
-
scanned: 0,
|
|
56
|
-
removed: [],
|
|
57
|
-
retained: [],
|
|
58
|
-
warnings: [],
|
|
59
|
-
entries: []
|
|
60
|
-
};
|
|
61
|
-
let dirEntries;
|
|
62
|
-
try {
|
|
63
|
-
const raw = await fs.readdir(locksDir);
|
|
64
|
-
dirEntries = raw.filter((f) => f.endsWith(".lock")).sort();
|
|
65
|
-
} catch (error) {
|
|
66
|
-
if (isErrno(error, "ENOENT")) {
|
|
67
|
-
return result;
|
|
68
|
-
}
|
|
69
|
-
throw error;
|
|
70
|
-
}
|
|
71
|
-
for (const file of dirEntries) {
|
|
72
|
-
result.scanned += 1;
|
|
73
|
-
const absPath = path.join(locksDir, file);
|
|
74
|
-
const relPath = `locks/${file}`;
|
|
75
|
-
if (hooks?.onRead) {
|
|
76
|
-
const hookWarnings = await hooks.onRead(absPath);
|
|
77
|
-
result.warnings.push(...hookWarnings);
|
|
78
|
-
}
|
|
79
|
-
let raw;
|
|
80
|
-
try {
|
|
81
|
-
raw = await fs.readFile(absPath, "utf8");
|
|
82
|
-
} catch (readError) {
|
|
83
|
-
if (isErrno(readError, "ENOENT")) {
|
|
84
|
-
result.scanned -= 1;
|
|
85
|
-
continue;
|
|
86
|
-
}
|
|
87
|
-
result.warnings.push(`lock_unreadable:${file}`);
|
|
88
|
-
result.retained.push(relPath);
|
|
89
|
-
result.entries.push({
|
|
90
|
-
file,
|
|
91
|
-
id: null,
|
|
92
|
-
owner: null,
|
|
93
|
-
created_at: null,
|
|
94
|
-
ttl_seconds: null,
|
|
95
|
-
age_seconds: null,
|
|
96
|
-
stale: false,
|
|
97
|
-
reason: "unparseable"
|
|
98
|
-
});
|
|
99
|
-
continue;
|
|
100
|
-
}
|
|
101
|
-
const lock = parseLock(raw);
|
|
102
|
-
if (lock === null) {
|
|
103
|
-
result.warnings.push(`lock_unparseable:${file}`);
|
|
104
|
-
result.retained.push(relPath);
|
|
105
|
-
result.entries.push({
|
|
106
|
-
file,
|
|
107
|
-
id: null,
|
|
108
|
-
owner: null,
|
|
109
|
-
created_at: null,
|
|
110
|
-
ttl_seconds: null,
|
|
111
|
-
age_seconds: null,
|
|
112
|
-
stale: false,
|
|
113
|
-
reason: "unparseable"
|
|
114
|
-
});
|
|
115
|
-
continue;
|
|
116
|
-
}
|
|
117
|
-
const createdAtMs = Date.parse(lock.created_at);
|
|
118
|
-
if (!Number.isFinite(createdAtMs)) {
|
|
119
|
-
result.warnings.push(`lock_invalid_timestamp:${file}`);
|
|
120
|
-
result.retained.push(relPath);
|
|
121
|
-
result.entries.push({
|
|
122
|
-
file,
|
|
123
|
-
id: lock.id,
|
|
124
|
-
owner: lock.owner,
|
|
125
|
-
created_at: lock.created_at,
|
|
126
|
-
ttl_seconds: lock.ttl_seconds,
|
|
127
|
-
age_seconds: null,
|
|
128
|
-
stale: false,
|
|
129
|
-
reason: "unparseable"
|
|
130
|
-
});
|
|
131
|
-
continue;
|
|
132
|
-
}
|
|
133
|
-
const ageMs = nowMs - createdAtMs;
|
|
134
|
-
const age_seconds = Math.floor(ageMs / 1e3);
|
|
135
|
-
const stale = ageMs > lock.ttl_seconds * 1e3;
|
|
136
|
-
if (!stale) {
|
|
137
|
-
result.retained.push(relPath);
|
|
138
|
-
result.entries.push({
|
|
139
|
-
file,
|
|
140
|
-
id: lock.id,
|
|
141
|
-
owner: lock.owner,
|
|
142
|
-
created_at: lock.created_at,
|
|
143
|
-
ttl_seconds: lock.ttl_seconds,
|
|
144
|
-
age_seconds,
|
|
145
|
-
stale: false,
|
|
146
|
-
reason: "active"
|
|
147
|
-
});
|
|
148
|
-
continue;
|
|
149
|
-
}
|
|
150
|
-
if (!dryRun) {
|
|
151
|
-
try {
|
|
152
|
-
await fs.unlink(absPath);
|
|
153
|
-
} catch (unlinkError) {
|
|
154
|
-
if (!isErrno(unlinkError, "ENOENT")) {
|
|
155
|
-
result.warnings.push(`lock_remove_failed:${file}`);
|
|
156
|
-
result.retained.push(relPath);
|
|
157
|
-
result.entries.push({
|
|
158
|
-
file,
|
|
159
|
-
id: lock.id,
|
|
160
|
-
owner: lock.owner,
|
|
161
|
-
created_at: lock.created_at,
|
|
162
|
-
ttl_seconds: lock.ttl_seconds,
|
|
163
|
-
age_seconds,
|
|
164
|
-
stale: true,
|
|
165
|
-
reason: "expired"
|
|
166
|
-
});
|
|
167
|
-
continue;
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
if (hooks?.onWrite) {
|
|
171
|
-
const hookWarnings = await hooks.onWrite(absPath);
|
|
172
|
-
result.warnings.push(...hookWarnings);
|
|
173
|
-
}
|
|
174
|
-
}
|
|
175
|
-
result.removed.push(relPath);
|
|
176
|
-
result.entries.push({
|
|
177
|
-
file,
|
|
178
|
-
id: lock.id,
|
|
179
|
-
owner: lock.owner,
|
|
180
|
-
created_at: lock.created_at,
|
|
181
|
-
ttl_seconds: lock.ttl_seconds,
|
|
182
|
-
age_seconds,
|
|
183
|
-
stale: true,
|
|
184
|
-
reason: "expired"
|
|
185
|
-
});
|
|
186
|
-
}
|
|
187
|
-
return result;
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
// dist/cli/commands/gc.js
|
|
191
22
|
!(function() {
|
|
192
23
|
try {
|
|
193
24
|
var e = "undefined" != typeof window ? window : "undefined" != typeof global ? global : "undefined" != typeof globalThis ? globalThis : "undefined" != typeof self ? self : {}, n = new e.Error().stack;
|
|
@@ -228,18 +59,18 @@ var GC_TARGETS = [
|
|
|
228
59
|
kind: "file"
|
|
229
60
|
}
|
|
230
61
|
];
|
|
231
|
-
function
|
|
62
|
+
function isErrno(error, code) {
|
|
232
63
|
return typeof error === "object" && error !== null && "code" in error && error.code === code;
|
|
233
64
|
}
|
|
234
65
|
async function removeCacheFile(pmRoot, target, dryRun) {
|
|
235
66
|
const relativePath = target.relativePath;
|
|
236
|
-
const absolutePath =
|
|
67
|
+
const absolutePath = path.join(pmRoot, relativePath);
|
|
237
68
|
const warnings = await runActiveOnReadHooks({
|
|
238
69
|
path: absolutePath,
|
|
239
70
|
scope: "project"
|
|
240
71
|
});
|
|
241
72
|
try {
|
|
242
|
-
const stats = await
|
|
73
|
+
const stats = await fs.stat(absolutePath);
|
|
243
74
|
if (target.kind === "file" && !stats.isFile()) {
|
|
244
75
|
return {
|
|
245
76
|
removed: false,
|
|
@@ -259,9 +90,9 @@ async function removeCacheFile(pmRoot, target, dryRun) {
|
|
|
259
90
|
};
|
|
260
91
|
}
|
|
261
92
|
if (target.kind === "file") {
|
|
262
|
-
await
|
|
93
|
+
await fs.unlink(absolutePath);
|
|
263
94
|
} else {
|
|
264
|
-
await
|
|
95
|
+
await fs.rm(absolutePath, { recursive: true, force: true });
|
|
265
96
|
}
|
|
266
97
|
const writeWarnings = await runActiveOnWriteHooks({
|
|
267
98
|
path: absolutePath,
|
|
@@ -273,7 +104,7 @@ async function removeCacheFile(pmRoot, target, dryRun) {
|
|
|
273
104
|
warnings: [...warnings, ...writeWarnings]
|
|
274
105
|
};
|
|
275
106
|
} catch (error) {
|
|
276
|
-
if (
|
|
107
|
+
if (isErrno(error, "ENOENT")) {
|
|
277
108
|
return {
|
|
278
109
|
removed: false,
|
|
279
110
|
warnings
|
|
@@ -377,4 +208,4 @@ async function runGc(global2, options = {}) {
|
|
|
377
208
|
export {
|
|
378
209
|
runGc
|
|
379
210
|
};
|
|
380
|
-
//# sourceMappingURL=gc-
|
|
211
|
+
//# sourceMappingURL=gc-DL6AVOX5.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../../../../cli/commands/gc.ts"],
|
|
4
|
+
"sourcesContent": ["import fs from \"node:fs/promises\";\nimport path from \"node:path\";\nimport { runActiveOnIndexHooks, runActiveOnReadHooks, runActiveOnWriteHooks } from \"../../core/extensions/index.js\";\nimport { pathExists } from \"../../core/fs/fs-utils.js\";\nimport { runLockGc } from \"../../core/lock/lock-gc.js\";\nimport { EXIT_CODE } from \"../../core/shared/constants.js\";\nimport type { GlobalOptions } from \"../../core/shared/command-types.js\";\nimport { PmCliError } from \"../../core/shared/errors.js\";\nimport { nowIso } from \"../../core/shared/time.js\";\nimport { getSettingsPath, resolvePmRoot } from \"../../core/store/paths.js\";\nimport { readSettings } from \"../../core/store/settings.js\";\n\nconst GC_SCOPE_VALUES = [\"index\", \"embeddings\", \"runtime\", \"locks\"] as const;\ntype GcScope = (typeof GC_SCOPE_VALUES)[number];\n\ninterface GcTarget {\n scope: GcScope;\n relativePath: string;\n kind: \"file\" | \"directory\";\n}\n\nconst GC_TARGETS: readonly GcTarget[] = [\n {\n scope: \"index\",\n relativePath: \"index/manifest.json\",\n kind: \"file\",\n },\n {\n scope: \"embeddings\",\n relativePath: \"search/embeddings.jsonl\",\n kind: \"file\",\n },\n {\n scope: \"embeddings\",\n relativePath: \"search/vectorization-status.json\",\n kind: \"file\",\n },\n {\n scope: \"embeddings\",\n relativePath: \"search/lancedb\",\n kind: \"directory\",\n },\n {\n scope: \"runtime\",\n relativePath: \"runtime/test-runs\",\n kind: \"directory\",\n },\n {\n scope: \"runtime\",\n relativePath: \"runtime/history-drift-cache.json\",\n kind: \"file\",\n },\n] as const;\n\nexport interface GcCommandOptions {\n dryRun?: boolean;\n scope?: string[];\n}\n\nexport interface GcLocksSummary {\n scanned: number;\n removed: number;\n retained: number;\n}\n\nexport interface GcResult {\n ok: boolean;\n dry_run: boolean;\n scope: GcScope[];\n removed: string[];\n retained: string[];\n warnings: string[];\n guidance: string[];\n /** Present only when the locks scope was selected. Summarizes the stale-lock sweep. */\n locks?: GcLocksSummary;\n generated_at: string;\n}\n\nfunction isErrno(error: unknown, code: string): boolean {\n return typeof error === \"object\" && error !== null && \"code\" in error && (error as { code?: string }).code === code;\n}\n\nasync function removeCacheFile(\n pmRoot: string,\n target: GcTarget,\n dryRun: boolean,\n): Promise<{ removed: boolean; warnings: string[] }> {\n const relativePath = target.relativePath;\n const absolutePath = path.join(pmRoot, relativePath);\n const warnings = await runActiveOnReadHooks({\n path: absolutePath,\n scope: \"project\",\n });\n try {\n const stats = await fs.stat(absolutePath);\n if (target.kind === \"file\" && !stats.isFile()) {\n return {\n removed: false,\n warnings: [...warnings, `not_a_file:${relativePath}`],\n };\n }\n if (target.kind === \"directory\" && !stats.isDirectory()) {\n return {\n removed: false,\n warnings: [...warnings, `not_a_directory:${relativePath}`],\n };\n }\n if (dryRun) {\n return {\n removed: true,\n warnings,\n };\n }\n if (target.kind === \"file\") {\n await fs.unlink(absolutePath);\n } else {\n await fs.rm(absolutePath, { recursive: true, force: true });\n }\n const writeWarnings = await runActiveOnWriteHooks({\n path: absolutePath,\n scope: \"project\",\n op: \"gc:remove\",\n });\n return {\n removed: true,\n warnings: [...warnings, ...writeWarnings],\n };\n } catch (error: unknown) {\n if (isErrno(error, \"ENOENT\")) {\n return {\n removed: false,\n warnings,\n };\n }\n throw error;\n }\n}\n\nfunction parseScopes(raw: string[] | undefined): GcScope[] {\n if (!raw || raw.length === 0) {\n return [...GC_SCOPE_VALUES];\n }\n const tokens = raw\n .flatMap((entry) => entry.split(\",\"))\n .map((entry) => entry.trim().toLowerCase())\n .filter((entry) => entry.length > 0);\n if (tokens.length === 0) {\n throw new PmCliError(`--scope requires at least one value (${GC_SCOPE_VALUES.join(\",\")})`, EXIT_CODE.USAGE);\n }\n const resolved = new Set<GcScope>();\n for (const token of tokens) {\n if (!(GC_SCOPE_VALUES as readonly string[]).includes(token)) {\n throw new PmCliError(\n `Invalid --scope value \"${token}\". Expected one or more of: ${GC_SCOPE_VALUES.join(\", \")}`,\n EXIT_CODE.USAGE,\n );\n }\n resolved.add(token as GcScope);\n }\n return GC_SCOPE_VALUES.filter((scope) => resolved.has(scope));\n}\n\nfunction buildGcGuidance(params: {\n dryRun: boolean;\n scopes: GcScope[];\n removed: string[];\n}): string[] {\n const guidance: string[] = [];\n if (params.dryRun) {\n guidance.push(\"Dry-run preview only: no cache artifacts were deleted.\");\n }\n const searchScopeSelected = params.scopes.includes(\"index\") || params.scopes.includes(\"embeddings\");\n const searchArtifactsAffected = params.removed.some(\n (entry) =>\n entry === \"index/manifest.json\" ||\n entry === \"search/embeddings.jsonl\" ||\n entry === \"search/vectorization-status.json\" ||\n entry === \"search/lancedb\",\n );\n if (searchScopeSelected && searchArtifactsAffected) {\n guidance.push(\n 'Search artifacts were removed; run \"pm install search-advanced --project\" if reindex is unavailable, then \"pm reindex --mode keyword\" (and \"--mode semantic\" when semantic search is enabled) before search-heavy workflows.',\n );\n }\n if (params.removed.includes(\"runtime/history-drift-cache.json\")) {\n guidance.push('History drift cache was removed; the next \"pm health\" run performs a full history-drift re-scan.');\n }\n return guidance;\n}\n\nexport async function runGc(global: GlobalOptions, options: GcCommandOptions = {}): Promise<GcResult> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n if (!(await pathExists(getSettingsPath(pmRoot)))) {\n throw new PmCliError(`Tracker is not initialized at ${pmRoot}. Run pm init first.`, EXIT_CODE.NOT_FOUND);\n }\n\n await readSettings(pmRoot);\n const dryRun = options.dryRun === true;\n const scopes = parseScopes(options.scope);\n const selectedTargets = GC_TARGETS.filter((target) => scopes.includes(target.scope));\n\n const removed: string[] = [];\n const retained: string[] = [];\n const warnings: string[] = [];\n\n for (const target of selectedTargets) {\n const result = await removeCacheFile(pmRoot, target, dryRun);\n if (result.removed) {\n removed.push(target.relativePath);\n } else {\n retained.push(target.relativePath);\n }\n warnings.push(...result.warnings);\n }\n\n // The locks scope is not a path-based GC_TARGET: it sweeps the locks/ directory\n // and removes only locks whose own embedded ttl has expired (crashed-process\n // debris), retaining active and unparseable locks. See core/lock/lock-gc.ts.\n let locksSummary: GcLocksSummary | undefined;\n if (scopes.includes(\"locks\")) {\n const lockResult = await runLockGc(pmRoot, {\n dryRun,\n hooks: {\n onRead: (lockPath) => runActiveOnReadHooks({ path: lockPath, scope: \"project\" }),\n onWrite: (lockPath) => runActiveOnWriteHooks({ path: lockPath, scope: \"project\", op: \"gc:lock_remove\" }),\n },\n });\n removed.push(...lockResult.removed);\n retained.push(...lockResult.retained);\n warnings.push(...lockResult.warnings);\n locksSummary = {\n scanned: lockResult.scanned,\n removed: lockResult.removed.length,\n retained: lockResult.retained.length,\n };\n }\n\n warnings.push(\n ...(await runActiveOnIndexHooks({\n mode: dryRun ? \"gc:dry-run\" : \"gc\",\n total_items: selectedTargets.length,\n })),\n );\n const guidance = buildGcGuidance({\n dryRun,\n scopes,\n removed,\n });\n\n return {\n ok: warnings.length === 0,\n dry_run: dryRun,\n scope: scopes,\n removed,\n retained,\n warnings,\n ...(locksSummary ? { locks: locksSummary } : {}),\n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W;MACpB,SAAS,WAAW,QAAQ;MAC5B,UAAU,WAAW,SAAS;;EAElC;AAEA,WAAS,KACP,GAAI,MAAM,sBAAsB;IAC9B,MAAM,SAAS,eAAe;IAC9B,aAAa,gBAAgB;GAC9B,CAAE;AAEL,QAAM,WAAW,gBAAgB;IAC/B;IACA;IACA;GACD;AAED,SAAO;IACL,IAAI,SAAS,WAAW;IACxB,SAAS;IACT,OAAO;IACP;IACA;IACA;IACA,GAAI,eAAe,EAAE,OAAO,aAAY,IAAK,CAAA;IAC7C;IACA,cAAc,OAAM;;AAExB;",
|
|
6
|
+
"names": ["global"]
|
|
7
|
+
}
|
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
|
|
2
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="53de24e8-b5be-5de6-93ad-bdaa9f3015b0")}catch(e){}}();
|
|
3
|
+
import {
|
|
4
|
+
runLockGc
|
|
5
|
+
} from "./chunk-EKS6O2IR.js";
|
|
3
6
|
import {
|
|
4
7
|
nowIso
|
|
5
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-IZHCCG4S.js";
|
|
6
9
|
import {
|
|
7
10
|
EXIT_CODE,
|
|
8
11
|
PmCliError,
|
|
@@ -13,176 +16,11 @@ import {
|
|
|
13
16
|
runActiveOnIndexHooks,
|
|
14
17
|
runActiveOnReadHooks,
|
|
15
18
|
runActiveOnWriteHooks
|
|
16
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-S2CDTRJ6.js";
|
|
17
20
|
|
|
18
21
|
// dist/cli/commands/gc.js
|
|
19
|
-
import fs2 from "node:fs/promises";
|
|
20
|
-
import path2 from "node:path";
|
|
21
|
-
|
|
22
|
-
// dist/core/lock/lock-gc.js
|
|
23
22
|
import fs from "node:fs/promises";
|
|
24
23
|
import path from "node:path";
|
|
25
|
-
function parseLock(raw) {
|
|
26
|
-
let parsed;
|
|
27
|
-
try {
|
|
28
|
-
parsed = JSON.parse(raw);
|
|
29
|
-
} catch {
|
|
30
|
-
return null;
|
|
31
|
-
}
|
|
32
|
-
if (typeof parsed !== "object" || parsed === null || Array.isArray(parsed)) {
|
|
33
|
-
return null;
|
|
34
|
-
}
|
|
35
|
-
const candidate = parsed;
|
|
36
|
-
const { id, owner, created_at, ttl_seconds } = candidate;
|
|
37
|
-
if (typeof id !== "string" || typeof owner !== "string" || typeof created_at !== "string" || typeof ttl_seconds !== "number" || !Number.isFinite(ttl_seconds)) {
|
|
38
|
-
return null;
|
|
39
|
-
}
|
|
40
|
-
return { id, owner, created_at, ttl_seconds };
|
|
41
|
-
}
|
|
42
|
-
function isErrno(error, code) {
|
|
43
|
-
return typeof error === "object" && error !== null && "code" in error && error.code === code;
|
|
44
|
-
}
|
|
45
|
-
async function runLockGc(pmRoot, options) {
|
|
46
|
-
const { dryRun, hooks } = options;
|
|
47
|
-
const nowMs = options.now ?? Date.now();
|
|
48
|
-
const locksDir = path.join(pmRoot, "locks");
|
|
49
|
-
const result = {
|
|
50
|
-
scanned: 0,
|
|
51
|
-
removed: [],
|
|
52
|
-
retained: [],
|
|
53
|
-
warnings: [],
|
|
54
|
-
entries: []
|
|
55
|
-
};
|
|
56
|
-
let dirEntries;
|
|
57
|
-
try {
|
|
58
|
-
const raw = await fs.readdir(locksDir);
|
|
59
|
-
dirEntries = raw.filter((f) => f.endsWith(".lock")).sort();
|
|
60
|
-
} catch (error) {
|
|
61
|
-
if (isErrno(error, "ENOENT")) {
|
|
62
|
-
return result;
|
|
63
|
-
}
|
|
64
|
-
throw error;
|
|
65
|
-
}
|
|
66
|
-
for (const file of dirEntries) {
|
|
67
|
-
result.scanned += 1;
|
|
68
|
-
const absPath = path.join(locksDir, file);
|
|
69
|
-
const relPath = `locks/${file}`;
|
|
70
|
-
if (hooks?.onRead) {
|
|
71
|
-
const hookWarnings = await hooks.onRead(absPath);
|
|
72
|
-
result.warnings.push(...hookWarnings);
|
|
73
|
-
}
|
|
74
|
-
let raw;
|
|
75
|
-
try {
|
|
76
|
-
raw = await fs.readFile(absPath, "utf8");
|
|
77
|
-
} catch (readError) {
|
|
78
|
-
if (isErrno(readError, "ENOENT")) {
|
|
79
|
-
result.scanned -= 1;
|
|
80
|
-
continue;
|
|
81
|
-
}
|
|
82
|
-
result.warnings.push(`lock_unreadable:${file}`);
|
|
83
|
-
result.retained.push(relPath);
|
|
84
|
-
result.entries.push({
|
|
85
|
-
file,
|
|
86
|
-
id: null,
|
|
87
|
-
owner: null,
|
|
88
|
-
created_at: null,
|
|
89
|
-
ttl_seconds: null,
|
|
90
|
-
age_seconds: null,
|
|
91
|
-
stale: false,
|
|
92
|
-
reason: "unparseable"
|
|
93
|
-
});
|
|
94
|
-
continue;
|
|
95
|
-
}
|
|
96
|
-
const lock = parseLock(raw);
|
|
97
|
-
if (lock === null) {
|
|
98
|
-
result.warnings.push(`lock_unparseable:${file}`);
|
|
99
|
-
result.retained.push(relPath);
|
|
100
|
-
result.entries.push({
|
|
101
|
-
file,
|
|
102
|
-
id: null,
|
|
103
|
-
owner: null,
|
|
104
|
-
created_at: null,
|
|
105
|
-
ttl_seconds: null,
|
|
106
|
-
age_seconds: null,
|
|
107
|
-
stale: false,
|
|
108
|
-
reason: "unparseable"
|
|
109
|
-
});
|
|
110
|
-
continue;
|
|
111
|
-
}
|
|
112
|
-
const createdAtMs = Date.parse(lock.created_at);
|
|
113
|
-
if (!Number.isFinite(createdAtMs)) {
|
|
114
|
-
result.warnings.push(`lock_invalid_timestamp:${file}`);
|
|
115
|
-
result.retained.push(relPath);
|
|
116
|
-
result.entries.push({
|
|
117
|
-
file,
|
|
118
|
-
id: lock.id,
|
|
119
|
-
owner: lock.owner,
|
|
120
|
-
created_at: lock.created_at,
|
|
121
|
-
ttl_seconds: lock.ttl_seconds,
|
|
122
|
-
age_seconds: null,
|
|
123
|
-
stale: false,
|
|
124
|
-
reason: "unparseable"
|
|
125
|
-
});
|
|
126
|
-
continue;
|
|
127
|
-
}
|
|
128
|
-
const ageMs = nowMs - createdAtMs;
|
|
129
|
-
const age_seconds = Math.floor(ageMs / 1e3);
|
|
130
|
-
const stale = ageMs > lock.ttl_seconds * 1e3;
|
|
131
|
-
if (!stale) {
|
|
132
|
-
result.retained.push(relPath);
|
|
133
|
-
result.entries.push({
|
|
134
|
-
file,
|
|
135
|
-
id: lock.id,
|
|
136
|
-
owner: lock.owner,
|
|
137
|
-
created_at: lock.created_at,
|
|
138
|
-
ttl_seconds: lock.ttl_seconds,
|
|
139
|
-
age_seconds,
|
|
140
|
-
stale: false,
|
|
141
|
-
reason: "active"
|
|
142
|
-
});
|
|
143
|
-
continue;
|
|
144
|
-
}
|
|
145
|
-
if (!dryRun) {
|
|
146
|
-
try {
|
|
147
|
-
await fs.unlink(absPath);
|
|
148
|
-
} catch (unlinkError) {
|
|
149
|
-
if (!isErrno(unlinkError, "ENOENT")) {
|
|
150
|
-
result.warnings.push(`lock_remove_failed:${file}`);
|
|
151
|
-
result.retained.push(relPath);
|
|
152
|
-
result.entries.push({
|
|
153
|
-
file,
|
|
154
|
-
id: lock.id,
|
|
155
|
-
owner: lock.owner,
|
|
156
|
-
created_at: lock.created_at,
|
|
157
|
-
ttl_seconds: lock.ttl_seconds,
|
|
158
|
-
age_seconds,
|
|
159
|
-
stale: true,
|
|
160
|
-
reason: "expired"
|
|
161
|
-
});
|
|
162
|
-
continue;
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
if (hooks?.onWrite) {
|
|
166
|
-
const hookWarnings = await hooks.onWrite(absPath);
|
|
167
|
-
result.warnings.push(...hookWarnings);
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
result.removed.push(relPath);
|
|
171
|
-
result.entries.push({
|
|
172
|
-
file,
|
|
173
|
-
id: lock.id,
|
|
174
|
-
owner: lock.owner,
|
|
175
|
-
created_at: lock.created_at,
|
|
176
|
-
ttl_seconds: lock.ttl_seconds,
|
|
177
|
-
age_seconds,
|
|
178
|
-
stale: true,
|
|
179
|
-
reason: "expired"
|
|
180
|
-
});
|
|
181
|
-
}
|
|
182
|
-
return result;
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
// dist/cli/commands/gc.js
|
|
186
24
|
var GC_SCOPE_VALUES = ["index", "embeddings", "runtime", "locks"];
|
|
187
25
|
var GC_TARGETS = [
|
|
188
26
|
{
|
|
@@ -216,18 +54,18 @@ var GC_TARGETS = [
|
|
|
216
54
|
kind: "file"
|
|
217
55
|
}
|
|
218
56
|
];
|
|
219
|
-
function
|
|
57
|
+
function isErrno(error, code) {
|
|
220
58
|
return typeof error === "object" && error !== null && "code" in error && error.code === code;
|
|
221
59
|
}
|
|
222
60
|
async function removeCacheFile(pmRoot, target, dryRun) {
|
|
223
61
|
const relativePath = target.relativePath;
|
|
224
|
-
const absolutePath =
|
|
62
|
+
const absolutePath = path.join(pmRoot, relativePath);
|
|
225
63
|
const warnings = await runActiveOnReadHooks({
|
|
226
64
|
path: absolutePath,
|
|
227
65
|
scope: "project"
|
|
228
66
|
});
|
|
229
67
|
try {
|
|
230
|
-
const stats = await
|
|
68
|
+
const stats = await fs.stat(absolutePath);
|
|
231
69
|
if (target.kind === "file" && !stats.isFile()) {
|
|
232
70
|
return {
|
|
233
71
|
removed: false,
|
|
@@ -247,9 +85,9 @@ async function removeCacheFile(pmRoot, target, dryRun) {
|
|
|
247
85
|
};
|
|
248
86
|
}
|
|
249
87
|
if (target.kind === "file") {
|
|
250
|
-
await
|
|
88
|
+
await fs.unlink(absolutePath);
|
|
251
89
|
} else {
|
|
252
|
-
await
|
|
90
|
+
await fs.rm(absolutePath, { recursive: true, force: true });
|
|
253
91
|
}
|
|
254
92
|
const writeWarnings = await runActiveOnWriteHooks({
|
|
255
93
|
path: absolutePath,
|
|
@@ -261,7 +99,7 @@ async function removeCacheFile(pmRoot, target, dryRun) {
|
|
|
261
99
|
warnings: [...warnings, ...writeWarnings]
|
|
262
100
|
};
|
|
263
101
|
} catch (error) {
|
|
264
|
-
if (
|
|
102
|
+
if (isErrno(error, "ENOENT")) {
|
|
265
103
|
return {
|
|
266
104
|
removed: false,
|
|
267
105
|
warnings
|
|
@@ -365,6 +203,6 @@ async function runGc(global, options = {}) {
|
|
|
365
203
|
export {
|
|
366
204
|
runGc
|
|
367
205
|
};
|
|
368
|
-
//# sourceMappingURL=gc-
|
|
206
|
+
//# sourceMappingURL=gc-NRFHLVFT.js.map
|
|
369
207
|
|
|
370
|
-
//# debugId=
|
|
208
|
+
//# debugId=53de24e8-b5be-5de6-93ad-bdaa9f3015b0
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../../../../cli/commands/gc.ts"],"sourcesContent":["import fs from \"node:fs/promises\";\nimport path from \"node:path\";\nimport { runActiveOnIndexHooks, runActiveOnReadHooks, runActiveOnWriteHooks } from \"../../core/extensions/index.js\";\nimport { pathExists } from \"../../core/fs/fs-utils.js\";\nimport { runLockGc } from \"../../core/lock/lock-gc.js\";\nimport { EXIT_CODE } from \"../../core/shared/constants.js\";\nimport type { GlobalOptions } from \"../../core/shared/command-types.js\";\nimport { PmCliError } from \"../../core/shared/errors.js\";\nimport { nowIso } from \"../../core/shared/time.js\";\nimport { getSettingsPath, resolvePmRoot } from \"../../core/store/paths.js\";\nimport { readSettings } from \"../../core/store/settings.js\";\n\nconst GC_SCOPE_VALUES = [\"index\", \"embeddings\", \"runtime\", \"locks\"] as const;\ntype GcScope = (typeof GC_SCOPE_VALUES)[number];\n\ninterface GcTarget {\n scope: GcScope;\n relativePath: string;\n kind: \"file\" | \"directory\";\n}\n\nconst GC_TARGETS: readonly GcTarget[] = [\n {\n scope: \"index\",\n relativePath: \"index/manifest.json\",\n kind: \"file\",\n },\n {\n scope: \"embeddings\",\n relativePath: \"search/embeddings.jsonl\",\n kind: \"file\",\n },\n {\n scope: \"embeddings\",\n relativePath: \"search/vectorization-status.json\",\n kind: \"file\",\n },\n {\n scope: \"embeddings\",\n relativePath: \"search/lancedb\",\n kind: \"directory\",\n },\n {\n scope: \"runtime\",\n relativePath: \"runtime/test-runs\",\n kind: \"directory\",\n },\n {\n scope: \"runtime\",\n relativePath: \"runtime/history-drift-cache.json\",\n kind: \"file\",\n },\n] as const;\n\nexport interface GcCommandOptions {\n dryRun?: boolean;\n scope?: string[];\n}\n\nexport interface GcLocksSummary {\n scanned: number;\n removed: number;\n retained: number;\n}\n\nexport interface GcResult {\n ok: boolean;\n dry_run: boolean;\n scope: GcScope[];\n removed: string[];\n retained: string[];\n warnings: string[];\n guidance: string[];\n /** Present only when the locks scope was selected. Summarizes the stale-lock sweep. */\n locks?: GcLocksSummary;\n generated_at: string;\n}\n\nfunction isErrno(error: unknown, code: string): boolean {\n return typeof error === \"object\" && error !== null && \"code\" in error && (error as { code?: string }).code === code;\n}\n\nasync function removeCacheFile(\n pmRoot: string,\n target: GcTarget,\n dryRun: boolean,\n): Promise<{ removed: boolean; warnings: string[] }> {\n const relativePath = target.relativePath;\n const absolutePath = path.join(pmRoot, relativePath);\n const warnings = await runActiveOnReadHooks({\n path: absolutePath,\n scope: \"project\",\n });\n try {\n const stats = await fs.stat(absolutePath);\n if (target.kind === \"file\" && !stats.isFile()) {\n return {\n removed: false,\n warnings: [...warnings, `not_a_file:${relativePath}`],\n };\n }\n if (target.kind === \"directory\" && !stats.isDirectory()) {\n return {\n removed: false,\n warnings: [...warnings, `not_a_directory:${relativePath}`],\n };\n }\n if (dryRun) {\n return {\n removed: true,\n warnings,\n };\n }\n if (target.kind === \"file\") {\n await fs.unlink(absolutePath);\n } else {\n await fs.rm(absolutePath, { recursive: true, force: true });\n }\n const writeWarnings = await runActiveOnWriteHooks({\n path: absolutePath,\n scope: \"project\",\n op: \"gc:remove\",\n });\n return {\n removed: true,\n warnings: [...warnings, ...writeWarnings],\n };\n } catch (error: unknown) {\n if (isErrno(error, \"ENOENT\")) {\n return {\n removed: false,\n warnings,\n };\n }\n throw error;\n }\n}\n\nfunction parseScopes(raw: string[] | undefined): GcScope[] {\n if (!raw || raw.length === 0) {\n return [...GC_SCOPE_VALUES];\n }\n const tokens = raw\n .flatMap((entry) => entry.split(\",\"))\n .map((entry) => entry.trim().toLowerCase())\n .filter((entry) => entry.length > 0);\n if (tokens.length === 0) {\n throw new PmCliError(`--scope requires at least one value (${GC_SCOPE_VALUES.join(\",\")})`, EXIT_CODE.USAGE);\n }\n const resolved = new Set<GcScope>();\n for (const token of tokens) {\n if (!(GC_SCOPE_VALUES as readonly string[]).includes(token)) {\n throw new PmCliError(\n `Invalid --scope value \"${token}\". Expected one or more of: ${GC_SCOPE_VALUES.join(\", \")}`,\n EXIT_CODE.USAGE,\n );\n }\n resolved.add(token as GcScope);\n }\n return GC_SCOPE_VALUES.filter((scope) => resolved.has(scope));\n}\n\nfunction buildGcGuidance(params: {\n dryRun: boolean;\n scopes: GcScope[];\n removed: string[];\n}): string[] {\n const guidance: string[] = [];\n if (params.dryRun) {\n guidance.push(\"Dry-run preview only: no cache artifacts were deleted.\");\n }\n const searchScopeSelected = params.scopes.includes(\"index\") || params.scopes.includes(\"embeddings\");\n const searchArtifactsAffected = params.removed.some(\n (entry) =>\n entry === \"index/manifest.json\" ||\n entry === \"search/embeddings.jsonl\" ||\n entry === \"search/vectorization-status.json\" ||\n entry === \"search/lancedb\",\n );\n if (searchScopeSelected && searchArtifactsAffected) {\n guidance.push(\n 'Search artifacts were removed; run \"pm install search-advanced --project\" if reindex is unavailable, then \"pm reindex --mode keyword\" (and \"--mode semantic\" when semantic search is enabled) before search-heavy workflows.',\n );\n }\n if (params.removed.includes(\"runtime/history-drift-cache.json\")) {\n guidance.push('History drift cache was removed; the next \"pm health\" run performs a full history-drift re-scan.');\n }\n return guidance;\n}\n\nexport async function runGc(global: GlobalOptions, options: GcCommandOptions = {}): Promise<GcResult> {\n const pmRoot = resolvePmRoot(process.cwd(), global.path);\n if (!(await pathExists(getSettingsPath(pmRoot)))) {\n throw new PmCliError(`Tracker is not initialized at ${pmRoot}. Run pm init first.`, EXIT_CODE.NOT_FOUND);\n }\n\n await readSettings(pmRoot);\n const dryRun = options.dryRun === true;\n const scopes = parseScopes(options.scope);\n const selectedTargets = GC_TARGETS.filter((target) => scopes.includes(target.scope));\n\n const removed: string[] = [];\n const retained: string[] = [];\n const warnings: string[] = [];\n\n for (const target of selectedTargets) {\n const result = await removeCacheFile(pmRoot, target, dryRun);\n if (result.removed) {\n removed.push(target.relativePath);\n } else {\n retained.push(target.relativePath);\n }\n warnings.push(...result.warnings);\n }\n\n // The locks scope is not a path-based GC_TARGET: it sweeps the locks/ directory\n // and removes only locks whose own embedded ttl has expired (crashed-process\n // debris), retaining active and unparseable locks. See core/lock/lock-gc.ts.\n let locksSummary: GcLocksSummary | undefined;\n if (scopes.includes(\"locks\")) {\n const lockResult = await runLockGc(pmRoot, {\n dryRun,\n hooks: {\n onRead: (lockPath) => runActiveOnReadHooks({ path: lockPath, scope: \"project\" }),\n onWrite: (lockPath) => runActiveOnWriteHooks({ path: lockPath, scope: \"project\", op: \"gc:lock_remove\" }),\n },\n });\n removed.push(...lockResult.removed);\n retained.push(...lockResult.retained);\n warnings.push(...lockResult.warnings);\n locksSummary = {\n scanned: lockResult.scanned,\n removed: lockResult.removed.length,\n retained: lockResult.retained.length,\n };\n }\n\n warnings.push(\n ...(await runActiveOnIndexHooks({\n mode: dryRun ? \"gc:dry-run\" : \"gc\",\n total_items: selectedTargets.length,\n })),\n );\n const guidance = buildGcGuidance({\n dryRun,\n scopes,\n removed,\n });\n\n return {\n ok: warnings.length === 0,\n dry_run: dryRun,\n scope: scopes,\n removed,\n retained,\n warnings,\n ...(locksSummary ? { locks: locksSummary } : {}),\n guidance,\n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Q;MAC5B,UAAU,WAAW,SAAS;;EAElC;AAEA,WAAS,KACP,GAAI,MAAM,sBAAsB;IAC9B,MAAM,SAAS,eAAe;IAC9B,aAAa,gBAAgB;GAC9B,CAAE;AAEL,QAAM,WAAW,gBAAgB;IAC/B;IACA;IACA;GACD;AAED,SAAO;IACL,IAAI,SAAS,WAAW;IACxB,SAAS;IACT,OAAO;IACP;IACA;IACA;IACA,GAAI,eAAe,EAAE,OAAO,aAAY,IAAK,CAAA;IAC7C;IACA,cAAc,OAAM;;AAExB","debugId":"53de24e8-b5be-5de6-93ad-bdaa9f3015b0"}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import {
|
|
2
2
|
readHistoryEntries
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-GRZGHGRG.js";
|
|
4
|
+
import "./chunk-GOO4UXBI.js";
|
|
5
5
|
import {
|
|
6
6
|
parseIntegerLimit
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-VYZNX4C5.js";
|
|
8
8
|
import {
|
|
9
9
|
buildItemNotFoundError,
|
|
10
10
|
locateItem,
|
|
11
11
|
readLocatedItem,
|
|
12
12
|
toItemRecord
|
|
13
|
-
} from "./chunk-
|
|
14
|
-
import "./chunk-
|
|
15
|
-
import "./chunk-
|
|
13
|
+
} from "./chunk-XXLMJDUB.js";
|
|
14
|
+
import "./chunk-LGOXXQUW.js";
|
|
15
|
+
import "./chunk-MACCNKSZ.js";
|
|
16
16
|
import {
|
|
17
17
|
resolveItemTypeRegistry
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import "./chunk-
|
|
18
|
+
} from "./chunk-W6KNFAMZ.js";
|
|
19
|
+
import "./chunk-IXVSSHGV.js";
|
|
20
20
|
import {
|
|
21
21
|
EXIT_CODE,
|
|
22
22
|
FRONT_MATTER_KEY_ORDER,
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
readSettings,
|
|
29
29
|
resolvePmRoot,
|
|
30
30
|
resolveRuntimeFieldRegistry
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-LFW5NQUP.js";
|
|
32
32
|
|
|
33
33
|
// dist/cli/commands/get.js
|
|
34
34
|
!(function() {
|
|
@@ -196,7 +196,7 @@ async function runGet(id, global2, options = {}) {
|
|
|
196
196
|
result.claim_state = claimState;
|
|
197
197
|
}
|
|
198
198
|
if (options.tree === true) {
|
|
199
|
-
const { runList } = await import("./list-
|
|
199
|
+
const { runList } = await import("./list-VOQDQHA4.js");
|
|
200
200
|
const subtree = await runList(void 0, {
|
|
201
201
|
parent: located.id,
|
|
202
202
|
tree: true,
|
|
@@ -216,4 +216,4 @@ async function runGet(id, global2, options = {}) {
|
|
|
216
216
|
export {
|
|
217
217
|
runGet
|
|
218
218
|
};
|
|
219
|
-
//# sourceMappingURL=get-
|
|
219
|
+
//# sourceMappingURL=get-K7UULTQF.js.map
|
|
@@ -2,23 +2,23 @@
|
|
|
2
2
|
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="8d05da97-b537-5f04-9c8b-7b8ebdb34993")}catch(e){}}();
|
|
3
3
|
import {
|
|
4
4
|
readHistoryEntries
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-XWDZVCBJ.js";
|
|
6
|
+
import "./chunk-JE5IZXDS.js";
|
|
7
7
|
import {
|
|
8
8
|
parseIntegerLimit
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-NN6RKGFW.js";
|
|
10
10
|
import {
|
|
11
11
|
buildItemNotFoundError,
|
|
12
12
|
locateItem,
|
|
13
13
|
readLocatedItem,
|
|
14
14
|
toItemRecord
|
|
15
|
-
} from "./chunk-
|
|
16
|
-
import "./chunk-
|
|
17
|
-
import "./chunk-
|
|
15
|
+
} from "./chunk-L6YQONLM.js";
|
|
16
|
+
import "./chunk-6ZFTM65G.js";
|
|
17
|
+
import "./chunk-QQG4HEX7.js";
|
|
18
18
|
import {
|
|
19
19
|
resolveItemTypeRegistry
|
|
20
|
-
} from "./chunk-
|
|
21
|
-
import "./chunk-
|
|
20
|
+
} from "./chunk-32XSW44C.js";
|
|
21
|
+
import "./chunk-IZHCCG4S.js";
|
|
22
22
|
import {
|
|
23
23
|
EXIT_CODE,
|
|
24
24
|
FRONT_MATTER_KEY_ORDER,
|
|
@@ -30,7 +30,7 @@ import {
|
|
|
30
30
|
readSettings,
|
|
31
31
|
resolvePmRoot,
|
|
32
32
|
resolveRuntimeFieldRegistry
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-S2CDTRJ6.js";
|
|
34
34
|
|
|
35
35
|
// dist/cli/commands/get.js
|
|
36
36
|
var GET_DEPTH_VALUES = ["brief", "standard", "deep"];
|
|
@@ -191,7 +191,7 @@ async function runGet(id, global, options = {}) {
|
|
|
191
191
|
result.claim_state = claimState;
|
|
192
192
|
}
|
|
193
193
|
if (options.tree === true) {
|
|
194
|
-
const { runList } = await import("./list-
|
|
194
|
+
const { runList } = await import("./list-GGVPXEV6.js");
|
|
195
195
|
const subtree = await runList(void 0, {
|
|
196
196
|
parent: located.id,
|
|
197
197
|
tree: true,
|
|
@@ -211,6 +211,6 @@ async function runGet(id, global, options = {}) {
|
|
|
211
211
|
export {
|
|
212
212
|
runGet
|
|
213
213
|
};
|
|
214
|
-
//# sourceMappingURL=get-
|
|
214
|
+
//# sourceMappingURL=get-SAB7CRBG.js.map
|
|
215
215
|
|
|
216
216
|
//# debugId=8d05da97-b537-5f04-9c8b-7b8ebdb34993
|