autohand-cli 0.7.8 → 0.7.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -0
- package/dist/{AutomodeManager-YVCJXOMQ.js → AutomodeManager-NGRAO2MH.js} +35 -8
- package/dist/{AutomodeManager-HV6M7EAX.cjs → AutomodeManager-ZKQMBM4T.cjs} +35 -8
- package/dist/{CommunitySkillsCache-Q22FUAR5.js → CommunitySkillsCache-ILWHWE5P.js} +2 -2
- package/dist/CommunitySkillsCache-KHC6RUJW.cjs +7 -0
- package/dist/MemoryManager-6ZT7IDO5.cjs +7 -0
- package/dist/MemoryManager-AJGS5AKB.js +7 -0
- package/dist/PermissionManager-HG6W2DGU.cjs +10 -0
- package/dist/{PermissionManager-HATZKTRC.js → PermissionManager-U5OMGR3L.js} +3 -3
- package/dist/SessionManager-BJ2G6VV4.cjs +9 -0
- package/dist/{SessionManager-S5R6O3NU.js → SessionManager-ENPGYK5J.js} +2 -2
- package/dist/SkillsRegistry-6ZFOCT25.cjs +8 -0
- package/dist/{SkillsRegistry-R5WDM6T3.js → SkillsRegistry-C2SHOZ5D.js} +2 -2
- package/dist/{SyncApiClient-FAOMIZAP.js → SyncApiClient-AYXYSOJM.js} +1 -1
- package/dist/SyncApiClient-ID3KXEMA.cjs +10 -0
- package/dist/about-RGUM5QQ4.cjs +11 -0
- package/dist/about-VDR3SIHS.js +11 -0
- package/dist/add-dir-3BMVJ5H3.cjs +9 -0
- package/dist/{add-dir-PNU7AGKO.js → add-dir-RP2BL3JW.js} +2 -1
- package/dist/agents-JQ2PHCQB.js +10 -0
- package/dist/agents-RGSZ2BM3.cjs +10 -0
- package/dist/agents-new-LSJN2L2T.cjs +13 -0
- package/dist/agents-new-MZUEVKSK.js +13 -0
- package/dist/automode-DP3BMYJB.cjs +9 -0
- package/dist/{automode-QCRJSBRT.js → automode-XOF3U3OB.js} +2 -1
- package/dist/cc-2W6M7J45.cjs +8 -0
- package/dist/cc-UTTLESTY.js +8 -0
- package/dist/{chunk-B4ZPNXZE.cjs → chunk-34OGUMRO.cjs} +9 -5
- package/dist/chunk-3652ROFD.js +589 -0
- package/dist/{chunk-KNLBEUAV.cjs → chunk-3DQSBW4B.cjs} +10 -6
- package/dist/{chunk-XFPITUFJ.cjs → chunk-3S4DEIJP.cjs} +50 -8
- package/dist/{chunk-5MDDOGTD.cjs → chunk-3UNX56GC.cjs} +30 -37
- package/dist/chunk-46WX5IO2.cjs +499 -0
- package/dist/{chunk-OC5YDNFC.js → chunk-4ULBAYME.js} +42 -57
- package/dist/{chunk-VEDIYPWY.cjs → chunk-5BQ57AZC.cjs} +9 -9
- package/dist/{chunk-B5N5UAMO.cjs → chunk-5FZM7KLB.cjs} +13 -10
- package/dist/{chunk-JBKP2CLA.cjs → chunk-5NZA4UB4.cjs} +47 -47
- package/dist/{chunk-VPAN5H7Q.js → chunk-5Q3W4DEU.js} +43 -36
- package/dist/{chunk-VMMGT42E.cjs → chunk-65GTO4QM.cjs} +7 -3
- package/dist/{chunk-CXZEPTRI.js → chunk-6P3K4YUW.js} +6 -2
- package/dist/{chunk-MDWULS57.js → chunk-6UJMCWRY.js} +56 -33
- package/dist/chunk-73XIKTZL.js +124 -0
- package/dist/{chunk-23JQSCTO.js → chunk-7QNW24ZT.js} +8 -4
- package/dist/{chunk-XT4OSHSB.cjs → chunk-AEYOIPHD.cjs} +6 -2
- package/dist/chunk-ANUQFV43.cjs +589 -0
- package/dist/chunk-ATR3RORT.js +499 -0
- package/dist/{chunk-A6QBABQ7.js → chunk-B72CC4O6.js} +2 -2
- package/dist/{chunk-TAZJSKFD.js → chunk-BBIKQW66.js} +9 -5
- package/dist/{chunk-FFA4LDAO.cjs → chunk-BDIZGBDA.cjs} +8 -3
- package/dist/{chunk-3YEDXG6S.js → chunk-BG4OQUKP.js} +1 -1
- package/dist/{chunk-WIUGUR5T.js → chunk-BODVOW7B.js} +67 -16
- package/dist/{chunk-A552JHUJ.cjs → chunk-BZ73ZQTE.cjs} +34 -25
- package/dist/{chunk-YDOR2OCA.cjs → chunk-C22G4UE4.cjs} +27 -19
- package/dist/{chunk-GFJ6AETU.cjs → chunk-C2E3GJEE.cjs} +12 -9
- package/dist/{chunk-UL7YPRCU.js → chunk-C5SVIQG3.js} +10 -5
- package/dist/{chunk-6KMAJTU3.js → chunk-CUBYCLNL.js} +3 -2
- package/dist/{chunk-52MLYK5P.js → chunk-D2XFTCRP.js} +1 -1
- package/dist/{chunk-OBV3UUIL.js → chunk-DEAEO7RI.js} +1 -1
- package/dist/chunk-DMPVI3YK.cjs +400 -0
- package/dist/{chunk-C26EN22G.cjs → chunk-DUDDZRCS.cjs} +9 -5
- package/dist/{chunk-4RWTUT2Z.js → chunk-E7YL3AHT.js} +32 -23
- package/dist/{chunk-54GVL2SE.cjs → chunk-EAOEAQGF.cjs} +3 -2
- package/dist/{chunk-PU534KPO.cjs → chunk-EV53SLSB.cjs} +4 -4
- package/dist/{chunk-EDGV5BNH.js → chunk-F3EIOVSQ.js} +26 -33
- package/dist/{chunk-SFGJQPGC.cjs → chunk-FPHU2ES6.cjs} +56 -33
- package/dist/{chunk-G77ZY4QG.js → chunk-GD4AFYJ3.js} +1 -1
- package/dist/{chunk-PMMSDR44.cjs → chunk-GIZL57FE.cjs} +5 -1
- package/dist/{chunk-I4HVBWYF.js → chunk-GLAE5K5W.js} +7 -2
- package/dist/{chunk-4AMTDSQ3.cjs → chunk-HDSEJMWI.cjs} +6 -3
- package/dist/chunk-HLFZPN65.js +94 -0
- package/dist/{chunk-ZWS3KSMK.js → chunk-HQQ4NKER.js} +5 -2
- package/dist/{chunk-WBDPILKI.cjs → chunk-HVOBMOZ2.cjs} +6 -2
- package/dist/{chunk-MJFBVQHB.js → chunk-IPI3JXKP.js} +10 -7
- package/dist/chunk-IXFOH4OC.cjs +222 -0
- package/dist/chunk-JS7IPR7P.js +249 -0
- package/dist/{chunk-7TOHYAUF.cjs → chunk-KC5FPUOF.cjs} +2 -2
- package/dist/{chunk-7VW3A7DO.cjs → chunk-L42HTMMR.cjs} +2 -2
- package/dist/chunk-LGGZQTLM.cjs +209 -0
- package/dist/chunk-LOXOD4IS.cjs +8630 -0
- package/dist/chunk-MNCWB5F7.cjs +63 -0
- package/dist/{chunk-AVL4DKQO.js → chunk-MYNHJHDZ.js} +1 -1
- package/dist/{chunk-GDTZQSJ6.cjs → chunk-N4ZSG6JJ.cjs} +2 -2
- package/dist/chunk-NCC6ETZS.js +362 -0
- package/dist/chunk-NF7RIHJK.js +45 -0
- package/dist/{chunk-SYJLMBLP.cjs → chunk-NGBN2NGH.cjs} +77 -26
- package/dist/{chunk-SLISYSP4.cjs → chunk-NRORJRD4.cjs} +4 -4
- package/dist/{chunk-OTS4YFSZ.cjs → chunk-OKABWSWA.cjs} +7 -3
- package/dist/{chunk-KH7BCZJN.js → chunk-OLG7LZBD.js} +1 -1
- package/dist/{chunk-KZ7VMQTC.js → chunk-OMEH2EVE.js} +5 -1
- package/dist/{chunk-U5WIP4HS.js → chunk-P5VDZ6PV.js} +47 -5
- package/dist/{chunk-V5MTBGM4.cjs → chunk-PA2H2263.cjs} +6 -2
- package/dist/chunk-PGRH5Q77.cjs +249 -0
- package/dist/{chunk-DPJ3IIBB.js → chunk-PM62ZYXA.js} +18 -10
- package/dist/chunk-PNSRJT46.js +380 -0
- package/dist/{chunk-C3IFF3EH.cjs → chunk-PSED4Z4X.cjs} +43 -58
- package/dist/{chunk-EKY5PKQI.js → chunk-PWLLLJHU.js} +5 -1
- package/dist/{chunk-DOTAX65F.js → chunk-PYLR4J2D.js} +8 -4
- package/dist/{chunk-YWKZF2SA.js → chunk-QC6IUDDJ.js} +46 -46
- package/dist/{chunk-4M2GX7RH.cjs → chunk-QM7HZCQW.cjs} +11 -6
- package/dist/chunk-QRQ5EX7I.cjs +380 -0
- package/dist/{chunk-YDH2BMEN.js → chunk-QU64XI5X.js} +9 -6
- package/dist/{chunk-3L76MLO5.cjs → chunk-R7SDL3DJ.cjs} +27 -31
- package/dist/{chunk-WQSWU2QA.cjs → chunk-RJP3SZ7Q.cjs} +46 -255
- package/dist/{chunk-BAFJQUWR.js → chunk-RJXNNIFW.js} +18 -22
- package/dist/{chunk-YAGD43KA.cjs → chunk-S5G7OEN2.cjs} +47 -40
- package/dist/{chunk-2JPUEN44.cjs → chunk-SA4JOV4F.cjs} +61 -86
- package/dist/chunk-SAG6IY5Z.cjs +94 -0
- package/dist/chunk-TSV4LVHK.js +35 -0
- package/dist/{chunk-JHFH3N4U.cjs → chunk-TSY7JHIV.cjs} +2 -2
- package/dist/chunk-U23U52ZN.cjs +124 -0
- package/dist/chunk-UET7BDX2.js +8630 -0
- package/dist/chunk-ULQ6MDSJ.cjs +362 -0
- package/dist/{chunk-WH3D42BQ.js → chunk-UM4QEO36.js} +59 -84
- package/dist/chunk-VXCMGBXY.cjs +35 -0
- package/dist/chunk-WD5ZF6HE.js +63 -0
- package/dist/chunk-WH5RW7DV.cjs +85 -0
- package/dist/{chunk-GSOEIEOU.js → chunk-WJ276BIP.js} +5 -1
- package/dist/{chunk-P2Z6GDEN.js → chunk-WLTVF77A.js} +1 -1
- package/dist/{chunk-53BR4MUW.cjs → chunk-WOGJXDBU.cjs} +3 -3
- package/dist/{chunk-QJ53OSGF.js → chunk-WRJLBHWB.js} +6 -2
- package/dist/chunk-WYLFLZ42.js +222 -0
- package/dist/{chunk-B7EUETGY.cjs → chunk-XL77XYI2.cjs} +4 -4
- package/dist/{chunk-NI3BQXKU.js → chunk-XLI7SHCH.js} +2 -2
- package/dist/chunk-Y27LG4BQ.cjs +45 -0
- package/dist/chunk-Y6OWFIUF.js +209 -0
- package/dist/chunk-YKSSNFDZ.js +400 -0
- package/dist/{chunk-VRI7EXV6.js → chunk-YMDLUTF2.js} +5 -1
- package/dist/chunk-YVY27BJT.js +85 -0
- package/dist/{chunk-GWIAMKKF.js → chunk-ZBIBLOZL.js} +40 -249
- package/dist/completion-HVSWU5GR.cjs +13 -0
- package/dist/completion-WJ2MVNDH.js +13 -0
- package/dist/constants-RBQTR32A.cjs +20 -0
- package/dist/{constants-ZLG6M5SI.js → constants-V6J54N3X.js} +1 -1
- package/dist/export-NN7F5ANA.js +11 -0
- package/dist/export-UPS3AK2P.cjs +11 -0
- package/dist/feedback-ARI7CLVQ.js +14 -0
- package/dist/feedback-OZTPYHKJ.cjs +14 -0
- package/dist/help-4674IV4D.cjs +58 -0
- package/dist/help-ENG5KV2M.js +58 -0
- package/dist/history-2KUM6GN4.cjs +13 -0
- package/dist/history-RZFT34Q7.js +13 -0
- package/dist/hooks-7QSUBHBM.cjs +12 -0
- package/dist/hooks-S4MD4QSR.js +12 -0
- package/dist/i18n-6NKENUIV.js +32 -0
- package/dist/i18n-MXQXQOVE.cjs +32 -0
- package/dist/ide-5STDV43A.cjs +11 -0
- package/dist/ide-W2NYXOWQ.js +11 -0
- package/dist/index.cjs +18002 -13864
- package/dist/index.js +18252 -14114
- package/dist/init-FG5KEJCZ.cjs +9 -0
- package/dist/init-TV4MJDYK.js +9 -0
- package/dist/language-52Q7CSAY.cjs +16 -0
- package/dist/language-FXFDGOBF.js +16 -0
- package/dist/localProjectPermissions-2EATUDZM.cjs +17 -0
- package/dist/{localProjectPermissions-YFFAKLUZ.js → localProjectPermissions-WQYMGI42.js} +2 -2
- package/dist/login-AN42IOBK.js +18 -0
- package/dist/login-I65V4TGU.cjs +18 -0
- package/dist/logout-KK5UWGNG.js +16 -0
- package/dist/logout-VYYNWBHZ.cjs +16 -0
- package/dist/mcp-4SKTDECJ.js +15 -0
- package/dist/mcp-AGWPTMAX.cjs +15 -0
- package/dist/mcp-install-3NN2HAYR.cjs +473 -0
- package/dist/mcp-install-KTV52DQK.js +473 -0
- package/dist/memory-LG4K6XV6.cjs +9 -0
- package/dist/{memory-4GSP7NKV.js → memory-LRDK2SYC.js} +2 -1
- package/dist/model-P5D7ATE7.cjs +9 -0
- package/dist/{model-HKEFSH5E.js → model-WBFJIGUN.js} +2 -1
- package/dist/{new-EEZC4XXV.js → new-5A7RQEKI.js} +2 -1
- package/dist/new-EAATWI2G.cjs +9 -0
- package/dist/permissions-5URK6C44.js +12 -0
- package/dist/permissions-CJUDVG63.cjs +12 -0
- package/dist/plan-B3CW5DXJ.cjs +10 -0
- package/dist/plan-JFGNRL2S.js +10 -0
- package/dist/quit-A33JHDG7.cjs +9 -0
- package/dist/quit-IYBLN3DB.js +9 -0
- package/dist/resume-OPSJTCH7.cjs +12 -0
- package/dist/resume-TOWEEN5D.js +12 -0
- package/dist/search-GOLIE5BA.js +14 -0
- package/dist/search-H42HGUK5.cjs +14 -0
- package/dist/{sessions-4KXIT76T.js → sessions-B5NENDKY.js} +2 -1
- package/dist/sessions-YHAVEMWY.cjs +9 -0
- package/dist/share-2JD2AKKX.cjs +13 -0
- package/dist/share-MYGDOTQE.js +13 -0
- package/dist/{skills-3YEEODHK.js → skills-ICEQ2TNC.js} +2 -1
- package/dist/skills-LFVNZOMF.cjs +13 -0
- package/dist/{skills-install-KAXAQSN6.js → skills-install-6RN7FVCP.js} +9 -7
- package/dist/{skills-install-FTGOHOZ4.cjs → skills-install-LU6GA2WF.cjs} +14 -12
- package/dist/skills-new-5BM5PDFX.cjs +14 -0
- package/dist/skills-new-KWBWOX74.js +14 -0
- package/dist/status-M3XHJELG.cjs +10 -0
- package/dist/status-ZQDUYMKQ.js +10 -0
- package/dist/sync-6M3WRKMH.cjs +39 -0
- package/dist/sync-73D2MP65.cjs +16 -0
- package/dist/{sync-H4UHHLKU.js → sync-EXYX7HXW.js} +3 -3
- package/dist/sync-LL6M67CN.js +16 -0
- package/dist/theme-IFEI2IBJ.cjs +16 -0
- package/dist/theme-U3SKEULY.js +16 -0
- package/dist/ui/questionModal.cjs +28 -0
- package/dist/ui/questionModal.d.cts +11 -0
- package/dist/ui/questionModal.d.ts +11 -0
- package/dist/ui/questionModal.js +28 -0
- package/dist/undo-4DS67OAW.cjs +9 -0
- package/dist/undo-YMALVAPN.js +9 -0
- package/package.json +3 -2
- package/dist/CommunitySkillsCache-2BITCEAA.cjs +0 -7
- package/dist/MemoryManager-2ATHG7BH.js +0 -7
- package/dist/MemoryManager-AENCGCEW.cjs +0 -7
- package/dist/PermissionManager-6HZGTK2N.cjs +0 -10
- package/dist/SessionManager-AG4WT3DP.cjs +0 -9
- package/dist/SkillsRegistry-ZXU6YDRP.cjs +0 -8
- package/dist/SyncApiClient-UOA4VLLD.cjs +0 -10
- package/dist/add-dir-OMK3Y4DM.cjs +0 -8
- package/dist/agents-ICAC3KD3.js +0 -9
- package/dist/agents-YONWPKFS.cjs +0 -9
- package/dist/agents-new-NV557UVG.cjs +0 -10
- package/dist/agents-new-QHM3CO4B.js +0 -10
- package/dist/automode-BRHUHGXU.cjs +0 -8
- package/dist/chunk-3HPUOQJN.cjs +0 -23
- package/dist/chunk-5DN5KNXU.js +0 -81
- package/dist/chunk-7BYSXAKS.js +0 -23
- package/dist/chunk-ARVFUZOB.js +0 -736
- package/dist/chunk-BEIG7V7Q.cjs +0 -51
- package/dist/chunk-GWXXFQ3F.cjs +0 -81
- package/dist/chunk-XFQS2VGT.cjs +0 -736
- package/dist/chunk-Z3Q2AFDS.js +0 -51
- package/dist/completion-WVFWX7XQ.cjs +0 -10
- package/dist/completion-Y42FKDT3.js +0 -10
- package/dist/constants-G2PLP5HH.cjs +0 -20
- package/dist/export-BKBJ7PB2.cjs +0 -8
- package/dist/export-WJ5P6E5Z.js +0 -8
- package/dist/feedback-HZBCTSFG.js +0 -10
- package/dist/feedback-JBQ3UPGZ.cjs +0 -10
- package/dist/help-PKC6QCNG.js +0 -10
- package/dist/help-UEELQRHP.cjs +0 -10
- package/dist/hooks-G4VLYMLX.cjs +0 -9
- package/dist/hooks-LN4A6NQL.js +0 -9
- package/dist/init-DML7AOII.js +0 -8
- package/dist/init-SLLSDDJN.cjs +0 -8
- package/dist/language-KODBDE5R.js +0 -12
- package/dist/language-SJT475NW.cjs +0 -12
- package/dist/localProjectPermissions-AYQYGTOE.cjs +0 -17
- package/dist/login-TC2KROQI.js +0 -14
- package/dist/login-TYMR2ZD3.cjs +0 -14
- package/dist/logout-2ECV365P.js +0 -12
- package/dist/logout-CO3CPYZJ.cjs +0 -12
- package/dist/memory-CFNC7RJH.cjs +0 -8
- package/dist/model-TKVEJ5BC.cjs +0 -8
- package/dist/new-EB2MBQXA.cjs +0 -8
- package/dist/permissions-5MTH22EF.js +0 -9
- package/dist/permissions-IP5SITPI.cjs +0 -9
- package/dist/quit-2RYFGIJP.cjs +0 -8
- package/dist/quit-RSYIERO5.js +0 -8
- package/dist/resume-EPOEF3WV.cjs +0 -9
- package/dist/resume-LOYD5MMP.js +0 -9
- package/dist/sessions-7RTCPVNE.cjs +0 -8
- package/dist/share-APR5S2CS.cjs +0 -10
- package/dist/share-VLJFDZKR.js +0 -10
- package/dist/skills-CRM55MKM.cjs +0 -12
- package/dist/skills-new-JF4FKNUT.cjs +0 -11
- package/dist/skills-new-JYX2GBKM.js +0 -11
- package/dist/status-DAEFE7ZC.cjs +0 -9
- package/dist/status-PBFFUC4Q.js +0 -9
- package/dist/sync-3B7SNBYC.js +0 -14
- package/dist/sync-4RARBQIH.cjs +0 -39
- package/dist/sync-YZ6YZ42H.cjs +0 -14
- package/dist/theme-3XV5BWUB.js +0 -12
- package/dist/theme-Z2WS5XWZ.cjs +0 -12
- package/dist/undo-2WR2ZIEC.cjs +0 -8
- package/dist/undo-7QJBXARS.js +0 -8
|
@@ -0,0 +1,499 @@
|
|
|
1
|
+
import {
|
|
2
|
+
showModal
|
|
3
|
+
} from "./chunk-PNSRJT46.js";
|
|
4
|
+
import {
|
|
5
|
+
t
|
|
6
|
+
} from "./chunk-UET7BDX2.js";
|
|
7
|
+
|
|
8
|
+
// src/commands/ide.ts
|
|
9
|
+
import chalk from "chalk";
|
|
10
|
+
import terminalLink from "terminal-link";
|
|
11
|
+
|
|
12
|
+
// src/core/ide/ideDetector.ts
|
|
13
|
+
import { exec } from "child_process";
|
|
14
|
+
import os from "os";
|
|
15
|
+
import path from "path";
|
|
16
|
+
|
|
17
|
+
// src/core/ide/ideTypes.ts
|
|
18
|
+
var IDE_REGISTRY = [
|
|
19
|
+
{
|
|
20
|
+
kind: "vscode",
|
|
21
|
+
displayName: "Visual Studio Code",
|
|
22
|
+
processPatterns: {
|
|
23
|
+
darwin: ["Visual Studio Code", "code "],
|
|
24
|
+
linux: ["code ", "/code"],
|
|
25
|
+
win32: ["Code.exe"]
|
|
26
|
+
},
|
|
27
|
+
extensionUrl: "https://marketplace.visualstudio.com/items?itemName=AutohandAI.vscode-autohand",
|
|
28
|
+
storage: {
|
|
29
|
+
type: "vscode-family",
|
|
30
|
+
darwin: "Code",
|
|
31
|
+
linux: "Code",
|
|
32
|
+
win32: "Code"
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
kind: "vscode-insiders",
|
|
37
|
+
displayName: "Visual Studio Code Insiders",
|
|
38
|
+
processPatterns: {
|
|
39
|
+
darwin: ["Code - Insiders", "code-insiders "],
|
|
40
|
+
linux: ["code-insiders ", "/code-insiders"],
|
|
41
|
+
win32: ["Code - Insiders.exe"]
|
|
42
|
+
},
|
|
43
|
+
extensionUrl: "https://marketplace.visualstudio.com/items?itemName=AutohandAI.vscode-autohand",
|
|
44
|
+
storage: {
|
|
45
|
+
type: "vscode-family",
|
|
46
|
+
darwin: "Code - Insiders",
|
|
47
|
+
linux: "Code - Insiders",
|
|
48
|
+
win32: "Code - Insiders"
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
kind: "cursor",
|
|
53
|
+
displayName: "Cursor",
|
|
54
|
+
processPatterns: {
|
|
55
|
+
darwin: ["Cursor.app", "cursor "],
|
|
56
|
+
linux: ["cursor ", "/cursor"],
|
|
57
|
+
win32: ["Cursor.exe"]
|
|
58
|
+
},
|
|
59
|
+
storage: {
|
|
60
|
+
type: "vscode-family",
|
|
61
|
+
darwin: "Cursor",
|
|
62
|
+
linux: "Cursor",
|
|
63
|
+
win32: "Cursor"
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
kind: "zed",
|
|
68
|
+
displayName: "Zed",
|
|
69
|
+
processPatterns: {
|
|
70
|
+
darwin: ["Zed.app", "/zed "],
|
|
71
|
+
linux: ["zed ", "/zed"],
|
|
72
|
+
win32: ["Zed.exe"]
|
|
73
|
+
},
|
|
74
|
+
extensionUrl: "https://zed.dev/extensions/autohand-acp",
|
|
75
|
+
storage: {
|
|
76
|
+
type: "zed",
|
|
77
|
+
darwin: "Zed",
|
|
78
|
+
linux: "zed",
|
|
79
|
+
win32: "Zed"
|
|
80
|
+
}
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
kind: "antigravity",
|
|
84
|
+
displayName: "Antigravity",
|
|
85
|
+
processPatterns: {
|
|
86
|
+
darwin: ["Antigravity.app", "antigravity "],
|
|
87
|
+
linux: [],
|
|
88
|
+
win32: []
|
|
89
|
+
},
|
|
90
|
+
storage: {
|
|
91
|
+
type: "vscode-family",
|
|
92
|
+
darwin: "Antigravity"
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
];
|
|
96
|
+
|
|
97
|
+
// src/core/ide/ideDetector.ts
|
|
98
|
+
async function detectRunningIDEs(cwd) {
|
|
99
|
+
const platform = getCurrentPlatform();
|
|
100
|
+
const normalizedCwd = path.resolve(cwd);
|
|
101
|
+
const processLines = await getProcessList(platform);
|
|
102
|
+
const detected = [];
|
|
103
|
+
for (const entry of IDE_REGISTRY) {
|
|
104
|
+
const patterns = entry.processPatterns[platform] ?? [];
|
|
105
|
+
if (patterns.length === 0) continue;
|
|
106
|
+
const matchingLines = findProcessLines(processLines, patterns);
|
|
107
|
+
if (matchingLines.length === 0) continue;
|
|
108
|
+
const argPaths = extractWorkspacePaths(matchingLines, entry.kind, platform);
|
|
109
|
+
if (argPaths.length > 0) {
|
|
110
|
+
const seen = /* @__PURE__ */ new Set();
|
|
111
|
+
for (const wsPath of argPaths) {
|
|
112
|
+
const resolvedWs = path.resolve(wsPath);
|
|
113
|
+
if (seen.has(resolvedWs)) continue;
|
|
114
|
+
seen.add(resolvedWs);
|
|
115
|
+
detected.push({
|
|
116
|
+
kind: entry.kind,
|
|
117
|
+
displayName: entry.displayName,
|
|
118
|
+
workspacePath: resolvedWs,
|
|
119
|
+
matchesCwd: pathMatchesCwd(normalizedCwd, resolvedWs, platform),
|
|
120
|
+
extensionUrl: entry.extensionUrl
|
|
121
|
+
});
|
|
122
|
+
}
|
|
123
|
+
} else {
|
|
124
|
+
const cwdFoundInStorage = await checkCwdInStorage(entry, normalizedCwd, platform);
|
|
125
|
+
detected.push({
|
|
126
|
+
kind: entry.kind,
|
|
127
|
+
displayName: entry.displayName,
|
|
128
|
+
workspacePath: cwdFoundInStorage ? normalizedCwd : null,
|
|
129
|
+
matchesCwd: cwdFoundInStorage,
|
|
130
|
+
extensionUrl: entry.extensionUrl
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
detected.sort((a, b) => {
|
|
135
|
+
if (a.matchesCwd && !b.matchesCwd) return -1;
|
|
136
|
+
if (!a.matchesCwd && b.matchesCwd) return 1;
|
|
137
|
+
return a.displayName.localeCompare(b.displayName);
|
|
138
|
+
});
|
|
139
|
+
return detected;
|
|
140
|
+
}
|
|
141
|
+
function getCurrentPlatform() {
|
|
142
|
+
return process.platform;
|
|
143
|
+
}
|
|
144
|
+
function pathMatchesCwd(normalizedCwd, workspacePath, platform) {
|
|
145
|
+
if (platform === "linux") {
|
|
146
|
+
return normalizedCwd === workspacePath;
|
|
147
|
+
}
|
|
148
|
+
return normalizedCwd.toLowerCase() === workspacePath.toLowerCase();
|
|
149
|
+
}
|
|
150
|
+
async function getProcessList(platform) {
|
|
151
|
+
if (platform === "win32") {
|
|
152
|
+
return getWindowsProcessList();
|
|
153
|
+
}
|
|
154
|
+
return getUnixProcessList();
|
|
155
|
+
}
|
|
156
|
+
async function getUnixProcessList() {
|
|
157
|
+
return new Promise((resolve) => {
|
|
158
|
+
exec("ps aux", { encoding: "utf-8", timeout: 5e3 }, (error, stdout) => {
|
|
159
|
+
if (error) {
|
|
160
|
+
resolve([]);
|
|
161
|
+
return;
|
|
162
|
+
}
|
|
163
|
+
resolve(stdout.split("\n"));
|
|
164
|
+
});
|
|
165
|
+
});
|
|
166
|
+
}
|
|
167
|
+
async function getWindowsProcessList() {
|
|
168
|
+
return new Promise((resolve) => {
|
|
169
|
+
const cmd = 'powershell -NoProfile -Command "Get-CimInstance Win32_Process | Select-Object Name,CommandLine | ConvertTo-Json"';
|
|
170
|
+
exec(cmd, { encoding: "utf-8", timeout: 8e3 }, (error, stdout) => {
|
|
171
|
+
if (error) {
|
|
172
|
+
resolve([]);
|
|
173
|
+
return;
|
|
174
|
+
}
|
|
175
|
+
try {
|
|
176
|
+
const processes = JSON.parse(stdout);
|
|
177
|
+
const lines = (Array.isArray(processes) ? processes : [processes]).map(
|
|
178
|
+
(p) => `${p.Name ?? ""} ${p.CommandLine ?? ""}`
|
|
179
|
+
);
|
|
180
|
+
resolve(lines);
|
|
181
|
+
} catch {
|
|
182
|
+
resolve([]);
|
|
183
|
+
}
|
|
184
|
+
});
|
|
185
|
+
});
|
|
186
|
+
}
|
|
187
|
+
function findProcessLines(lines, patterns) {
|
|
188
|
+
return lines.filter(
|
|
189
|
+
(line) => patterns.some((pattern) => line.includes(pattern))
|
|
190
|
+
);
|
|
191
|
+
}
|
|
192
|
+
function extractWorkspacePaths(lines, kind, platform) {
|
|
193
|
+
const paths = /* @__PURE__ */ new Set();
|
|
194
|
+
for (const line of lines) {
|
|
195
|
+
const folderUriMatch = line.match(/--folder-uri\s+file:\/\/([^\s]+)/);
|
|
196
|
+
if (folderUriMatch?.[1]) {
|
|
197
|
+
try {
|
|
198
|
+
const decoded = decodeURIComponent(folderUriMatch[1]);
|
|
199
|
+
if (!isRuntimePath(decoded, platform)) {
|
|
200
|
+
paths.add(decoded);
|
|
201
|
+
}
|
|
202
|
+
continue;
|
|
203
|
+
} catch {
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
const extractedPaths = extractPathsFromArgs(line, kind, platform);
|
|
207
|
+
for (const p of extractedPaths) {
|
|
208
|
+
paths.add(p);
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
return [...paths];
|
|
212
|
+
}
|
|
213
|
+
function extractPathsFromArgs(line, _kind, platform) {
|
|
214
|
+
const results = [];
|
|
215
|
+
let pathMatches;
|
|
216
|
+
if (platform === "win32") {
|
|
217
|
+
pathMatches = line.match(/\s([A-Za-z]:\\[^\s"]+)/g);
|
|
218
|
+
} else {
|
|
219
|
+
pathMatches = line.match(/\s(\/(?:Users|home|root)[^\s]+)/g);
|
|
220
|
+
}
|
|
221
|
+
if (!pathMatches) return results;
|
|
222
|
+
for (const match of pathMatches) {
|
|
223
|
+
const candidate = match.trim();
|
|
224
|
+
if (isRuntimePath(candidate, platform)) continue;
|
|
225
|
+
if (looksLikeWorkspace(candidate, platform)) {
|
|
226
|
+
results.push(candidate);
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
return results;
|
|
230
|
+
}
|
|
231
|
+
function isRuntimePath(p, platform) {
|
|
232
|
+
const plat = platform ?? getCurrentPlatform();
|
|
233
|
+
const commonPatterns = [
|
|
234
|
+
"node_modules",
|
|
235
|
+
".vscode",
|
|
236
|
+
".cursor",
|
|
237
|
+
"Frameworks/",
|
|
238
|
+
"Helper",
|
|
239
|
+
"Crashpad",
|
|
240
|
+
"chrome-sandbox",
|
|
241
|
+
".log",
|
|
242
|
+
".sock",
|
|
243
|
+
".pid"
|
|
244
|
+
];
|
|
245
|
+
const unixPatterns = [
|
|
246
|
+
"/Applications/",
|
|
247
|
+
"/Library/",
|
|
248
|
+
"/System/",
|
|
249
|
+
"/usr/",
|
|
250
|
+
"/opt/",
|
|
251
|
+
"/tmp/",
|
|
252
|
+
"/var/",
|
|
253
|
+
"/private/",
|
|
254
|
+
"/.local/share/",
|
|
255
|
+
"/.config/",
|
|
256
|
+
"/.cache/",
|
|
257
|
+
".app/",
|
|
258
|
+
"MacOS/",
|
|
259
|
+
"Resources/"
|
|
260
|
+
];
|
|
261
|
+
const windowsPatterns = [
|
|
262
|
+
"Program Files",
|
|
263
|
+
"Program Files (x86)",
|
|
264
|
+
"\\Windows\\",
|
|
265
|
+
"\\AppData\\",
|
|
266
|
+
"\\ProgramData\\"
|
|
267
|
+
];
|
|
268
|
+
const patterns = [
|
|
269
|
+
...commonPatterns,
|
|
270
|
+
...plat === "win32" ? windowsPatterns : unixPatterns
|
|
271
|
+
];
|
|
272
|
+
return patterns.some((pattern) => p.includes(pattern));
|
|
273
|
+
}
|
|
274
|
+
function looksLikeWorkspace(p, platform) {
|
|
275
|
+
const plat = platform ?? getCurrentPlatform();
|
|
276
|
+
if (plat === "win32") {
|
|
277
|
+
return /^[A-Za-z]:\\Users\\[^\\]+\\.+/.test(p);
|
|
278
|
+
}
|
|
279
|
+
return /^\/(Users|home)\/[^/]+\/.+/.test(p) || /^\/root\/.+/.test(p);
|
|
280
|
+
}
|
|
281
|
+
function getStorageBasePath(type, platform) {
|
|
282
|
+
const home = os.homedir();
|
|
283
|
+
switch (platform) {
|
|
284
|
+
case "darwin":
|
|
285
|
+
return path.join(home, "Library", "Application Support");
|
|
286
|
+
case "linux":
|
|
287
|
+
if (type === "zed") {
|
|
288
|
+
return process.env["XDG_DATA_HOME"] ?? path.join(home, ".local", "share");
|
|
289
|
+
}
|
|
290
|
+
return process.env["XDG_CONFIG_HOME"] ?? path.join(home, ".config");
|
|
291
|
+
case "win32":
|
|
292
|
+
if (type === "zed") {
|
|
293
|
+
return process.env["LOCALAPPDATA"] ?? path.join(home, "AppData", "Local");
|
|
294
|
+
}
|
|
295
|
+
return process.env["APPDATA"] ?? path.join(home, "AppData", "Roaming");
|
|
296
|
+
default:
|
|
297
|
+
return path.join(home, ".config");
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
async function checkCwdInStorage(entry, normalizedCwd, platform) {
|
|
301
|
+
const storageName = entry.storage?.[platform];
|
|
302
|
+
if (!storageName || !entry.storage) return false;
|
|
303
|
+
try {
|
|
304
|
+
if (entry.storage.type === "zed") {
|
|
305
|
+
return await checkZedStorage(storageName, normalizedCwd, platform);
|
|
306
|
+
}
|
|
307
|
+
return await checkVSCodeFamilyStorage(storageName, normalizedCwd, platform);
|
|
308
|
+
} catch {
|
|
309
|
+
return false;
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
async function checkVSCodeFamilyStorage(storageName, normalizedCwd, platform) {
|
|
313
|
+
const basePath = getStorageBasePath("vscode-family", platform);
|
|
314
|
+
const dbPath = path.join(basePath, storageName, "User", "globalStorage", "state.vscdb");
|
|
315
|
+
const raw = await querySqlite(
|
|
316
|
+
dbPath,
|
|
317
|
+
"SELECT value FROM ItemTable WHERE key = 'history.recentlyOpenedPathsList'"
|
|
318
|
+
);
|
|
319
|
+
if (!raw) return false;
|
|
320
|
+
try {
|
|
321
|
+
const data = JSON.parse(raw);
|
|
322
|
+
for (const entry of data.entries ?? []) {
|
|
323
|
+
if (!entry.folderUri) continue;
|
|
324
|
+
try {
|
|
325
|
+
const url = new URL(entry.folderUri);
|
|
326
|
+
if (url.protocol === "file:") {
|
|
327
|
+
const folder = path.resolve(decodeURIComponent(url.pathname));
|
|
328
|
+
if (pathMatchesCwd(normalizedCwd, folder, platform)) return true;
|
|
329
|
+
}
|
|
330
|
+
} catch {
|
|
331
|
+
}
|
|
332
|
+
}
|
|
333
|
+
return false;
|
|
334
|
+
} catch {
|
|
335
|
+
return false;
|
|
336
|
+
}
|
|
337
|
+
}
|
|
338
|
+
async function checkZedStorage(storageName, normalizedCwd, platform) {
|
|
339
|
+
const basePath = getStorageBasePath("zed", platform);
|
|
340
|
+
const dbPath = path.join(basePath, storageName, "db", "0-stable", "db.sqlite");
|
|
341
|
+
const escaped = normalizedCwd.replace(/'/g, "''");
|
|
342
|
+
const raw = await querySqlite(
|
|
343
|
+
dbPath,
|
|
344
|
+
`SELECT COUNT(*) FROM workspaces WHERE paths IS NOT NULL AND paths = '${escaped}'`
|
|
345
|
+
);
|
|
346
|
+
return raw !== null && raw.trim() !== "0";
|
|
347
|
+
}
|
|
348
|
+
async function querySqlite(dbPath, query) {
|
|
349
|
+
return new Promise((resolve) => {
|
|
350
|
+
exec(
|
|
351
|
+
`sqlite3 -readonly "${dbPath}" "${query}"`,
|
|
352
|
+
{ encoding: "utf-8", timeout: 3e3 },
|
|
353
|
+
(error, stdout) => {
|
|
354
|
+
if (error) {
|
|
355
|
+
resolve(null);
|
|
356
|
+
return;
|
|
357
|
+
}
|
|
358
|
+
const trimmed = stdout.trim();
|
|
359
|
+
resolve(trimmed.length > 0 ? trimmed : null);
|
|
360
|
+
}
|
|
361
|
+
);
|
|
362
|
+
});
|
|
363
|
+
}
|
|
364
|
+
function getExtensionSuggestions(detected) {
|
|
365
|
+
const detectedKinds = new Set(detected.map((d) => d.kind));
|
|
366
|
+
const seen = /* @__PURE__ */ new Set();
|
|
367
|
+
const suggestions = [];
|
|
368
|
+
for (const entry of IDE_REGISTRY) {
|
|
369
|
+
if (!entry.extensionUrl) continue;
|
|
370
|
+
if (!detectedKinds.has(entry.kind)) continue;
|
|
371
|
+
if (seen.has(entry.extensionUrl)) continue;
|
|
372
|
+
seen.add(entry.extensionUrl);
|
|
373
|
+
suggestions.push({
|
|
374
|
+
displayName: entry.displayName,
|
|
375
|
+
url: entry.extensionUrl
|
|
376
|
+
});
|
|
377
|
+
}
|
|
378
|
+
return suggestions;
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
// src/commands/ide.ts
|
|
382
|
+
function groupByIDE(detected) {
|
|
383
|
+
const matching = [];
|
|
384
|
+
const matchedKinds = /* @__PURE__ */ new Set();
|
|
385
|
+
const nonMatching = /* @__PURE__ */ new Map();
|
|
386
|
+
for (const ide2 of detected) {
|
|
387
|
+
if (ide2.matchesCwd) {
|
|
388
|
+
matching.push(ide2);
|
|
389
|
+
matchedKinds.add(ide2.kind);
|
|
390
|
+
}
|
|
391
|
+
}
|
|
392
|
+
for (const ide2 of detected) {
|
|
393
|
+
if (matchedKinds.has(ide2.kind)) continue;
|
|
394
|
+
if (nonMatching.has(ide2.kind)) continue;
|
|
395
|
+
nonMatching.set(ide2.kind, ide2);
|
|
396
|
+
}
|
|
397
|
+
return { matching, nonMatching };
|
|
398
|
+
}
|
|
399
|
+
async function ide(ctx) {
|
|
400
|
+
console.log(chalk.bold.cyan(`
|
|
401
|
+
${t("commands.ide.title")}`));
|
|
402
|
+
console.log(chalk.gray(t("commands.ide.connectDescription")));
|
|
403
|
+
console.log();
|
|
404
|
+
const detected = await detectRunningIDEs(ctx.workspaceRoot);
|
|
405
|
+
const { matching, nonMatching } = groupByIDE(detected);
|
|
406
|
+
if (detected.length === 0) {
|
|
407
|
+
console.log(chalk.yellow(t("commands.ide.noIdesDetected")));
|
|
408
|
+
console.log();
|
|
409
|
+
printExtensionSuggestions(detected);
|
|
410
|
+
return null;
|
|
411
|
+
}
|
|
412
|
+
if (matching.length === 0) {
|
|
413
|
+
console.log(chalk.yellow(t("commands.ide.noMatchingIdes")));
|
|
414
|
+
console.log();
|
|
415
|
+
if (nonMatching.size > 0) {
|
|
416
|
+
console.log(
|
|
417
|
+
chalk.gray(
|
|
418
|
+
t("commands.ide.otherNotMatching", { count: String(nonMatching.size) })
|
|
419
|
+
)
|
|
420
|
+
);
|
|
421
|
+
console.log();
|
|
422
|
+
printNonMatchingIDEs([...nonMatching.values()]);
|
|
423
|
+
}
|
|
424
|
+
printExtensionSuggestions(detected);
|
|
425
|
+
return null;
|
|
426
|
+
}
|
|
427
|
+
console.log(
|
|
428
|
+
chalk.green(
|
|
429
|
+
t("commands.ide.foundMatching", { count: String(matching.length) })
|
|
430
|
+
)
|
|
431
|
+
);
|
|
432
|
+
console.log();
|
|
433
|
+
const options = matching.map((ide2) => ({
|
|
434
|
+
label: `${ide2.displayName}: ${ide2.workspacePath ?? t("common.unknown")}`,
|
|
435
|
+
value: ide2.kind
|
|
436
|
+
}));
|
|
437
|
+
const result = await showModal({
|
|
438
|
+
title: t("commands.ide.selectPrompt"),
|
|
439
|
+
options
|
|
440
|
+
});
|
|
441
|
+
if (!result) {
|
|
442
|
+
console.log(chalk.gray(`
|
|
443
|
+
${t("common.cancelled")}`));
|
|
444
|
+
return null;
|
|
445
|
+
}
|
|
446
|
+
const selected = matching.find((d) => d.kind === result.value);
|
|
447
|
+
if (selected) {
|
|
448
|
+
console.log(
|
|
449
|
+
chalk.green(
|
|
450
|
+
`
|
|
451
|
+
\u2713 ${t("commands.ide.connected", { ide: selected.displayName })}`
|
|
452
|
+
)
|
|
453
|
+
);
|
|
454
|
+
}
|
|
455
|
+
if (nonMatching.size > 0) {
|
|
456
|
+
console.log();
|
|
457
|
+
console.log(
|
|
458
|
+
chalk.gray(
|
|
459
|
+
t("commands.ide.otherNotMatching", { count: String(nonMatching.size) })
|
|
460
|
+
)
|
|
461
|
+
);
|
|
462
|
+
console.log();
|
|
463
|
+
printNonMatchingIDEs([...nonMatching.values()]);
|
|
464
|
+
}
|
|
465
|
+
printExtensionSuggestions(detected);
|
|
466
|
+
return null;
|
|
467
|
+
}
|
|
468
|
+
function printNonMatchingIDEs(ides) {
|
|
469
|
+
for (const ide2 of ides) {
|
|
470
|
+
const wsPath = ide2.workspacePath ?? t("common.unknown");
|
|
471
|
+
console.log(chalk.gray(` \u2022 ${ide2.displayName}: ${wsPath}`));
|
|
472
|
+
}
|
|
473
|
+
console.log();
|
|
474
|
+
}
|
|
475
|
+
function printExtensionSuggestions(detected) {
|
|
476
|
+
const suggestions = getExtensionSuggestions(detected);
|
|
477
|
+
if (suggestions.length === 0) return;
|
|
478
|
+
console.log(chalk.dim(`\u{1F4A1} ${t("commands.ide.extensionHint")}`));
|
|
479
|
+
for (const suggestion of suggestions) {
|
|
480
|
+
const link = terminalLink(suggestion.url, suggestion.url);
|
|
481
|
+
console.log(chalk.dim(` \u2022 ${suggestion.displayName}: ${link}`));
|
|
482
|
+
}
|
|
483
|
+
console.log();
|
|
484
|
+
}
|
|
485
|
+
var metadata = {
|
|
486
|
+
command: "/ide",
|
|
487
|
+
description: t("commands.ide.description"),
|
|
488
|
+
implemented: true
|
|
489
|
+
};
|
|
490
|
+
|
|
491
|
+
export {
|
|
492
|
+
ide,
|
|
493
|
+
metadata
|
|
494
|
+
};
|
|
495
|
+
/**
|
|
496
|
+
* @license
|
|
497
|
+
* Copyright 2025 Autohand AI LLC
|
|
498
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
499
|
+
*/
|
|
@@ -3,10 +3,10 @@ import {
|
|
|
3
3
|
} from "./chunk-QHPFA6OE.js";
|
|
4
4
|
import {
|
|
5
5
|
safePrompt
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-WD5ZF6HE.js";
|
|
7
7
|
import {
|
|
8
8
|
AUTOHAND_PATHS
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-PWLLLJHU.js";
|
|
10
10
|
|
|
11
11
|
// src/commands/skills-new.ts
|
|
12
12
|
import path from "path";
|
|
@@ -1,12 +1,16 @@
|
|
|
1
|
+
import {
|
|
2
|
+
t
|
|
3
|
+
} from "./chunk-UET7BDX2.js";
|
|
4
|
+
|
|
1
5
|
// src/commands/memory.ts
|
|
2
6
|
import chalk from "chalk";
|
|
3
7
|
async function memory(ctx) {
|
|
4
8
|
const { project, user } = await ctx.memoryManager.listAll();
|
|
5
9
|
console.log();
|
|
6
|
-
console.log(chalk.bold.cyan("
|
|
10
|
+
console.log(chalk.bold.cyan(t("commands.memory.title")));
|
|
7
11
|
console.log(chalk.gray("\u2500".repeat(50)));
|
|
8
12
|
if (project.length === 0 && user.length === 0) {
|
|
9
|
-
console.log(chalk.gray("
|
|
13
|
+
console.log(chalk.gray(t("commands.memory.noMemory")));
|
|
10
14
|
console.log();
|
|
11
15
|
console.log(chalk.gray("Tip: Type # followed by text to store a memory."));
|
|
12
16
|
console.log(chalk.gray("Example: # Always use TypeScript strict mode"));
|
|
@@ -14,7 +18,7 @@ async function memory(ctx) {
|
|
|
14
18
|
}
|
|
15
19
|
if (project.length > 0) {
|
|
16
20
|
console.log();
|
|
17
|
-
console.log(chalk.bold.yellow("
|
|
21
|
+
console.log(chalk.bold.yellow(t("commands.memory.projectMemory")) + chalk.gray(" (.autohand/memory/)"));
|
|
18
22
|
console.log();
|
|
19
23
|
for (const entry of project) {
|
|
20
24
|
const date = new Date(entry.updatedAt).toLocaleDateString();
|
|
@@ -26,7 +30,7 @@ async function memory(ctx) {
|
|
|
26
30
|
}
|
|
27
31
|
if (user.length > 0) {
|
|
28
32
|
console.log();
|
|
29
|
-
console.log(chalk.bold.magenta("
|
|
33
|
+
console.log(chalk.bold.magenta(t("commands.memory.userMemory")) + chalk.gray(" (~/.autohand/memory/)"));
|
|
30
34
|
console.log();
|
|
31
35
|
for (const entry of user) {
|
|
32
36
|
const date = new Date(entry.updatedAt).toLocaleDateString();
|
|
@@ -42,7 +46,7 @@ async function memory(ctx) {
|
|
|
42
46
|
}
|
|
43
47
|
var metadata = {
|
|
44
48
|
command: "/memory",
|
|
45
|
-
description: "
|
|
49
|
+
description: t("commands.memory.description"),
|
|
46
50
|
implemented: true
|
|
47
51
|
};
|
|
48
52
|
|
|
@@ -1,4 +1,8 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
2
|
+
|
|
3
|
+
var _chunkLOXOD4IScjs = require('./chunk-LOXOD4IS.cjs');
|
|
4
|
+
|
|
5
|
+
// src/commands/undo.ts
|
|
2
6
|
var _chalk = require('chalk'); var _chalk2 = _interopRequireDefault(_chalk);
|
|
3
7
|
var _child_process = require('child_process');
|
|
4
8
|
async function undo(ctx) {
|
|
@@ -25,12 +29,13 @@ async function undo(ctx) {
|
|
|
25
29
|
console.log(_chalk2.default.green(" Removed untracked files"));
|
|
26
30
|
}
|
|
27
31
|
} else {
|
|
28
|
-
console.log(_chalk2.default.gray("
|
|
32
|
+
console.log(_chalk2.default.gray(" " + _chunkLOXOD4IScjs.t.call(void 0, "commands.undo.noChanges")));
|
|
29
33
|
}
|
|
30
34
|
try {
|
|
31
35
|
await ctx.undoFileMutation();
|
|
32
|
-
console.log(_chalk2.default.green("
|
|
36
|
+
console.log(_chalk2.default.green(" " + _chunkLOXOD4IScjs.t.call(void 0, "commands.undo.success", { file: "last mutation" })));
|
|
33
37
|
} catch (e) {
|
|
38
|
+
console.log(_chalk2.default.gray(" " + _chunkLOXOD4IScjs.t.call(void 0, "commands.undo.noChanges")));
|
|
34
39
|
}
|
|
35
40
|
ctx.removeLastTurn();
|
|
36
41
|
console.log(_chalk2.default.green(" Removed last conversation turn"));
|