autohand-cli 0.9.1 → 0.9.2
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 +103 -79
- package/dist/AgentRegistry-BBQRODQC.cjs +18 -0
- package/dist/AgentRegistry-JBXZUPML.js +18 -0
- package/dist/{CommunitySkillsCache-ZACDPD4J.js → CommunitySkillsCache-CI7UN2DX.js} +2 -2
- package/dist/CommunitySkillsCache-XTQ6RMTA.cjs +8 -0
- package/dist/{HookManager-2S6AHOC3.js → HookManager-BELBPQQI.js} +1 -1
- package/dist/{HookManager-TVEQI5ZU.cjs → HookManager-ZL2CLAJW.cjs} +2 -2
- package/dist/{ImportWizard-AF2XL6DS.cjs → ImportWizard-U6CIJREW.cjs} +12 -12
- package/dist/{ImportWizard-AEBMAKXE.js → ImportWizard-VJFSWSUQ.js} +3 -3
- package/dist/LearnAdvisor-LAURA3IB.cjs +9 -0
- package/dist/LearnAdvisor-RFOBXFG7.js +9 -0
- package/dist/MemoryManager-3A2VRPF2.js +9 -0
- package/dist/MemoryManager-UOEQZIDC.cjs +9 -0
- package/dist/{NVIDIAProvider-SJPY3ONR.js → NVIDIAProvider-AFNJNWJM.js} +1 -1
- package/dist/NVIDIAProvider-L5GTYRCQ.cjs +14 -0
- package/dist/{PermissionManager-MT7KBNNR.js → PermissionManager-N2LDSOYF.js} +3 -3
- package/dist/PermissionManager-ZNURIEYR.cjs +11 -0
- package/dist/ProviderFactory-3BFS65V7.cjs +13 -0
- package/dist/{ProviderFactory-RB4RVAF6.js → ProviderFactory-XUT6BSGB.js} +4 -3
- package/dist/SessionManager-LGPQIA57.cjs +10 -0
- package/dist/{SessionManager-554PHVPC.js → SessionManager-OR4KDDDS.js} +2 -2
- package/dist/{SkillsRegistry-NHHMIUYJ.js → SkillsRegistry-IL3GWROU.js} +2 -2
- package/dist/SkillsRegistry-PM34DQNA.cjs +9 -0
- package/dist/SubAgent-2WG4QQB5.cjs +13 -0
- package/dist/SubAgent-ICGN23TQ.js +13 -0
- package/dist/{about-3USFSGOH.js → about-OYVGQMJJ.js} +3 -3
- package/dist/{about-QR52U5DD.cjs → about-U2BH7HDR.cjs} +4 -4
- package/dist/{acp-5Y2W6OZP.js → acp-JWHGXZL5.js} +169 -103
- package/dist/{acp-GSYE75OB.cjs → acp-S37JOBCS.cjs} +184 -118
- package/dist/{actionExecutor-KHUU3Z3Q.cjs → actionExecutor-2QEPMELQ.cjs} +13 -13
- package/dist/{actionExecutor-PLQJZLZV.js → actionExecutor-6NCCORRB.js} +12 -12
- package/dist/add-dir-KFUHSIR2.cjs +11 -0
- package/dist/{add-dir-HCERJDBR.js → add-dir-MM2BM2Z2.js} +2 -2
- package/dist/agent-DUIYLIVN.js +132 -0
- package/dist/agent-YYEHGDAK.cjs +132 -0
- package/dist/agents-GBGG4CW7.cjs +19 -0
- package/dist/agents-ZH34C72F.js +19 -0
- package/dist/agents-new-ERXLS7SB.cjs +17 -0
- package/dist/{agents-new-7GAQ25EK.js → agents-new-EVTGPTA4.js} +6 -6
- package/dist/{autoSkill-66PKCYTW.js → autoSkill-HEWKJ5JV.js} +2 -2
- package/dist/autoSkill-YL6PN6AV.cjs +20 -0
- package/dist/automode-4BJ7FNPL.cjs +10 -0
- package/dist/{automode-BUF3VGXU.js → automode-S4U7A7Q2.js} +2 -2
- package/dist/chrome-45ZXHL5N.cjs +22 -0
- package/dist/{chrome-Y3T7EIHG.js → chrome-BBSRVG6S.js} +2 -2
- package/dist/chrome-IFVZRHAT.cjs +50 -0
- package/dist/chrome-MYE6DNA2.js +22 -0
- package/dist/{chunk-45CHNQM6.cjs → chunk-24CEJYEG.cjs} +93 -31
- package/dist/{chunk-6JWCGQJU.cjs → chunk-255GIVM2.cjs} +6 -6
- package/dist/{chunk-D546G7DA.cjs → chunk-2BDSR2OW.cjs} +98 -75
- package/dist/{chunk-PGFLPURU.js → chunk-2BPIR7LA.js} +121 -4
- package/dist/{chunk-AOKXYGBQ.cjs → chunk-2NY7OHBF.cjs} +41 -26
- package/dist/chunk-2WUNHTXL.js +303 -0
- package/dist/{chunk-PQBYFEBL.cjs → chunk-34B6ZO6W.cjs} +124 -7
- package/dist/{chunk-5JTTM5SC.js → chunk-3BJN7GAH.js} +1 -1
- package/dist/{chunk-3UC6DMFI.cjs → chunk-3CAXECWJ.cjs} +15 -15
- package/dist/{chunk-YWH55BWK.cjs → chunk-3CBYUBZC.cjs} +6 -9
- package/dist/chunk-3DF3GZQ7.js +277 -0
- package/dist/{chunk-KASXKDF2.cjs → chunk-3JURXAL6.cjs} +58 -7
- package/dist/{chunk-JV5HVCHU.cjs → chunk-3KWAP2Y3.cjs} +88 -9
- package/dist/{chunk-WPE2XHVX.js → chunk-3MCK6UBL.js} +1 -1
- package/dist/{chunk-U2QUMKCB.js → chunk-3TH7IK4M.js} +62 -9
- package/dist/{chunk-YXM6SA7P.js → chunk-3V77OB3W.js} +3 -3
- package/dist/{chunk-MZN6JBRZ.cjs → chunk-3Y5UEK7K.cjs} +4 -4
- package/dist/{chunk-BP37FVBM.js → chunk-4GPPSBEZ.js} +3 -3
- package/dist/{chunk-4XVLNOFA.js → chunk-5CMBAJ6K.js} +20 -3
- package/dist/{chunk-PNIAIOMZ.cjs → chunk-5YRXFBYZ.cjs} +35 -6
- package/dist/chunk-6AC2TT26.js +156 -0
- package/dist/{chunk-PSAH4ZQB.cjs → chunk-6EIQ6A6U.cjs} +2 -2
- package/dist/{chunk-YQDI753V.js → chunk-6HSEDXVF.js} +4 -4
- package/dist/{chunk-O5GI6SR3.js → chunk-6NUXK62F.js} +1 -1
- package/dist/{chunk-HVCIB4SW.cjs → chunk-6TGCAPYH.cjs} +62 -9
- package/dist/{chunk-HZWU6IO3.js → chunk-6W3SZCSP.js} +2 -5
- package/dist/{chunk-Q3BS6FPM.js → chunk-73LV3DDZ.js} +4 -4
- package/dist/{chunk-ZNGRLCFQ.js → chunk-7BGGLIQF.js} +83 -1
- package/dist/{chunk-ZNYZB7XY.cjs → chunk-7EEK7CRR.cjs} +83 -1
- package/dist/{chunk-HK5A54AV.cjs → chunk-7TO3PDMV.cjs} +48 -4
- package/dist/chunk-7UU22RSH.cjs +277 -0
- package/dist/{chunk-XNIMSVS6.cjs → chunk-A3GAM6FM.cjs} +11 -11
- package/dist/{chunk-W5QLA6WP.cjs → chunk-A7DJU75T.cjs} +8 -8
- package/dist/{chunk-7XTUL7ZD.cjs → chunk-AAAO4ERQ.cjs} +9 -9
- package/dist/{chunk-M5DK524Z.js → chunk-AAJLMP57.js} +2 -2
- package/dist/chunk-ABR756QN.js +529 -0
- package/dist/{chunk-OIGYWOL6.js → chunk-APFGDIPD.js} +3 -1
- package/dist/{chunk-PTTZI4QZ.js → chunk-APQYRMYL.js} +4 -4
- package/dist/{chunk-CO2AADYU.cjs → chunk-AZKOIF2G.cjs} +55 -17
- package/dist/{chunk-P6SLT2F4.cjs → chunk-AZLHUPNC.cjs} +2 -2
- package/dist/chunk-B55VCYSQ.cjs +30 -0
- package/dist/{chunk-JMJRFSNJ.js → chunk-BLQUMSM3.js} +1 -1
- package/dist/{chunk-MGNXABSU.cjs → chunk-BXKPX6K4.cjs} +9 -9
- package/dist/{chunk-MQQH4XQH.cjs → chunk-C66FN2LP.cjs} +4 -4
- package/dist/{chunk-CECH6QQP.js → chunk-CH7KUFAS.js} +10 -10
- package/dist/{chunk-PIXQ2AVM.cjs → chunk-CILSXOPI.cjs} +17 -17
- package/dist/{chunk-IEPLQ47J.js → chunk-CM24K6ZT.js} +89 -12
- package/dist/chunk-CMEZ42F2.cjs +303 -0
- package/dist/{chunk-X5P6QQOB.cjs → chunk-CNQKIWIS.cjs} +100 -23
- package/dist/{chunk-AQ5PVHOC.cjs → chunk-CSUGNNJY.cjs} +4 -3
- package/dist/{chunk-QRQF3556.js → chunk-D6HB3H3L.js} +25 -10
- package/dist/{chunk-XZVDYC5U.js → chunk-D7AYKVKW.js} +2 -2
- package/dist/{chunk-3UHRCHKB.cjs → chunk-DLCXWOWT.cjs} +23 -23
- package/dist/{chunk-CK4HAHVY.cjs → chunk-DMM2BKSV.cjs} +118 -25
- package/dist/{chunk-SPQ7QIQ6.js → chunk-DW3DPV77.js} +1 -1
- package/dist/chunk-ECQD2QC3.cjs +33 -0
- package/dist/{chunk-SNDDZG5H.js → chunk-EEYOS3UC.js} +90 -70
- package/dist/{chunk-DGBPWODD.js → chunk-EF2EN5CR.js} +2 -2
- package/dist/{chunk-M7B7RRBK.cjs → chunk-EFXFURDY.cjs} +138 -51
- package/dist/chunk-EK34UZPB.cjs +40 -0
- package/dist/{chunk-CRTCZ4WL.cjs → chunk-FJR6EZLO.cjs} +3834 -2337
- package/dist/{chunk-TYBPTKFT.js → chunk-FPO7YNPQ.js} +1 -1
- package/dist/{chunk-X3TI5TJJ.js → chunk-FS4I6BNR.js} +1 -1
- package/dist/{chunk-WNJXIACY.js → chunk-FSJ2MNOC.js} +3 -3
- package/dist/{chunk-44ZWOBTI.js → chunk-GEHZMC4G.js} +12 -9
- package/dist/{chunk-Y5BDE24P.cjs → chunk-GO6C2RAR.cjs} +3 -0
- package/dist/{chunk-XW3XCK4E.cjs → chunk-GSMR6V36.cjs} +4 -4
- package/dist/{chunk-H426KOGY.js → chunk-GSZWATME.js} +1 -1
- package/dist/{chunk-S5JNQIGL.cjs → chunk-GYLGCR6F.cjs} +5 -5
- package/dist/{chunk-ONVYXTUT.cjs → chunk-H3OOWNYQ.cjs} +3 -3
- package/dist/{chunk-V5ELP2XE.js → chunk-H65446XW.js} +110 -15
- package/dist/{chunk-LANGD5CO.js → chunk-H7HXRRHK.js} +45 -1
- package/dist/{chunk-RBXBH6EB.cjs → chunk-HN2JTDN5.cjs} +17 -17
- package/dist/{chunk-SOVR7S3T.cjs → chunk-HNXUZ5OY.cjs} +2 -2
- package/dist/{chunk-AZ47LKD5.cjs → chunk-HOYT3E65.cjs} +3 -3
- package/dist/{chunk-P4FUTSVK.js → chunk-HTPY5ESD.js} +3 -3
- package/dist/{chunk-5SFV2NCY.cjs → chunk-HVLWH2AF.cjs} +10 -10
- package/dist/{chunk-VQHSYAPZ.cjs → chunk-HZTEU4W5.cjs} +62 -93
- package/dist/{chunk-4XFHP2SN.cjs → chunk-I5T7LPFP.cjs} +7 -7
- package/dist/{chunk-ZPLCAXJW.js → chunk-IB5CJXE7.js} +7 -7
- package/dist/{chunk-KM7R5YPS.cjs → chunk-INNXFLDR.cjs} +9 -6
- package/dist/{chunk-2ESQR35E.cjs → chunk-JFLEP3T7.cjs} +10 -10
- package/dist/chunk-JJGDOBFL.js +40 -0
- package/dist/{chunk-5A7ZL64N.js → chunk-JSU46T6K.js} +1 -1
- package/dist/{chunk-NB6M6ESM.js → chunk-K6WN6BT4.js} +1 -1
- package/dist/{chunk-QQ64HEHP.cjs → chunk-KIQH3SMT.cjs} +34 -31
- package/dist/{chunk-MANJ67D3.js → chunk-KPRXHIE2.js} +52 -83
- package/dist/{chunk-6HF6XSCC.js → chunk-LIO3RX2Z.js} +2 -2
- package/dist/{chunk-NZ3ZWLUW.js → chunk-LOSXLH7P.js} +109 -16
- package/dist/{chunk-NZ7GCK7Y.cjs → chunk-LSOR72PB.cjs} +23 -23
- package/dist/{chunk-6AYJCDTA.js → chunk-MA3AVDCC.js} +47 -9
- package/dist/{chunk-PZZMIYII.js → chunk-ME3S2WIR.js} +3 -3
- package/dist/{chunk-2IW5YFJ4.js → chunk-NC2I2M4P.js} +4 -4
- package/dist/{chunk-AE2ILW25.cjs → chunk-NC4A4LVC.cjs} +13 -13
- package/dist/{chunk-EEHWALXA.js → chunk-NGEK5FCJ.js} +85 -3
- package/dist/{chunk-MMKZSJUN.js → chunk-NKW6CHXQ.js} +1 -1
- package/dist/{chunk-JB3JCYBJ.js → chunk-NOWCRKP2.js} +4 -3
- package/dist/{chunk-3ZOOH44N.js → chunk-NUB2LMB6.js} +2 -2
- package/dist/chunk-O246MKIW.cjs +267 -0
- package/dist/{chunk-SRMGWMQO.js → chunk-OGFWL2PS.js} +1 -1
- package/dist/{chunk-YISPVAXO.cjs → chunk-ONNGAR6W.cjs} +340 -597
- package/dist/{chunk-7WAUCLLQ.js → chunk-OOFR6A62.js} +33 -4
- package/dist/{chunk-4E7SHPNQ.js → chunk-OZ7FHO7J.js} +2 -2
- package/dist/{chunk-NV6LCD2I.cjs → chunk-P5EWGUI2.cjs} +109 -27
- package/dist/{chunk-YC5OBZQU.js → chunk-P6BQJPAI.js} +41 -18
- package/dist/{chunk-SHRLFX6F.js → chunk-PG2JIU5M.js} +57 -6
- package/dist/{chunk-6OECOAK5.cjs → chunk-PI27G2ED.cjs} +25 -8
- package/dist/{chunk-TR6NECEZ.js → chunk-PI7LRPL6.js} +1 -1
- package/dist/{chunk-GAOPJ5S3.cjs → chunk-PMPEC5HN.cjs} +18 -15
- package/dist/{chunk-5GCQ5UMV.cjs → chunk-PYUP7AKY.cjs} +14 -14
- package/dist/{chunk-S5QKRA2V.js → chunk-QC5Z3ZT5.js} +2 -2
- package/dist/chunk-QDO4L2A7.cjs +156 -0
- package/dist/{chunk-LFDPTJYF.cjs → chunk-QDXRI5AM.cjs} +1 -1
- package/dist/{chunk-26G7YGOW.js → chunk-QVXMSQOG.js} +84 -21
- package/dist/{chunk-SVVP4UUZ.cjs → chunk-R4UKBKDY.cjs} +11 -11
- package/dist/{chunk-HG3ZASBH.cjs → chunk-R75AWII3.cjs} +112 -17
- package/dist/{chunk-TE4SYTWR.cjs → chunk-RD5PLUIX.cjs} +8 -8
- package/dist/{chunk-FFHSCM5M.js → chunk-RGB34CV5.js} +3 -3
- package/dist/{chunk-SY2P3Z5W.cjs → chunk-RJCZLFHE.cjs} +96 -32
- package/dist/{chunk-22SCR3EV.cjs → chunk-RKWNM2BJ.cjs} +2 -2
- package/dist/{chunk-FBQJZKFX.js → chunk-RMVONICR.js} +3 -3
- package/dist/{chunk-PY73W5MQ.cjs → chunk-RPSYRJL7.cjs} +10 -4
- package/dist/{chunk-HXHE2KAO.js → chunk-RWKU2X7O.js} +7 -4
- package/dist/{chunk-NQZH5CR2.cjs → chunk-RZLEGVMH.cjs} +102 -5
- package/dist/{chunk-KMP6Y3LJ.js → chunk-S2L3Y677.js} +1 -1
- package/dist/{chunk-GSDV75A5.js → chunk-S7KVUIOS.js} +1 -1
- package/dist/{chunk-7PT646AL.cjs → chunk-SACJJ6NO.cjs} +5 -3
- package/dist/{chunk-LEZEWKPA.js → chunk-SJQU2ZFR.js} +96 -32
- package/dist/{chunk-65LRPW5W.js → chunk-SKAQKQFF.js} +12 -2
- package/dist/chunk-T4DXP5OP.js +30 -0
- package/dist/{chunk-EYHKL4QC.js → chunk-T6FTB6K2.js} +1 -1
- package/dist/{chunk-DNSD7DVJ.js → chunk-T6N6GRFT.js} +13 -10
- package/dist/{chunk-575PXZX7.js → chunk-TJFKA6A7.js} +82 -3
- package/dist/{chunk-HSWWM6AM.js → chunk-TJZUPS4Z.js} +34 -291
- package/dist/{chunk-DHUQZ53B.cjs → chunk-TLKHZ425.cjs} +2 -2
- package/dist/{chunk-VLGGMQUN.cjs → chunk-TQ24NLXO.cjs} +6 -6
- package/dist/{chunk-LUMV3DB2.js → chunk-TWBAU46X.js} +1 -1
- package/dist/{chunk-EA2MS25U.cjs → chunk-TZB5XADL.cjs} +4 -4
- package/dist/{chunk-U6PLSPMD.cjs → chunk-UAYXZXWU.cjs} +4 -4
- package/dist/{chunk-OV3T5MUH.cjs → chunk-UKBFNBDO.cjs} +11 -11
- package/dist/{chunk-SZD45IDG.js → chunk-UMJYX5KD.js} +101 -4
- package/dist/{chunk-B76FJKEJ.cjs → chunk-USKYTHDL.cjs} +69 -18
- package/dist/{chunk-NZQFKXM3.cjs → chunk-VAJUSZMC.cjs} +15 -15
- package/dist/{chunk-SDLY4X3G.js → chunk-VGQG4NBJ.js} +2 -2
- package/dist/{chunk-KWXGDSYT.js → chunk-VLUIVJ3J.js} +58 -7
- package/dist/{chunk-KJ26T7GM.cjs → chunk-VOBINVMV.cjs} +105 -42
- package/dist/{chunk-C5QIQQ37.js → chunk-VSHKKCSH.js} +16 -5
- package/dist/{chunk-L46OUKW5.cjs → chunk-VSZU3MGA.cjs} +28 -17
- package/dist/{chunk-YFXTE422.cjs → chunk-VWHAUB77.cjs} +8 -3
- package/dist/{chunk-UWZ4G3SQ.js → chunk-VXGYFX45.js} +4 -4
- package/dist/{chunk-C46B72VK.js → chunk-WH6YUQDB.js} +141 -54
- package/dist/{chunk-SFFEKZGC.js → chunk-WQ6TD55V.js} +2 -2
- package/dist/{chunk-7PJKTSRN.js → chunk-WQWECXTY.js} +3 -3
- package/dist/{chunk-DSSCERHI.cjs → chunk-WVDJUJH6.cjs} +2 -2
- package/dist/{chunk-JPFRI4L4.js → chunk-X24VIVDZ.js} +210 -26
- package/dist/{chunk-7IRQ7JEH.js → chunk-X4NRTLXD.js} +7 -1
- package/dist/{chunk-7MY4JHER.js → chunk-X53SHYCG.js} +2 -2
- package/dist/{chunk-RFUKZIJF.cjs → chunk-XB2Z4ZAK.cjs} +5 -5
- package/dist/{chunk-WJYFLQ7G.cjs → chunk-Y47OJGLB.cjs} +3 -3
- package/dist/{chunk-HC2Q6A3E.cjs → chunk-Y4MN27V3.cjs} +361 -177
- package/dist/{chunk-ZK6HOR62.js → chunk-YEHFYZFU.js} +7 -2
- package/dist/{chunk-FFBDRUO5.cjs → chunk-YICIUY23.cjs} +1 -1
- package/dist/{chunk-63ANVAOJ.cjs → chunk-YMXYC777.cjs} +3 -3
- package/dist/{chunk-X7XMITIL.cjs → chunk-Z3GRWK6O.cjs} +8 -8
- package/dist/{chunk-3ICORF7M.cjs → chunk-Z5GG2KSL.cjs} +4 -4
- package/dist/{chunk-I2ZK3AOD.js → chunk-ZER7DYQK.js} +2 -2
- package/dist/{chunk-V3SZLWEQ.cjs → chunk-ZFDXZEZJ.cjs} +11 -11
- package/dist/{chunk-QBYGMMDD.js → chunk-ZFV4HJA6.js} +66 -4
- package/dist/chunk-ZHMYTI5D.cjs +529 -0
- package/dist/{chunk-4567QNRB.js → chunk-ZLR2TFBC.js} +3 -0
- package/dist/{chunk-OCATAKXV.cjs → chunk-ZTWNU5QZ.cjs} +20 -20
- package/dist/{chunk-CCIDL4SA.js → chunk-ZVLVLDYN.js} +2915 -1418
- package/dist/clear-AJGXD2BB.cjs +12 -0
- package/dist/{clear-Y5TO3RZA.js → clear-HAHDSWKW.js} +3 -3
- package/dist/communityInstaller-IRR6M3N6.cjs +22 -0
- package/dist/{communityInstaller-RVL4STPS.js → communityInstaller-OLKEUGMX.js} +5 -5
- package/dist/completion-G7Z436TF.cjs +17 -0
- package/dist/{completion-SE3XYG74.js → completion-ZS3AXJ6A.js} +4 -4
- package/dist/{config-7KPHKFTP.js → config-OWYAQPCX.js} +5 -4
- package/dist/config-W2BHT2QE.cjs +22 -0
- package/dist/{constants-EJFAWJQI.js → constants-AS6K67AA.js} +5 -3
- package/dist/constants-B4W5BT7F.cjs +23 -0
- package/dist/{export-BJVIDZC4.js → export-5HIU3KMD.js} +4 -4
- package/dist/export-GFD32UY2.cjs +15 -0
- package/dist/{extractSessionMemories-A2JX5WJ2.js → extractSessionMemories-K6ZVAW2F.js} +1 -1
- package/dist/{extractSessionMemories-XL3MS37F.cjs → extractSessionMemories-LLOIJR5U.cjs} +2 -2
- package/dist/feature-KP74CZ3F.cjs +14 -0
- package/dist/{feature-V4JF5TNJ.js → feature-OPNVMB2E.js} +2 -2
- package/dist/features-LT55MURX.cjs +24 -0
- package/dist/features-ZDIU26WX.js +24 -0
- package/dist/feedback-7WTJFQ6S.js +18 -0
- package/dist/feedback-CEOJ3453.cjs +18 -0
- package/dist/go-2CY5SZNR.js +16 -0
- package/dist/go-O2CSQON4.cjs +16 -0
- package/dist/goal-DL2N2AWT.cjs +16 -0
- package/dist/goal-IJS7VZSG.js +16 -0
- package/dist/help-RNOGDEBA.cjs +12 -0
- package/dist/{help-MLIROWKM.js → help-TCWD2IRH.js} +2 -2
- package/dist/{history-GQJ6RZD6.js → history-ATOR5OQV.js} +2 -2
- package/dist/history-UUSGX2AL.cjs +14 -0
- package/dist/{hooks-PPFHCF7T.js → hooks-R3Z5QKUP.js} +5 -5
- package/dist/hooks-RWM5UY67.cjs +18 -0
- package/dist/{i18n-Q7UZJRPL.js → i18n-4QI4TD4I.js} +1 -1
- package/dist/i18n-MFAEU5RV.cjs +33 -0
- package/dist/{ide-BUSVE54P.js → ide-6PBTCCUQ.js} +4 -4
- package/dist/ide-UE3G7NMQ.cjs +15 -0
- package/dist/{import-C7S6UJMW.cjs → import-2IG76KAN.cjs} +6 -4
- package/dist/{import-U47DXCA7.js → import-E47QL4DW.js} +2 -2
- package/dist/import-NQDNBFUL.cjs +10 -0
- package/dist/{import-3VBKI6BN.js → import-VQIHGJWS.js} +6 -4
- package/dist/index.cjs +444 -334
- package/dist/index.d.cts +38 -0
- package/dist/index.d.ts +38 -0
- package/dist/index.js +324 -214
- package/dist/init-DX3RDGDT.cjs +10 -0
- package/dist/{init-Q2O4R42R.js → init-Q54OAAFZ.js} +2 -2
- package/dist/{inputPrompt-3CFZDUBH.js → inputPrompt-V2VBDRM7.js} +2 -2
- package/dist/inputPrompt-WVGVWAHS.cjs +90 -0
- package/dist/language-I6KXAOXD.js +23 -0
- package/dist/language-XMIVOH5E.cjs +23 -0
- package/dist/learn-JPVVGTKU.js +23 -0
- package/dist/learn-NLSHI2MZ.cjs +23 -0
- package/dist/login-NABQYLYC.cjs +28 -0
- package/dist/login-XPOVFSWN.js +28 -0
- package/dist/logout-HNHCGB4Q.js +25 -0
- package/dist/logout-SKGDXJSW.cjs +25 -0
- package/dist/{mcp-AH3MMUBU.js → mcp-EN73YFGZ.js} +8 -7
- package/dist/mcp-TADZCPJQ.cjs +22 -0
- package/dist/{mcp-install-IA4ZS2SV.cjs → mcp-install-2GKWWBAS.cjs} +14 -13
- package/dist/{mcp-install-222PCKSW.js → mcp-install-3TBTVSHW.js} +9 -8
- package/dist/memory-GRXFTDIN.cjs +10 -0
- package/dist/{memory-VB46T5H3.js → memory-K2P3CDCH.js} +2 -2
- package/dist/{model-SJJG64AM.js → model-DEG22OWA.js} +2 -2
- package/dist/model-OSD74T7Z.cjs +10 -0
- package/dist/new-4NWBOATU.cjs +12 -0
- package/dist/{new-ERZ5C6CN.js → new-KJAP2MB6.js} +3 -3
- package/dist/{onboarding-ZQXMPSMJ.js → onboarding-2U5WE2OA.js} +17 -14
- package/dist/onboarding-5DZFCO5Q.cjs +39 -0
- package/dist/permissions-KY5I6YQ3.cjs +10 -0
- package/dist/{permissions-7ACNFK7A.js → permissions-TKYON7PP.js} +2 -2
- package/dist/{plan-YYUAXPTL.js → plan-DYHHLZSS.js} +1 -1
- package/dist/plan-PYKP652W.cjs +13 -0
- package/dist/quit-GSKJL42O.js +14 -0
- package/dist/quit-TQSRTBUT.cjs +14 -0
- package/dist/{registry-4DXUDKJN.js → registry-EZ4V4TUQ.js} +1339 -1
- package/dist/{registry-UEO3ETZ7.cjs → registry-LCWYI4IB.cjs} +1378 -40
- package/dist/resume-4VWJXARX.cjs +17 -0
- package/dist/{resume-XSXZMDMD.js → resume-TLHWWWFN.js} +5 -5
- package/dist/{review-QHP2KP4Q.js → review-CSK4IYTO.js} +1 -1
- package/dist/review-XLJEUH5K.cjs +9 -0
- package/dist/{rpc-XH7QLN4H.js → rpc-3DLQBDWU.js} +151 -124
- package/dist/{rpc-YF54T7JU.cjs → rpc-O36WUU3L.cjs} +169 -142
- package/dist/search-DSX2CY4A.cjs +22 -0
- package/dist/search-I3QUDUQL.js +22 -0
- package/dist/sessionBranching-DVNOUWJT.cjs +19 -0
- package/dist/sessionBranching-FKV4CR36.js +19 -0
- package/dist/sessions-3JUOT3ED.cjs +10 -0
- package/dist/{sessions-NJYHJOEL.js → sessions-VWMDIPOS.js} +2 -2
- package/dist/{settings-ZXUQH3DO.js → settings-FT2LZZUV.js} +11 -8
- package/dist/settings-RL4KNWHB.cjs +45 -0
- package/dist/setup-HQEJVOYT.js +32 -0
- package/dist/setup-MN54LKOL.cjs +32 -0
- package/dist/share-BUAFZNBX.cjs +17 -0
- package/dist/{share-WFAGZ5PY.js → share-CGB6MAVJ.js} +6 -6
- package/dist/skills/builtin/code-reviewer/SKILL.md +64 -0
- package/dist/skills/builtin/goal-writer/SKILL.md +124 -0
- package/dist/{skills-NBTNDVAY.js → skills-7DKR3HRZ.js} +7 -7
- package/dist/{skills-OB6RDW7D.js → skills-BBBENOEY.js} +9 -9
- package/dist/skills-OQM7IHAF.cjs +29 -0
- package/dist/{skills-ZROBG3RZ.cjs → skills-RA2PKL63.cjs} +9 -9
- package/dist/{skills-install-ILX6QVEF.cjs → skills-install-D7K476SL.cjs} +15 -15
- package/dist/{skills-install-BHTIEMKH.js → skills-install-T4SOKJSL.js} +8 -8
- package/dist/{skills-new-YMRP2HNO.js → skills-new-S33NGEU3.js} +6 -6
- package/dist/skills-new-UVYH53MD.cjs +18 -0
- package/dist/slashCommands-MWOUDSQP.js +111 -0
- package/dist/slashCommands-XASURUTV.cjs +111 -0
- package/dist/squad-PIIYDFVH.cjs +15 -0
- package/dist/squad-VHYOVEJP.js +15 -0
- package/dist/status-GHFTXQBL.js +25 -0
- package/dist/status-WXMIJIU3.cjs +25 -0
- package/dist/statusline-2K7AC6ZQ.js +21 -0
- package/dist/statusline-GROI4HOC.cjs +21 -0
- package/dist/sync-254WF6JI.cjs +42 -0
- package/dist/sync-2DIZN4EH.cjs +24 -0
- package/dist/{sync-OCJN4ZSO.js → sync-J6I2ZUKQ.js} +5 -3
- package/dist/{sync-7C25MOT2.js → sync-Z3LVSEEV.js} +8 -6
- package/dist/{teammate-D77B6QRT.cjs → teammate-EXR76PEQ.cjs} +5 -5
- package/dist/{teammate-EZCMHOIL.js → teammate-K4DAOFEQ.js} +5 -5
- package/dist/theme-MVQDSU47.js +23 -0
- package/dist/theme-QAKEYWJG.cjs +23 -0
- package/dist/ui/questionModal.cjs +5 -5
- package/dist/ui/questionModal.js +4 -4
- package/dist/{undo-GNUTFXCW.js → undo-5AU47JHF.js} +2 -2
- package/dist/undo-ME6WKUXZ.cjs +10 -0
- package/dist/{usage-QSTNSDAO.js → usage-QTKO2YMD.js} +6 -5
- package/dist/usage-TYNJKVER.cjs +25 -0
- package/package.json +4 -3
- package/dist/AgentRegistry-GOV7FN2O.js +0 -10
- package/dist/AgentRegistry-J2C6JBZ3.cjs +0 -10
- package/dist/CommunitySkillsCache-22BB3J6H.cjs +0 -8
- package/dist/LearnAdvisor-KKEQ5QCV.js +0 -9
- package/dist/LearnAdvisor-Q7RAYLPF.cjs +0 -9
- package/dist/MemoryManager-PMNAEZMB.cjs +0 -8
- package/dist/MemoryManager-QZRLTUB5.js +0 -8
- package/dist/NVIDIAProvider-C3FWQOBZ.cjs +0 -14
- package/dist/PermissionManager-URCNP5EC.cjs +0 -11
- package/dist/ProviderFactory-56N3ECE4.cjs +0 -12
- package/dist/SessionManager-2IZGWASQ.cjs +0 -10
- package/dist/SkillsRegistry-GMRVONOQ.cjs +0 -9
- package/dist/SubAgent-4GOR2FIJ.js +0 -13
- package/dist/SubAgent-ZJMDH4FI.cjs +0 -13
- package/dist/add-dir-BTAD5OZS.cjs +0 -11
- package/dist/agent-B3EVT7NN.cjs +0 -126
- package/dist/agent-SATQ3WZ3.js +0 -126
- package/dist/agents-44CRJGM7.cjs +0 -18
- package/dist/agents-NN4ZAJ7R.js +0 -18
- package/dist/agents-new-6D6G4QS6.cjs +0 -17
- package/dist/autoSkill-VQLGBELN.cjs +0 -20
- package/dist/automode-45DWV4TN.cjs +0 -10
- package/dist/chrome-Q2U73HZB.cjs +0 -50
- package/dist/chrome-Q54OALOK.cjs +0 -21
- package/dist/chrome-ZNJ46OYW.js +0 -21
- package/dist/chunk-JCUHCH37.cjs +0 -247
- package/dist/chunk-VKOXFT4L.cjs +0 -23
- package/dist/clear-QJXU25IF.cjs +0 -12
- package/dist/communityInstaller-LXMVKVAV.cjs +0 -22
- package/dist/completion-JX4T2ONW.cjs +0 -17
- package/dist/config-3224PRW4.cjs +0 -21
- package/dist/constants-MCCGUU5F.cjs +0 -21
- package/dist/export-KU4557HK.cjs +0 -15
- package/dist/feature-K3LG5IJP.cjs +0 -14
- package/dist/features-5OJTLKS7.js +0 -23
- package/dist/features-VCBJQXCX.cjs +0 -23
- package/dist/feedback-D4437VE4.js +0 -18
- package/dist/feedback-VZPEHGFY.cjs +0 -18
- package/dist/go-X4E6BCD6.js +0 -12
- package/dist/go-XREVFS5I.cjs +0 -12
- package/dist/goal-4M3J6JS2.cjs +0 -16
- package/dist/goal-EI66BV7W.js +0 -16
- package/dist/help-GGFS7WHY.cjs +0 -12
- package/dist/history-J4LUIOSI.cjs +0 -14
- package/dist/hooks-FSRIUS6A.cjs +0 -18
- package/dist/i18n-CI6VFXL5.cjs +0 -33
- package/dist/ide-YR27BPGM.cjs +0 -15
- package/dist/import-DBK4OCDF.cjs +0 -10
- package/dist/init-OXTYS72D.cjs +0 -10
- package/dist/inputPrompt-JMACL4EB.cjs +0 -90
- package/dist/language-EK3M6UBV.cjs +0 -22
- package/dist/language-Q3RUGGOW.js +0 -22
- package/dist/learn-3DSX7DYG.cjs +0 -23
- package/dist/learn-OPOH5L43.js +0 -23
- package/dist/login-GST7MWXJ.cjs +0 -27
- package/dist/login-Q7DZKAX4.js +0 -27
- package/dist/logout-2G7OUK7I.cjs +0 -24
- package/dist/logout-FNBBL2UI.js +0 -24
- package/dist/mcp-DW7R63IB.cjs +0 -21
- package/dist/memory-6NX3DAIY.cjs +0 -10
- package/dist/model-64NAELFS.cjs +0 -10
- package/dist/new-DU5SOOOY.cjs +0 -12
- package/dist/onboarding-2U2BV2KE.cjs +0 -36
- package/dist/permissions-GSNNV7RJ.cjs +0 -10
- package/dist/plan-XEJMOT55.cjs +0 -13
- package/dist/quit-WY6T267G.js +0 -10
- package/dist/quit-XIRE2KRE.cjs +0 -10
- package/dist/resume-RQZ3WXBP.cjs +0 -17
- package/dist/review-UWHWQHCB.cjs +0 -9
- package/dist/search-VXXFGZWU.cjs +0 -21
- package/dist/search-YAWGX7P7.js +0 -21
- package/dist/sessions-OSG3UJEZ.cjs +0 -10
- package/dist/settings-SO2UIGWV.cjs +0 -42
- package/dist/setup-KG7EGKF5.js +0 -30
- package/dist/setup-RSOPCQ57.cjs +0 -30
- package/dist/share-ZU3SGACF.cjs +0 -17
- package/dist/skills-KBVAQAD2.cjs +0 -29
- package/dist/skills-new-B45VQ2PP.cjs +0 -18
- package/dist/slashCommands-53VYIBJU.js +0 -105
- package/dist/slashCommands-BG2RGGZ6.cjs +0 -105
- package/dist/status-CQ2IUOVK.cjs +0 -24
- package/dist/status-E7IGNVPC.js +0 -24
- package/dist/sync-XRP46IVG.cjs +0 -40
- package/dist/sync-ZMFVE7T4.cjs +0 -22
- package/dist/theme-KKRDE6P7.cjs +0 -22
- package/dist/theme-XF7XIWBQ.js +0 -22
- package/dist/undo-U4KN7QQM.cjs +0 -10
- package/dist/usage-YDEMQBNQ.cjs +0 -24
package/dist/index.cjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } async function _asyncNullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return await rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; } var _class;
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunk5YRXFBYZcjs = require('./chunk-5YRXFBYZ.cjs');
|
|
5
|
+
|
|
5
6
|
|
|
6
7
|
|
|
7
8
|
|
|
8
9
|
|
|
9
|
-
var _chunkQLZOMZO5cjs = require('./chunk-QLZOMZO5.cjs');
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
|
|
@@ -15,28 +15,37 @@ var _chunkQLZOMZO5cjs = require('./chunk-QLZOMZO5.cjs');
|
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
|
|
18
|
+
var _chunkEFXFURDYcjs = require('./chunk-EFXFURDY.cjs');
|
|
18
19
|
|
|
19
20
|
|
|
20
21
|
|
|
21
22
|
|
|
22
|
-
var
|
|
23
|
+
var _chunkQLZOMZO5cjs = require('./chunk-QLZOMZO5.cjs');
|
|
23
24
|
|
|
24
25
|
|
|
25
26
|
var _chunkXDLH4EDLcjs = require('./chunk-XDLH4EDL.cjs');
|
|
26
27
|
|
|
27
28
|
|
|
29
|
+
var _chunkCMEZ42F2cjs = require('./chunk-CMEZ42F2.cjs');
|
|
30
|
+
require('./chunk-3OF56EMA.cjs');
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
|
|
28
35
|
|
|
29
36
|
|
|
30
37
|
|
|
31
38
|
|
|
32
39
|
|
|
40
|
+
var _chunkUKBFNBDOcjs = require('./chunk-UKBFNBDO.cjs');
|
|
33
41
|
|
|
34
42
|
|
|
35
|
-
var _chunkOV3T5MUHcjs = require('./chunk-OV3T5MUH.cjs');
|
|
36
43
|
|
|
44
|
+
var _chunk3KWAP2Y3cjs = require('./chunk-3KWAP2Y3.cjs');
|
|
37
45
|
|
|
38
46
|
|
|
39
|
-
|
|
47
|
+
|
|
48
|
+
var _chunkAZKOIF2Gcjs = require('./chunk-AZKOIF2G.cjs');
|
|
40
49
|
|
|
41
50
|
|
|
42
51
|
|
|
@@ -47,27 +56,32 @@ var _chunkFMB3TSWPcjs = require('./chunk-FMB3TSWP.cjs');
|
|
|
47
56
|
var _chunkSD3NTC7Dcjs = require('./chunk-SD3NTC7D.cjs');
|
|
48
57
|
|
|
49
58
|
|
|
50
|
-
var
|
|
51
|
-
require('./chunk-
|
|
52
|
-
require('./chunk-
|
|
53
|
-
require('./chunk-YWH55BWK.cjs');
|
|
59
|
+
var _chunkCSUGNNJYcjs = require('./chunk-CSUGNNJY.cjs');
|
|
60
|
+
require('./chunk-DMM2BKSV.cjs');
|
|
61
|
+
require('./chunk-3CBYUBZC.cjs');
|
|
54
62
|
require('./chunk-NHWHEW7M.cjs');
|
|
55
63
|
|
|
56
64
|
|
|
57
65
|
|
|
58
66
|
|
|
59
67
|
|
|
60
|
-
var
|
|
61
|
-
require('./chunk-
|
|
68
|
+
var _chunkCNQKIWIScjs = require('./chunk-CNQKIWIS.cjs');
|
|
69
|
+
require('./chunk-AZLHUPNC.cjs');
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
var _chunkEK34UZPBcjs = require('./chunk-EK34UZPB.cjs');
|
|
62
74
|
require('./chunk-3EDDDZS2.cjs');
|
|
63
|
-
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
var _chunk7TO3PDMVcjs = require('./chunk-7TO3PDMV.cjs');
|
|
64
78
|
require('./chunk-YWTIXHU6.cjs');
|
|
65
79
|
require('./chunk-2VHB43IX.cjs');
|
|
66
80
|
|
|
67
81
|
|
|
68
82
|
|
|
69
83
|
|
|
70
|
-
var
|
|
84
|
+
var _chunk3JURXAL6cjs = require('./chunk-3JURXAL6.cjs');
|
|
71
85
|
require('./chunk-XF2WIKHR.cjs');
|
|
72
86
|
|
|
73
87
|
|
|
@@ -76,7 +90,7 @@ var _chunkWGNMOVMTcjs = require('./chunk-WGNMOVMT.cjs');
|
|
|
76
90
|
|
|
77
91
|
|
|
78
92
|
|
|
79
|
-
var
|
|
93
|
+
var _chunkRJCZLFHEcjs = require('./chunk-RJCZLFHE.cjs');
|
|
80
94
|
require('./chunk-3HT76LNN.cjs');
|
|
81
95
|
|
|
82
96
|
// src/index.ts
|
|
@@ -88,13 +102,49 @@ var _path = require('path'); var _path2 = _interopRequireDefault(_path);
|
|
|
88
102
|
var _url = require('url');
|
|
89
103
|
var _child_process = require('child_process');
|
|
90
104
|
|
|
105
|
+
// src/auth/startupAuth.ts
|
|
106
|
+
async function validateAuthOnStartup(config) {
|
|
107
|
+
if (!_optionalChain([config, 'access', _ => _.auth, 'optionalAccess', _2 => _2.token])) {
|
|
108
|
+
return void 0;
|
|
109
|
+
}
|
|
110
|
+
if (config.auth.expiresAt) {
|
|
111
|
+
const expiresAt = new Date(config.auth.expiresAt);
|
|
112
|
+
if (expiresAt < /* @__PURE__ */ new Date()) {
|
|
113
|
+
config.auth = void 0;
|
|
114
|
+
try {
|
|
115
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
116
|
+
} catch (e) {
|
|
117
|
+
}
|
|
118
|
+
return void 0;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
try {
|
|
122
|
+
const authClient = _chunkAZKOIF2Gcjs.getAuthClient.call(void 0, );
|
|
123
|
+
const result = await authClient.validateSession(config.auth.token);
|
|
124
|
+
if (result.authenticated) {
|
|
125
|
+
if (result.user && config.auth) {
|
|
126
|
+
config.auth.user = result.user;
|
|
127
|
+
}
|
|
128
|
+
return _optionalChain([config, 'access', _3 => _3.auth, 'optionalAccess', _4 => _4.user]);
|
|
129
|
+
}
|
|
130
|
+
config.auth = void 0;
|
|
131
|
+
try {
|
|
132
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
133
|
+
} catch (e2) {
|
|
134
|
+
}
|
|
135
|
+
return void 0;
|
|
136
|
+
} catch (e3) {
|
|
137
|
+
return _optionalChain([config, 'access', _5 => _5.auth, 'optionalAccess', _6 => _6.user]);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
91
141
|
// src/telemetry/PingService.ts
|
|
92
142
|
|
|
93
143
|
|
|
94
144
|
var _crypto = require('crypto'); var _crypto2 = _interopRequireDefault(_crypto);
|
|
95
145
|
var _os = require('os'); var _os2 = _interopRequireDefault(_os);
|
|
96
146
|
var PING_INTERVAL_MS = 45 * 60 * 1e3;
|
|
97
|
-
var PING_CACHE_FILE = _path2.default.join(
|
|
147
|
+
var PING_CACHE_FILE = _path2.default.join(_chunk3JURXAL6cjs.AUTOHAND_HOME, "last-ping.json");
|
|
98
148
|
var API_BASE_URL = process.env.AUTOHAND_API_URL || "https://api.autohand.ai";
|
|
99
149
|
var REQUEST_TIMEOUT_MS = 5e3;
|
|
100
150
|
var PingService = (_class = class {
|
|
@@ -115,14 +165,14 @@ var PingService = (_class = class {
|
|
|
115
165
|
*/
|
|
116
166
|
getOrCreateDeviceId() {
|
|
117
167
|
try {
|
|
118
|
-
_fsextra2.default.ensureDirSync(_path2.default.dirname(
|
|
119
|
-
if (_fsextra2.default.existsSync(
|
|
120
|
-
return _fsextra2.default.readFileSync(
|
|
168
|
+
_fsextra2.default.ensureDirSync(_path2.default.dirname(_chunk3JURXAL6cjs.AUTOHAND_FILES.deviceId));
|
|
169
|
+
if (_fsextra2.default.existsSync(_chunk3JURXAL6cjs.AUTOHAND_FILES.deviceId)) {
|
|
170
|
+
return _fsextra2.default.readFileSync(_chunk3JURXAL6cjs.AUTOHAND_FILES.deviceId, "utf8").trim();
|
|
121
171
|
}
|
|
122
172
|
const id = _crypto2.default.randomUUID();
|
|
123
|
-
_fsextra2.default.writeFileSync(
|
|
173
|
+
_fsextra2.default.writeFileSync(_chunk3JURXAL6cjs.AUTOHAND_FILES.deviceId, id);
|
|
124
174
|
return id;
|
|
125
|
-
} catch (
|
|
175
|
+
} catch (e4) {
|
|
126
176
|
return _crypto2.default.randomUUID();
|
|
127
177
|
}
|
|
128
178
|
}
|
|
@@ -140,7 +190,7 @@ var PingService = (_class = class {
|
|
|
140
190
|
return false;
|
|
141
191
|
}
|
|
142
192
|
}
|
|
143
|
-
} catch (
|
|
193
|
+
} catch (e5) {
|
|
144
194
|
}
|
|
145
195
|
return true;
|
|
146
196
|
}
|
|
@@ -155,7 +205,7 @@ var PingService = (_class = class {
|
|
|
155
205
|
pingDate: (/* @__PURE__ */ new Date()).toISOString().split("T")[0]
|
|
156
206
|
};
|
|
157
207
|
await _fsextra2.default.writeJson(PING_CACHE_FILE, cache, { spaces: 2 });
|
|
158
|
-
} catch (
|
|
208
|
+
} catch (e6) {
|
|
159
209
|
}
|
|
160
210
|
}
|
|
161
211
|
/**
|
|
@@ -201,7 +251,7 @@ var PingService = (_class = class {
|
|
|
201
251
|
latestVersion: data.latestVersion
|
|
202
252
|
};
|
|
203
253
|
}
|
|
204
|
-
} catch (
|
|
254
|
+
} catch (e7) {
|
|
205
255
|
} finally {
|
|
206
256
|
this.isPinging = false;
|
|
207
257
|
}
|
|
@@ -248,10 +298,10 @@ function initPingService(options) {
|
|
|
248
298
|
return pingServiceInstance;
|
|
249
299
|
}
|
|
250
300
|
function startPingService() {
|
|
251
|
-
_optionalChain([pingServiceInstance, 'optionalAccess',
|
|
301
|
+
_optionalChain([pingServiceInstance, 'optionalAccess', _7 => _7.start, 'call', _8 => _8()]);
|
|
252
302
|
}
|
|
253
303
|
function stopPingService() {
|
|
254
|
-
_optionalChain([pingServiceInstance, 'optionalAccess',
|
|
304
|
+
_optionalChain([pingServiceInstance, 'optionalAccess', _9 => _9.stop, 'call', _10 => _10()]);
|
|
255
305
|
}
|
|
256
306
|
|
|
257
307
|
// src/utils/stdinDetector.ts
|
|
@@ -266,7 +316,7 @@ function detectStdinType(fstat = _fs.fstatSync) {
|
|
|
266
316
|
return "pipe";
|
|
267
317
|
}
|
|
268
318
|
return "none";
|
|
269
|
-
} catch (
|
|
319
|
+
} catch (e8) {
|
|
270
320
|
return "none";
|
|
271
321
|
}
|
|
272
322
|
}
|
|
@@ -343,7 +393,7 @@ function resolveAutoModeLaunchMode(options) {
|
|
|
343
393
|
if (!options.hasAutoModeFlag) {
|
|
344
394
|
return "disabled";
|
|
345
395
|
}
|
|
346
|
-
if (_optionalChain([options, 'access',
|
|
396
|
+
if (_optionalChain([options, 'access', _11 => _11.autoModeTask, 'optionalAccess', _12 => _12.trim, 'call', _13 => _13()])) {
|
|
347
397
|
return "standalone";
|
|
348
398
|
}
|
|
349
399
|
return options.stdinIsTTY ? "interactive" : "unavailable";
|
|
@@ -387,39 +437,39 @@ function buildTmuxLaunchCommand(argv) {
|
|
|
387
437
|
// src/browser/cliCommand.ts
|
|
388
438
|
|
|
389
439
|
function registerChromeCommand(program2) {
|
|
390
|
-
program2.command("chrome").description("install and configure the Autohand Chrome extension bridge").command("install").description("install the native messaging bridge for Chrome-compatible browsers").option("--browser <browser>", "target browser: chrome, chromium, brave, edge, or all", "all").option("--extension-id <id>", "installed Chrome extension id to use for direct handoff").option("--install-url <url>", "fallback install/continue URL",
|
|
391
|
-
const config = await
|
|
392
|
-
const launchSpec =
|
|
393
|
-
const browsers =
|
|
394
|
-
const extensionId = _nullishCoalesce(options.extensionId, () => ( _optionalChain([config, 'access',
|
|
395
|
-
const preferredBrowser = options.browser === "all" ? _nullishCoalesce(_optionalChain([config, 'access',
|
|
396
|
-
const installUrl = _nullishCoalesce(_nullishCoalesce(options.installUrl, () => ( _optionalChain([config, 'access',
|
|
397
|
-
const detectedProfile = extensionId ? await
|
|
398
|
-
const result = await
|
|
440
|
+
program2.command("chrome").description("install and configure the Autohand Chrome extension bridge").command("install").description("install the native messaging bridge for Chrome-compatible browsers").option("--browser <browser>", "target browser: chrome, chromium, brave, edge, or all", "all").option("--extension-id <id>", "installed Chrome extension id to use for direct handoff").option("--install-url <url>", "fallback install/continue URL", _chunkUKBFNBDOcjs.DEFAULT_CHROME_INSTALL_URL).option("--cli-path <path>", "CLI binary path to register in the native host").option("--open", "open the install/continue page after installation", false).action(async (options) => {
|
|
441
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, void 0, process.cwd());
|
|
442
|
+
const launchSpec = _chunkUKBFNBDOcjs.resolveCliLaunchSpec.call(void 0, options.cliPath);
|
|
443
|
+
const browsers = _chunkUKBFNBDOcjs.normalizeBrowsers.call(void 0, options.browser);
|
|
444
|
+
const extensionId = _nullishCoalesce(options.extensionId, () => ( _optionalChain([config, 'access', _14 => _14.chrome, 'optionalAccess', _15 => _15.extensionId])));
|
|
445
|
+
const preferredBrowser = options.browser === "all" ? _nullishCoalesce(_optionalChain([config, 'access', _16 => _16.chrome, 'optionalAccess', _17 => _17.browser]), () => ( "auto")) : options.browser;
|
|
446
|
+
const installUrl = _nullishCoalesce(_nullishCoalesce(options.installUrl, () => ( _optionalChain([config, 'access', _18 => _18.chrome, 'optionalAccess', _19 => _19.installUrl]))), () => ( _chunkUKBFNBDOcjs.DEFAULT_CHROME_INSTALL_URL));
|
|
447
|
+
const detectedProfile = extensionId ? await _chunkUKBFNBDOcjs.detectExtensionProfile.call(void 0, extensionId, browsers) : null;
|
|
448
|
+
const result = await _chunkUKBFNBDOcjs.installNativeHost.call(void 0, {
|
|
399
449
|
cliCommand: launchSpec.command,
|
|
400
450
|
cliArgPrefix: launchSpec.args,
|
|
401
451
|
extensionIds: extensionId ? [extensionId] : [],
|
|
402
452
|
browsers
|
|
403
453
|
});
|
|
404
|
-
|
|
454
|
+
_chunkUKBFNBDOcjs.applyChromeSettings.call(void 0, config, {
|
|
405
455
|
extensionId,
|
|
406
|
-
browser: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess',
|
|
407
|
-
userDataDir: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess',
|
|
408
|
-
profileDirectory: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess',
|
|
456
|
+
browser: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess', _20 => _20.browser]), () => ( preferredBrowser)),
|
|
457
|
+
userDataDir: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess', _21 => _21.userDataDir]), () => ( _optionalChain([config, 'access', _22 => _22.chrome, 'optionalAccess', _23 => _23.userDataDir]))),
|
|
458
|
+
profileDirectory: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess', _24 => _24.profileDirectory]), () => ( _optionalChain([config, 'access', _25 => _25.chrome, 'optionalAccess', _26 => _26.profileDirectory]))),
|
|
409
459
|
installUrl
|
|
410
460
|
});
|
|
411
|
-
await
|
|
461
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
412
462
|
console.log(_chalk2.default.green("\nInstalled Autohand Chrome bridge."));
|
|
413
463
|
for (const target of result.targets) {
|
|
414
464
|
console.log(_chalk2.default.gray(` ${target.browser}: ${target.manifestPath}`));
|
|
415
465
|
}
|
|
416
466
|
if (options.open) {
|
|
417
|
-
await
|
|
418
|
-
|
|
419
|
-
_nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess',
|
|
467
|
+
await _chunkUKBFNBDOcjs.openChromeContinuation.call(void 0,
|
|
468
|
+
_chunkUKBFNBDOcjs.buildChromeOpenUrl.call(void 0, { extensionId, installUrl }),
|
|
469
|
+
_nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess', _27 => _27.browser]), () => ( preferredBrowser)),
|
|
420
470
|
{
|
|
421
|
-
userDataDir: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess',
|
|
422
|
-
profileDirectory: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess',
|
|
471
|
+
userDataDir: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess', _28 => _28.userDataDir]), () => ( _optionalChain([config, 'access', _29 => _29.chrome, 'optionalAccess', _30 => _30.userDataDir]))),
|
|
472
|
+
profileDirectory: _nullishCoalesce(_optionalChain([detectedProfile, 'optionalAccess', _31 => _31.profileDirectory]), () => ( _optionalChain([config, 'access', _32 => _32.chrome, 'optionalAccess', _33 => _33.profileDirectory])))
|
|
423
473
|
}
|
|
424
474
|
);
|
|
425
475
|
}
|
|
@@ -440,27 +490,47 @@ if (process.stdout.isTTY) {
|
|
|
440
490
|
process.stdout.write("\x1B]0;Autohand Code\x07");
|
|
441
491
|
}
|
|
442
492
|
process.env.AUTOHAND_CODE = "1";
|
|
493
|
+
function applyCliModelOverride(config, model) {
|
|
494
|
+
const providerName = _nullishCoalesce(config.provider, () => ( "openrouter"));
|
|
495
|
+
if (_chunkEK34UZPBcjs.isCustomProviderName.call(void 0, providerName)) {
|
|
496
|
+
const customProvider = _chunkEK34UZPBcjs.getCustomProviderConfig.call(void 0, config, providerName);
|
|
497
|
+
if (customProvider) {
|
|
498
|
+
config.customProviders = {
|
|
499
|
+
...config.customProviders,
|
|
500
|
+
[customProvider.id]: {
|
|
501
|
+
...customProvider,
|
|
502
|
+
model
|
|
503
|
+
}
|
|
504
|
+
};
|
|
505
|
+
}
|
|
506
|
+
return;
|
|
507
|
+
}
|
|
508
|
+
const providerConfig = config[providerName];
|
|
509
|
+
if (providerConfig) {
|
|
510
|
+
providerConfig.model = model;
|
|
511
|
+
}
|
|
512
|
+
}
|
|
443
513
|
function getCommitFromAlphaVersion(version) {
|
|
444
514
|
const match = version.match(/-alpha\.([0-9a-f]{7,40})$/i);
|
|
445
|
-
return _nullishCoalesce(_optionalChain([match, 'optionalAccess',
|
|
515
|
+
return _nullishCoalesce(_optionalChain([match, 'optionalAccess', _34 => _34[1]]), () => ( null));
|
|
446
516
|
}
|
|
447
517
|
function getGitCommit() {
|
|
448
518
|
if (true) {
|
|
449
|
-
return "
|
|
519
|
+
return "1d7b7b1";
|
|
450
520
|
}
|
|
451
|
-
const alphaCommit = getCommitFromAlphaVersion(
|
|
521
|
+
const alphaCommit = getCommitFromAlphaVersion(_chunkCSUGNNJYcjs.package_default.version);
|
|
452
522
|
if (alphaCommit) {
|
|
453
523
|
return alphaCommit;
|
|
454
524
|
}
|
|
455
525
|
try {
|
|
456
526
|
return _child_process.execSync.call(void 0, "git rev-parse --short HEAD", { encoding: "utf8", stdio: ["pipe", "pipe", "ignore"] }).trim();
|
|
457
|
-
} catch (
|
|
527
|
+
} catch (e9) {
|
|
458
528
|
return "unknown";
|
|
459
529
|
}
|
|
460
530
|
}
|
|
461
531
|
function getVersionString() {
|
|
462
532
|
const commit = getGitCommit();
|
|
463
|
-
return `${
|
|
533
|
+
return `${_chunkCSUGNNJYcjs.package_default.version} (${commit})`;
|
|
464
534
|
}
|
|
465
535
|
function normalizeMcpScope(scopeInput) {
|
|
466
536
|
const scope = (_nullishCoalesce(scopeInput, () => ( "user"))).toLowerCase();
|
|
@@ -470,7 +540,7 @@ function normalizeMcpScope(scopeInput) {
|
|
|
470
540
|
return null;
|
|
471
541
|
}
|
|
472
542
|
async function resolveProjectConfigPath(workspaceRoot) {
|
|
473
|
-
const projectConfigDir = _path2.default.join(workspaceRoot,
|
|
543
|
+
const projectConfigDir = _path2.default.join(workspaceRoot, _chunk3JURXAL6cjs.PROJECT_DIR_NAME);
|
|
474
544
|
const tomlPath = _path2.default.join(projectConfigDir, "config.toml");
|
|
475
545
|
const yamlPath = _path2.default.join(projectConfigDir, "config.yaml");
|
|
476
546
|
const ymlPath = _path2.default.join(projectConfigDir, "config.yml");
|
|
@@ -486,44 +556,15 @@ async function loadConfigForMcpScope(scopeInput) {
|
|
|
486
556
|
throw new Error(`Invalid scope "${scopeInput}". Use: user or project.`);
|
|
487
557
|
}
|
|
488
558
|
if (scope === "user") {
|
|
489
|
-
return { config: await
|
|
559
|
+
return { config: await _chunkCNQKIWIScjs.loadConfig.call(void 0, ), scope };
|
|
490
560
|
}
|
|
491
561
|
const projectConfigPath = await resolveProjectConfigPath(process.cwd());
|
|
492
|
-
return { config: await
|
|
493
|
-
}
|
|
494
|
-
async function validateAuthOnStartup(config) {
|
|
495
|
-
if (!_optionalChain([config, 'access', _29 => _29.auth, 'optionalAccess', _30 => _30.token])) {
|
|
496
|
-
return void 0;
|
|
497
|
-
}
|
|
498
|
-
if (config.auth.expiresAt) {
|
|
499
|
-
const expiresAt = new Date(config.auth.expiresAt);
|
|
500
|
-
if (expiresAt < /* @__PURE__ */ new Date()) {
|
|
501
|
-
config.auth = void 0;
|
|
502
|
-
try {
|
|
503
|
-
await _chunkX5P6QQOBcjs.saveConfig.call(void 0, config);
|
|
504
|
-
} catch (e7) {
|
|
505
|
-
}
|
|
506
|
-
return void 0;
|
|
507
|
-
}
|
|
508
|
-
}
|
|
509
|
-
try {
|
|
510
|
-
const authClient = _chunkCO2AADYUcjs.getAuthClient.call(void 0, );
|
|
511
|
-
const result = await authClient.validateSession(config.auth.token);
|
|
512
|
-
if (result.authenticated) {
|
|
513
|
-
if (result.user && config.auth) {
|
|
514
|
-
config.auth.user = result.user;
|
|
515
|
-
}
|
|
516
|
-
return _optionalChain([config, 'access', _31 => _31.auth, 'optionalAccess', _32 => _32.user]);
|
|
517
|
-
}
|
|
518
|
-
return _optionalChain([config, 'access', _33 => _33.auth, 'optionalAccess', _34 => _34.user]);
|
|
519
|
-
} catch (e8) {
|
|
520
|
-
return _optionalChain([config, 'access', _35 => _35.auth, 'optionalAccess', _36 => _36.user]);
|
|
521
|
-
}
|
|
562
|
+
return { config: await _chunkCNQKIWIScjs.loadConfig.call(void 0, projectConfigPath, process.cwd()), scope };
|
|
522
563
|
}
|
|
523
|
-
|
|
564
|
+
_chunk5YRXFBYZcjs.installProcessErrorHandlers.call(void 0, );
|
|
524
565
|
var program = new (0, _commander.Command)();
|
|
525
566
|
registerChromeCommand(program);
|
|
526
|
-
program.name("autohand").description("Autonomous coding agent").version(getVersionString(), "-v, --version", "output the current version").argument("[prompt]", "Run a single instruction in command mode (same as -p)").option("-p, --prompt [text]", "Run a single instruction in command mode").option("--path <path>", "Workspace path to operate in").option("-y, --yes", "Auto-confirm risky actions", false).option("--dry-run", "Preview actions without applying mutations", false).option("-d, --debug", "Enable debug output (verbose logging)", false).option("--model <model>", "Override the configured LLM model").option("--config <path>", "Path to config file (default ~/.autohand/config.json)").option("--temperature <value>", "Sampling temperature", parseFloat).option("--thinking [level]", "Set thinking/reasoning depth (none, normal, extended)").option("-c, --auto-commit", "Auto-commit with LLM-generated message (runs lint & test first)", false).option("--unrestricted", "Run without any approval prompts (use with caution)", false).option("--restricted", "Deny all dangerous operations automatically", false).option("--goal [input]", "Run /goal non-interactively (status when omitted, otherwise same arguments as /goal)").option("--auto-skill", "Auto-generate skills based on project analysis", false).option("--learn", "Run /learn skill advisor non-interactively (analyze and install recommended skills)", false).option("--learn-update", "Re-analyze project and regenerate outdated LLM-generated skills", false).option("--skill-install [skill-name]", "Install a community skill (opens browser if no name)").option("--project", "Install skill to project level (with --skill-install)", false).option("--permissions", "Display current permission settings and exit", false).option("--settings", "Configure Autohand settings (same as /settings in interactive mode)", false).option("--login", "Sign in to your Autohand account", false).option("--logout", "Sign out of your Autohand account", false).option("--sync-settings [bool]", "Enable/disable settings sync (default: true for logged users)").option("--patch", "Generate git patch without applying changes (requires --prompt)", false).option("--output <file>", "Output file for patch (default: stdout, used with --patch)").option("--mode <mode>", "Run mode: interactive (default), rpc, or acp", "interactive").option("--acp", "Shorthand for --mode acp (Agent Client Protocol over stdio)", false).option("--teammate-mode <mode>", "Team display mode: auto, in-process, or tmux").option("--worktree [name]", "Run session in isolated git worktree (optional name)").option("--tmux", "Launch in a dedicated tmux session (implies --worktree)").option("--auto-mode [prompt]", "Enable interactive auto-mode, or start a standalone loop with an inline task").option("--max-iterations <n>", "Max auto-mode iterations (default: 50)", parseInt).option("--completion-promise <text>", 'Completion marker text (default: "DONE")').option("--no-worktree", "Disable git worktree isolation in auto-mode").option("--checkpoint-interval <n>", "Git commit every N iterations (default: 5)", parseInt).option("--max-runtime <m>", "Max runtime in minutes (default: 120)", parseInt).option("--max-cost <d>", "Max API cost in dollars (default: 10)", parseFloat).option("--interactive-on-complete", "After auto-mode ends, hand off directly to interactive mode (TTY only)", false).option("--setup", "Run the setup wizard to configure or reconfigure Autohand", false).option("--about", "Show information about Autohand", false).option("--feedback", "Submit feedback", false).option("--add-dir <path...>", "Add additional directories to workspace scope (can be used multiple times)").option("--display-language <locale>", "Set display language (e.g., en, id, zh-cn, fr, de, ja)").option("--cc, --context-compact", "Enable context compaction (default: on)").option("--no-cc, --no-context-compact", "Disable context compaction").option("--search-engine <provider>", "Set web search provider (google, brave, duckduckgo, parallel)").option("--sys-prompt <value>", "Replace entire system prompt (inline string or file path)").option("--append-sys-prompt <value>", "Append to system prompt (inline string or file path)").option("--yolo [pattern]", "Auto-approve tool calls matching pattern (e.g., allow:read,write or deny:delete)").option("--timeout <seconds>", "Timeout in seconds for auto-approve mode", parseInt).option("--chrome", "Enable Chrome browser integration (same as /chrome)").option("--no-chrome", "Disable Chrome browser integration").action(async (positionalPrompt, opts) => {
|
|
567
|
+
program.name("autohand").description("Autonomous coding agent").version(getVersionString(), "-v, --version", "output the current version").argument("[prompt]", "Run a single instruction in command mode (same as -p)").option("-p, --prompt [text]", "Run a single instruction in command mode").option("--bare", "Minimal mode: skip hooks, LSP, plugin sync, attribution, auto-memory, background prefetches, keychain reads, and AGENTS.md auto-discovery", false).option("--path <path>", "Workspace path to operate in").option("-y, --yes", "Auto-confirm risky actions", false).option("--dry-run", "Preview actions without applying mutations", false).option("-d, --debug", "Enable debug output (verbose logging)", false).option("--model <model>", "Override the configured LLM model").option("--config <path>", "Path to config file (default ~/.autohand/config.json)").option("--temperature <value>", "Sampling temperature", parseFloat).option("--thinking [level]", "Set thinking/reasoning depth (none, normal, extended)").option("-c, --auto-commit", "Auto-commit with LLM-generated message (runs lint & test first)", false).option("--unrestricted", "Run without any approval prompts (use with caution)", false).option("--restricted", "Deny all dangerous operations automatically", false).option("--no-idle-logout", "Disable authenticated idle logout for long-running agent sessions").option("--goal [input]", "Run /goal non-interactively (status when omitted, otherwise same arguments as /goal)").option("--auto-skill", "Auto-generate skills based on project analysis", false).option("--learn", "Run /learn skill advisor non-interactively (analyze and install recommended skills)", false).option("--learn-update", "Re-analyze project and regenerate outdated LLM-generated skills", false).option("--skill-install [skill-name]", "Install a community skill (opens browser if no name)").option("--project", "Install skill to project level (with --skill-install)", false).option("--permissions", "Display current permission settings and exit", false).option("--settings", "Configure Autohand settings (same as /settings in interactive mode)", false).option("--login", "Sign in to your Autohand account", false).option("--logout", "Sign out of your Autohand account", false).option("--sync-settings [bool]", "Enable/disable settings sync (default: true for logged users)").option("--patch", "Generate git patch without applying changes (requires --prompt)", false).option("--output <file>", "Output file for patch (default: stdout, used with --patch)").option("--mode <mode>", "Run mode: interactive (default), rpc, or acp", "interactive").option("--acp", "Shorthand for --mode acp (Agent Client Protocol over stdio)", false).option("--teammate-mode <mode>", "Team display mode: auto, in-process, or tmux").option("--worktree [name]", "Run session in isolated git worktree (optional name)").option("--tmux", "Launch in a dedicated tmux session (implies --worktree)").option("--auto-mode [prompt]", "Enable interactive auto-mode, or start a standalone loop with an inline task").option("--max-iterations <n>", "Max auto-mode iterations (default: 50)", parseInt).option("--completion-promise <text>", 'Completion marker text (default: "DONE")').option("--no-worktree", "Disable git worktree isolation in auto-mode").option("--checkpoint-interval <n>", "Git commit every N iterations (default: 5)", parseInt).option("--max-runtime <m>", "Max runtime in minutes (default: 120)", parseInt).option("--max-cost <d>", "Max API cost in dollars (default: 10)", parseFloat).option("--interactive-on-complete", "After auto-mode ends, hand off directly to interactive mode (TTY only)", false).option("--setup", "Run the setup wizard to configure or reconfigure Autohand", false).option("--about", "Show information about Autohand", false).option("--feedback", "Submit feedback", false).option("--add-dir <path...>", "Add additional directories to workspace scope (can be used multiple times)").option("--display-language <locale>", "Set display language (e.g., en, id, zh-cn, fr, de, ja)").option("--cc, --context-compact", "Enable context compaction (default: on)").option("--no-cc, --no-context-compact", "Disable context compaction").option("--search-engine <provider>", "Set web search provider (google, brave, duckduckgo, parallel)").option("--sys-prompt <value>", "Replace entire system prompt (inline string or file path)").option("--system-prompt <value>", "Replace entire system prompt (inline string or file path)").option("--system-prompt-file <path>", "Replace entire system prompt with file contents").option("--append-sys-prompt <value>", "Append to system prompt (inline string or file path)").option("--append-system-prompt <value>", "Append to system prompt (inline string or file path)").option("--append-system-prompt-file <path>", "Append file contents to system prompt").option("--mcp-config <path>", "Explicit MCP config file").option("--agents <json|path>", 'Custom agents as inline JSON ({"reviewer":{"description":"...","prompt":"..."}}) or an external agents directory').option("--plugin-dir <path>", "Explicit plugin/meta-tool directory").option("--yolo [pattern]", "Auto-approve tool calls matching pattern (e.g., allow:read,write or deny:delete)").option("--timeout <seconds>", "Timeout in seconds for auto-approve mode", parseInt).option("--chrome", "Enable Chrome browser integration (same as /chrome)").option("--no-chrome", "Disable Chrome browser integration").option("--fork <pathOrId>", "Create and resume a new session branch from an existing session reference").action(async (positionalPrompt, opts) => {
|
|
527
568
|
if (process.stdout.isTTY && process.env.AUTOHAND_NO_BANNER !== "1") {
|
|
528
569
|
process.stdout.write("\x1B[3J\x1B[2J\x1B[H");
|
|
529
570
|
}
|
|
@@ -536,6 +577,32 @@ program.name("autohand").description("Autonomous coding agent").version(getVersi
|
|
|
536
577
|
if (opts.goal === true) {
|
|
537
578
|
opts.goal = "";
|
|
538
579
|
}
|
|
580
|
+
if (opts.systemPrompt) {
|
|
581
|
+
opts.sysPrompt = String(opts.systemPrompt);
|
|
582
|
+
}
|
|
583
|
+
if (opts.systemPromptFile) {
|
|
584
|
+
opts.sysPrompt = opts.systemPromptFile;
|
|
585
|
+
}
|
|
586
|
+
if (opts.appendSystemPrompt) {
|
|
587
|
+
opts.appendSysPrompt = String(opts.appendSystemPrompt);
|
|
588
|
+
}
|
|
589
|
+
if (opts.appendSystemPromptFile) {
|
|
590
|
+
opts.appendSysPrompt = opts.appendSystemPromptFile;
|
|
591
|
+
}
|
|
592
|
+
if (opts.bare) {
|
|
593
|
+
process.env.AUTOHAND_CODE_SIMPLE = "1";
|
|
594
|
+
opts.syncSettings = false;
|
|
595
|
+
opts.contextCompact = false;
|
|
596
|
+
opts.noChrome = true;
|
|
597
|
+
}
|
|
598
|
+
if (typeof opts.agents === "string" && _chunk3KWAP2Y3cjs.looksLikeInlineAgents.call(void 0, opts.agents)) {
|
|
599
|
+
try {
|
|
600
|
+
opts.inlineAgents = _chunk3KWAP2Y3cjs.parseInlineAgents.call(void 0, opts.agents);
|
|
601
|
+
} catch (error) {
|
|
602
|
+
console.error(_chalk2.default.red(`Invalid --agents JSON: ${error.message}`));
|
|
603
|
+
process.exit(1);
|
|
604
|
+
}
|
|
605
|
+
}
|
|
539
606
|
if (positionalPrompt && !opts.prompt) {
|
|
540
607
|
opts.prompt = positionalPrompt;
|
|
541
608
|
}
|
|
@@ -571,44 +638,44 @@ program.name("autohand").description("Autonomous coding agent").version(getVersi
|
|
|
571
638
|
return;
|
|
572
639
|
}
|
|
573
640
|
if (opts.settings) {
|
|
574
|
-
const config = await
|
|
575
|
-
const { settings } = await Promise.resolve().then(() => _interopRequireWildcard(require("./settings-
|
|
641
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config, process.cwd());
|
|
642
|
+
const { settings } = await Promise.resolve().then(() => _interopRequireWildcard(require("./settings-RL4KNWHB.cjs")));
|
|
576
643
|
await settings({ config });
|
|
577
644
|
process.exit(0);
|
|
578
645
|
}
|
|
579
646
|
if (opts.login) {
|
|
580
|
-
const { login } = await Promise.resolve().then(() => _interopRequireWildcard(require("./login-
|
|
581
|
-
const config = await
|
|
647
|
+
const { login } = await Promise.resolve().then(() => _interopRequireWildcard(require("./login-NABQYLYC.cjs")));
|
|
648
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config);
|
|
582
649
|
await login({ config });
|
|
583
650
|
process.exit(0);
|
|
584
651
|
}
|
|
585
652
|
if (opts.logout) {
|
|
586
|
-
const { logout } = await Promise.resolve().then(() => _interopRequireWildcard(require("./logout-
|
|
587
|
-
const config = await
|
|
653
|
+
const { logout } = await Promise.resolve().then(() => _interopRequireWildcard(require("./logout-SKGDXJSW.cjs")));
|
|
654
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config);
|
|
588
655
|
await logout({ config });
|
|
589
656
|
process.exit(0);
|
|
590
657
|
}
|
|
591
658
|
if (opts.about) {
|
|
592
|
-
const { initI18n: initI18n2, detectLocale: detectLocale2 } = await Promise.resolve().then(() => _interopRequireWildcard(require("./i18n-
|
|
593
|
-
const { about } = await Promise.resolve().then(() => _interopRequireWildcard(require("./about-
|
|
659
|
+
const { initI18n: initI18n2, detectLocale: detectLocale2 } = await Promise.resolve().then(() => _interopRequireWildcard(require("./i18n-MFAEU5RV.cjs")));
|
|
660
|
+
const { about } = await Promise.resolve().then(() => _interopRequireWildcard(require("./about-U2BH7HDR.cjs")));
|
|
594
661
|
const { locale } = detectLocale2();
|
|
595
662
|
await initI18n2(locale);
|
|
596
|
-
const config = await
|
|
663
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config);
|
|
597
664
|
await about({ config });
|
|
598
665
|
process.exit(0);
|
|
599
666
|
}
|
|
600
667
|
if (opts.feedback) {
|
|
601
|
-
const { initI18n: initI18n2, detectLocale: detectLocale2 } = await Promise.resolve().then(() => _interopRequireWildcard(require("./i18n-
|
|
602
|
-
const { feedback } = await Promise.resolve().then(() => _interopRequireWildcard(require("./feedback-
|
|
668
|
+
const { initI18n: initI18n2, detectLocale: detectLocale2 } = await Promise.resolve().then(() => _interopRequireWildcard(require("./i18n-MFAEU5RV.cjs")));
|
|
669
|
+
const { feedback } = await Promise.resolve().then(() => _interopRequireWildcard(require("./feedback-CEOJ3453.cjs")));
|
|
603
670
|
const { locale } = detectLocale2();
|
|
604
671
|
await initI18n2(locale);
|
|
605
|
-
const config = await
|
|
672
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config);
|
|
606
673
|
await feedback({ config });
|
|
607
674
|
process.exit(0);
|
|
608
675
|
}
|
|
609
676
|
if (opts.setup) {
|
|
610
|
-
const config = await
|
|
611
|
-
const workspaceRoot =
|
|
677
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config, process.cwd());
|
|
678
|
+
const workspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, opts.path);
|
|
612
679
|
const workspacePathValidation = await _chunkQLZOMZO5cjs.validateWorkspacePath.call(void 0, workspaceRoot);
|
|
613
680
|
if (!workspacePathValidation.valid) {
|
|
614
681
|
console.error(_chalk2.default.red(`Error: ${workspacePathValidation.error}`));
|
|
@@ -619,7 +686,7 @@ program.name("autohand").description("Autonomous coding agent").version(getVersi
|
|
|
619
686
|
_chunkWGNMOVMTcjs.printDangerousWorkspaceWarning.call(void 0, workspaceRoot, safetyCheck);
|
|
620
687
|
process.exit(1);
|
|
621
688
|
}
|
|
622
|
-
const { SetupWizard } = await Promise.resolve().then(() => _interopRequireWildcard(require("./onboarding-
|
|
689
|
+
const { SetupWizard } = await Promise.resolve().then(() => _interopRequireWildcard(require("./onboarding-5DZFCO5Q.cjs")));
|
|
623
690
|
const wizard = new SetupWizard(workspaceRoot, config);
|
|
624
691
|
const result = await wizard.run({ skipWelcome: false });
|
|
625
692
|
if (result.cancelled) {
|
|
@@ -628,14 +695,24 @@ program.name("autohand").description("Autonomous coding agent").version(getVersi
|
|
|
628
695
|
}
|
|
629
696
|
if (result.success) {
|
|
630
697
|
const newConfig = { ...config, ...result.config };
|
|
631
|
-
await
|
|
698
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, newConfig);
|
|
632
699
|
console.log(_chalk2.default.green("\nSetup complete! Run `autohand` to start."));
|
|
633
700
|
}
|
|
634
701
|
process.exit(0);
|
|
635
702
|
}
|
|
703
|
+
if (opts.mode === "rpc") {
|
|
704
|
+
const { runRpcMode } = await Promise.resolve().then(() => _interopRequireWildcard(require("./rpc-O36WUU3L.cjs")));
|
|
705
|
+
await runRpcMode(opts);
|
|
706
|
+
return;
|
|
707
|
+
}
|
|
708
|
+
if (opts.mode === "acp") {
|
|
709
|
+
const { runAcpMode } = await Promise.resolve().then(() => _interopRequireWildcard(require("./acp-S37JOBCS.cjs")));
|
|
710
|
+
await runAcpMode(opts);
|
|
711
|
+
return;
|
|
712
|
+
}
|
|
636
713
|
{
|
|
637
|
-
const preAuthConfig = await
|
|
638
|
-
const workspaceRoot =
|
|
714
|
+
const preAuthConfig = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config, process.cwd());
|
|
715
|
+
const workspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, preAuthConfig, opts.path);
|
|
639
716
|
const workspacePathValidation = await _chunkQLZOMZO5cjs.validateWorkspacePath.call(void 0, workspaceRoot);
|
|
640
717
|
if (!workspacePathValidation.valid) {
|
|
641
718
|
console.error(_chalk2.default.red(`Error: ${workspacePathValidation.error}`));
|
|
@@ -648,8 +725,8 @@ program.name("autohand").description("Autonomous coding agent").version(getVersi
|
|
|
648
725
|
}
|
|
649
726
|
}
|
|
650
727
|
{
|
|
651
|
-
let authConfig = await
|
|
652
|
-
authConfig = await
|
|
728
|
+
let authConfig = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config, process.cwd());
|
|
729
|
+
authConfig = await _chunkAZKOIF2Gcjs.ensureAuthenticated.call(void 0, authConfig, { bare: opts.bare === true });
|
|
653
730
|
opts._authConfig = authConfig;
|
|
654
731
|
}
|
|
655
732
|
if (opts.patch) {
|
|
@@ -666,10 +743,10 @@ program.name("autohand").description("Autonomous coding agent").version(getVersi
|
|
|
666
743
|
}
|
|
667
744
|
}
|
|
668
745
|
if (opts.noChrome) {
|
|
669
|
-
const config = await
|
|
746
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config, process.cwd());
|
|
670
747
|
if (config.chrome) {
|
|
671
748
|
config.chrome.enabledByDefault = false;
|
|
672
|
-
await
|
|
749
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
673
750
|
console.log(_chalk2.default.green("\u2713 Chrome browser integration disabled."));
|
|
674
751
|
}
|
|
675
752
|
}
|
|
@@ -682,18 +759,8 @@ program.name("autohand").description("Autonomous coding agent").version(getVersi
|
|
|
682
759
|
process.exit(1);
|
|
683
760
|
}
|
|
684
761
|
}
|
|
685
|
-
if (opts.mode === "rpc") {
|
|
686
|
-
const { runRpcMode } = await Promise.resolve().then(() => _interopRequireWildcard(require("./rpc-YF54T7JU.cjs")));
|
|
687
|
-
await runRpcMode(opts);
|
|
688
|
-
return;
|
|
689
|
-
}
|
|
690
|
-
if (opts.mode === "acp") {
|
|
691
|
-
const { runAcpMode } = await Promise.resolve().then(() => _interopRequireWildcard(require("./acp-GSYE75OB.cjs")));
|
|
692
|
-
await runAcpMode(opts);
|
|
693
|
-
return;
|
|
694
|
-
}
|
|
695
762
|
if (opts.mode === "teammate") {
|
|
696
|
-
const { parseTeammateOptions, runTeammateMode } = await Promise.resolve().then(() => _interopRequireWildcard(require("./teammate-
|
|
763
|
+
const { parseTeammateOptions, runTeammateMode } = await Promise.resolve().then(() => _interopRequireWildcard(require("./teammate-EXR76PEQ.cjs")));
|
|
697
764
|
const teammateOpts = parseTeammateOptions(process.argv);
|
|
698
765
|
if (!teammateOpts) {
|
|
699
766
|
console.error("Error: --mode teammate requires --team, --name, --agent, and --lead-session");
|
|
@@ -724,37 +791,73 @@ program.name("autohand").description("Autonomous coding agent").version(getVersi
|
|
|
724
791
|
await runCLI(opts);
|
|
725
792
|
});
|
|
726
793
|
program.command("resume <sessionId>").description("Resume a previous session").option("--path <path>", "Workspace path to operate in").option("--model <model>", "Override the configured LLM model").action(async (sessionId, opts) => {
|
|
727
|
-
let authConfig = await
|
|
728
|
-
authConfig = await
|
|
794
|
+
let authConfig = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config, process.cwd());
|
|
795
|
+
authConfig = await _chunkAZKOIF2Gcjs.ensureAuthenticated.call(void 0, authConfig);
|
|
729
796
|
opts._authConfig = authConfig;
|
|
730
797
|
await runCLI({ ...opts, resumeSessionId: sessionId });
|
|
731
798
|
});
|
|
732
799
|
program.command("login").description("Sign in to your Autohand account").action(async () => {
|
|
733
|
-
const { login } = await Promise.resolve().then(() => _interopRequireWildcard(require("./login-
|
|
734
|
-
const config = await
|
|
800
|
+
const { login } = await Promise.resolve().then(() => _interopRequireWildcard(require("./login-NABQYLYC.cjs")));
|
|
801
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, );
|
|
735
802
|
await login({ config });
|
|
736
803
|
process.exit(0);
|
|
737
804
|
});
|
|
738
805
|
program.command("logout").description("Sign out of your Autohand account").action(async () => {
|
|
739
|
-
const { logout } = await Promise.resolve().then(() => _interopRequireWildcard(require("./logout-
|
|
740
|
-
const config = await
|
|
806
|
+
const { logout } = await Promise.resolve().then(() => _interopRequireWildcard(require("./logout-SKGDXJSW.cjs")));
|
|
807
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, );
|
|
741
808
|
await logout({ config });
|
|
742
809
|
process.exit(0);
|
|
743
810
|
});
|
|
811
|
+
program.command("squad [args...]").description("Start and manage the standalone Autohand Squad runtime").allowUnknownOption(true).allowExcessArguments(true).action(async (args = []) => {
|
|
812
|
+
const rootOptions = program.opts();
|
|
813
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, rootOptions.config, process.cwd());
|
|
814
|
+
const workspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, rootOptions.path);
|
|
815
|
+
const { runSquadCommand } = await Promise.resolve().then(() => _interopRequireWildcard(require("./squad-PIIYDFVH.cjs")));
|
|
816
|
+
const result = await runSquadCommand({ workspaceRoot, config }, args);
|
|
817
|
+
if (result.output) {
|
|
818
|
+
if (result.code === 0) {
|
|
819
|
+
console.log(result.output);
|
|
820
|
+
} else {
|
|
821
|
+
console.error(result.output);
|
|
822
|
+
}
|
|
823
|
+
}
|
|
824
|
+
process.exit(result.code);
|
|
825
|
+
});
|
|
826
|
+
program.command("queue [args...]").description("Show the local Autohand Squad queue").allowUnknownOption(true).allowExcessArguments(true).action(async (args = []) => {
|
|
827
|
+
const rootOptions = program.opts();
|
|
828
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, rootOptions.config, process.cwd());
|
|
829
|
+
const workspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, rootOptions.path);
|
|
830
|
+
const { runSquadCommand } = await Promise.resolve().then(() => _interopRequireWildcard(require("./squad-PIIYDFVH.cjs")));
|
|
831
|
+
const result = await runSquadCommand({ workspaceRoot, config }, ["queue", ...args]);
|
|
832
|
+
if (result.output) {
|
|
833
|
+
if (result.code === 0) {
|
|
834
|
+
console.log(result.output);
|
|
835
|
+
} else {
|
|
836
|
+
console.error(result.output);
|
|
837
|
+
}
|
|
838
|
+
}
|
|
839
|
+
process.exit(result.code);
|
|
840
|
+
});
|
|
744
841
|
var configCmd = program.command("config").description("Configure Autohand settings").action(async () => {
|
|
745
|
-
const config = await
|
|
746
|
-
const { settings } = await Promise.resolve().then(() => _interopRequireWildcard(require("./settings-
|
|
842
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, program.opts().config);
|
|
843
|
+
const { settings } = await Promise.resolve().then(() => _interopRequireWildcard(require("./settings-RL4KNWHB.cjs")));
|
|
747
844
|
await settings({ config });
|
|
748
845
|
process.exit(0);
|
|
749
846
|
});
|
|
750
847
|
configCmd.command("set <parts...>").description("Set a config value, e.g. autohand config set verbs activity false").action(async (parts) => {
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
848
|
+
try {
|
|
849
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, program.opts().config);
|
|
850
|
+
const { parseConfigSetArgs, setConfigSetting, formatConfigSetResult } = await Promise.resolve().then(() => _interopRequireWildcard(require("./settings-RL4KNWHB.cjs")));
|
|
851
|
+
const { key, value } = parseConfigSetArgs(parts);
|
|
852
|
+
const result = setConfigSetting(config, key, value);
|
|
853
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
854
|
+
console.log(_chalk2.default.green(formatConfigSetResult(result)));
|
|
855
|
+
process.exit(0);
|
|
856
|
+
} catch (error) {
|
|
857
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
858
|
+
console.error(_chalk2.default.red(message));
|
|
859
|
+
process.exit(1);
|
|
860
|
+
}
|
|
758
861
|
});
|
|
759
862
|
var mcpCmd = program.command("mcp").description("Manage MCP (Model Context Protocol) servers");
|
|
760
863
|
mcpCmd.command("add <name> <target> [args...]").description("Add an MCP server to config and auto-connect on next session").option("-t, --transport <transport>", "Transport type: stdio | http | sse", "stdio").option("-s, --scope <scope>", "Config scope: user | project", "user").action(async (name, target, serverArgs, options) => {
|
|
@@ -816,7 +919,7 @@ mcpCmd.command("add <name> <target> [args...]").description("Add an MCP server t
|
|
|
816
919
|
const wasAutoConnectDisabled = existing.autoConnect === false;
|
|
817
920
|
if (wasAutoConnectDisabled || wasMcpDisabled) {
|
|
818
921
|
existing.autoConnect = true;
|
|
819
|
-
await
|
|
922
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
820
923
|
const reenabledParts = [];
|
|
821
924
|
if (wasMcpDisabled) reenabledParts.push("MCP support");
|
|
822
925
|
if (wasAutoConnectDisabled) reenabledParts.push("auto-connect");
|
|
@@ -839,13 +942,13 @@ mcpCmd.command("add <name> <target> [args...]").description("Add an MCP server t
|
|
|
839
942
|
existing.args = void 0;
|
|
840
943
|
}
|
|
841
944
|
existing.autoConnect = true;
|
|
842
|
-
await
|
|
945
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
843
946
|
console.log(_chalk2.default.green(`Updated "${name}" in ${scope} config (${newServer.transport}: ${displayTarget})`));
|
|
844
947
|
console.log(_chalk2.default.gray("Server will use the new settings on next start."));
|
|
845
948
|
process.exit(0);
|
|
846
949
|
}
|
|
847
950
|
config.mcp.servers.push(newServer);
|
|
848
|
-
await
|
|
951
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
849
952
|
console.log(_chalk2.default.green(`Added "${name}" to ${scope} config (${newServer.transport}: ${displayTarget})`));
|
|
850
953
|
console.log(_chalk2.default.gray("Server will auto-connect when you start autohand."));
|
|
851
954
|
process.exit(0);
|
|
@@ -862,13 +965,13 @@ mcpCmd.command("remove <name>").description("Remove an MCP server from config").
|
|
|
862
965
|
process.exit(1);
|
|
863
966
|
return;
|
|
864
967
|
}
|
|
865
|
-
const serverIndex = _optionalChain([config, 'access',
|
|
968
|
+
const serverIndex = _optionalChain([config, 'access', _35 => _35.mcp, 'optionalAccess', _36 => _36.servers, 'optionalAccess', _37 => _37.findIndex, 'call', _38 => _38((s) => s.name === name)]);
|
|
866
969
|
if (serverIndex === void 0 || serverIndex < 0) {
|
|
867
970
|
console.log(_chalk2.default.yellow(`Server "${name}" not found in ${scope} config.`));
|
|
868
971
|
process.exit(1);
|
|
869
972
|
}
|
|
870
973
|
config.mcp.servers.splice(serverIndex, 1);
|
|
871
|
-
await
|
|
974
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
872
975
|
console.log(_chalk2.default.green(`Removed "${name}" from ${scope} config.`));
|
|
873
976
|
process.exit(0);
|
|
874
977
|
});
|
|
@@ -884,7 +987,7 @@ mcpCmd.command("list").description("List configured MCP servers").option("-s, --
|
|
|
884
987
|
process.exit(1);
|
|
885
988
|
return;
|
|
886
989
|
}
|
|
887
|
-
const servers = _nullishCoalesce(_optionalChain([config, 'access',
|
|
990
|
+
const servers = _nullishCoalesce(_optionalChain([config, 'access', _39 => _39.mcp, 'optionalAccess', _40 => _40.servers]), () => ( []));
|
|
888
991
|
if (servers.length === 0) {
|
|
889
992
|
console.log(_chalk2.default.gray(`No MCP servers configured in ${scope} config.`));
|
|
890
993
|
console.log(_chalk2.default.gray("Add one with: autohand mcp add <name> <command> [args...]"));
|
|
@@ -895,7 +998,7 @@ mcpCmd.command("list").description("List configured MCP servers").option("-s, --
|
|
|
895
998
|
Configured MCP Servers (${servers.length}, ${scope} config):
|
|
896
999
|
`));
|
|
897
1000
|
for (const server of servers) {
|
|
898
|
-
const target = server.transport === "stdio" ? `${server.command}${_optionalChain([server, 'access',
|
|
1001
|
+
const target = server.transport === "stdio" ? `${server.command}${_optionalChain([server, 'access', _41 => _41.args, 'optionalAccess', _42 => _42.length]) ? " " + server.args.join(" ") : ""}`.trim() : _nullishCoalesce(server.url, () => ( "<missing-url>"));
|
|
899
1002
|
const auto = server.autoConnect !== false ? _chalk2.default.green("auto-connect") : _chalk2.default.gray("manual");
|
|
900
1003
|
console.log(` ${_chalk2.default.white(server.name)} ${_chalk2.default.gray("\u2192")} ${server.transport}:${target} ${_chalk2.default.gray(`[${auto}]`)}`);
|
|
901
1004
|
}
|
|
@@ -914,48 +1017,48 @@ mcpCmd.command("install [server-name]").description("Browse and install communit
|
|
|
914
1017
|
}
|
|
915
1018
|
const { McpClientManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./McpClientManager-BNSKLHIN.cjs")));
|
|
916
1019
|
const manager = new McpClientManager();
|
|
917
|
-
const { mcpInstall } = await Promise.resolve().then(() => _interopRequireWildcard(require("./mcp-install-
|
|
1020
|
+
const { mcpInstall } = await Promise.resolve().then(() => _interopRequireWildcard(require("./mcp-install-2GKWWBAS.cjs")));
|
|
918
1021
|
const result = await mcpInstall({ mcpManager: manager, config }, serverName);
|
|
919
1022
|
if (result) console.log(result);
|
|
920
1023
|
await manager.disconnectAll().catch(() => {
|
|
921
1024
|
});
|
|
922
1025
|
process.exit(0);
|
|
923
1026
|
});
|
|
924
|
-
var
|
|
925
|
-
const { features } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-
|
|
926
|
-
const config = await
|
|
1027
|
+
var experimentsCmd = program.command("experiments").description("List and toggle Autohand experiments").action(async () => {
|
|
1028
|
+
const { features } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-LT55MURX.cjs")));
|
|
1029
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, program.opts().config);
|
|
927
1030
|
const result = await features({ config }, ["list"]);
|
|
928
1031
|
if (result) console.log(result);
|
|
929
1032
|
process.exit(0);
|
|
930
1033
|
});
|
|
931
|
-
|
|
932
|
-
const { features } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-
|
|
933
|
-
const config = await
|
|
1034
|
+
experimentsCmd.command("list").alias("ls").description("List experiments and current state").action(async () => {
|
|
1035
|
+
const { features } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-LT55MURX.cjs")));
|
|
1036
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, program.opts().config);
|
|
934
1037
|
const result = await features({ config }, ["list"]);
|
|
935
1038
|
if (result) console.log(result);
|
|
936
1039
|
process.exit(0);
|
|
937
1040
|
});
|
|
938
|
-
|
|
939
|
-
const { features } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-
|
|
940
|
-
const config = await
|
|
1041
|
+
experimentsCmd.command("status <feature>").alias("show").description("Show one experiment").action(async (featureId) => {
|
|
1042
|
+
const { features } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-LT55MURX.cjs")));
|
|
1043
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, program.opts().config);
|
|
941
1044
|
const result = await features({ config }, ["status", featureId]);
|
|
942
|
-
if (_optionalChain([result, 'optionalAccess',
|
|
1045
|
+
if (_optionalChain([result, 'optionalAccess', _43 => _43.startsWith, 'call', _44 => _44("Unknown feature")])) {
|
|
943
1046
|
console.log(_chalk2.default.red(result));
|
|
944
1047
|
process.exit(1);
|
|
945
1048
|
}
|
|
946
1049
|
if (result) console.log(result);
|
|
947
1050
|
process.exit(0);
|
|
948
1051
|
});
|
|
949
|
-
|
|
950
|
-
const { features } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-
|
|
951
|
-
const config = await
|
|
1052
|
+
experimentsCmd.command("refresh").description("Download remote feature flags from the Autohand API").action(async () => {
|
|
1053
|
+
const { features } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-LT55MURX.cjs")));
|
|
1054
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, program.opts().config);
|
|
952
1055
|
const result = await features({ config }, ["refresh"]);
|
|
953
1056
|
if (result) console.log(result);
|
|
954
1057
|
process.exit(0);
|
|
955
1058
|
});
|
|
956
|
-
|
|
957
|
-
const { setFeatureEnabled } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-
|
|
958
|
-
const config = await
|
|
1059
|
+
experimentsCmd.command("enable <feature>").description("Enable an experiment").action(async (featureId) => {
|
|
1060
|
+
const { setFeatureEnabled } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-LT55MURX.cjs")));
|
|
1061
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, program.opts().config);
|
|
959
1062
|
const result = await setFeatureEnabled(config, featureId, true);
|
|
960
1063
|
if (result.startsWith("Unknown feature")) {
|
|
961
1064
|
console.log(_chalk2.default.red(result));
|
|
@@ -964,9 +1067,9 @@ featuresCmd.command("enable <feature>").description("Enable a feature switch").a
|
|
|
964
1067
|
console.log(result);
|
|
965
1068
|
process.exit(0);
|
|
966
1069
|
});
|
|
967
|
-
|
|
968
|
-
const { setFeatureEnabled } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-
|
|
969
|
-
const config = await
|
|
1070
|
+
experimentsCmd.command("disable <feature>").description("Disable an experiment").action(async (featureId) => {
|
|
1071
|
+
const { setFeatureEnabled } = await Promise.resolve().then(() => _interopRequireWildcard(require("./features-LT55MURX.cjs")));
|
|
1072
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, program.opts().config);
|
|
970
1073
|
const result = await setFeatureEnabled(config, featureId, false);
|
|
971
1074
|
if (result.startsWith("Unknown feature")) {
|
|
972
1075
|
console.log(_chalk2.default.red(result));
|
|
@@ -976,62 +1079,49 @@ featuresCmd.command("disable <feature>").description("Disable a feature switch")
|
|
|
976
1079
|
process.exit(0);
|
|
977
1080
|
});
|
|
978
1081
|
program.command("sessions").description("List saved sessions").option("--project <name>", "Filter sessions by project name").action(async (opts) => {
|
|
979
|
-
const { SessionManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./SessionManager-
|
|
1082
|
+
const { SessionManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./SessionManager-LGPQIA57.cjs")));
|
|
980
1083
|
const sessionManager = new SessionManager();
|
|
981
1084
|
await sessionManager.initialize();
|
|
982
|
-
const { sessions } = await Promise.resolve().then(() => _interopRequireWildcard(require("./sessions-
|
|
1085
|
+
const { sessions } = await Promise.resolve().then(() => _interopRequireWildcard(require("./sessions-3JUOT3ED.cjs")));
|
|
983
1086
|
const args = opts.project ? ["--project", opts.project] : [];
|
|
984
1087
|
await sessions({ sessionManager, args });
|
|
985
1088
|
process.exit(0);
|
|
986
1089
|
});
|
|
987
1090
|
program.command("init").description("Create an AGENTS.md file in the workspace").option("--path <path>", "Workspace path").action(async (opts) => {
|
|
988
|
-
const config = await
|
|
989
|
-
const workspaceRoot =
|
|
1091
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, void 0, process.cwd());
|
|
1092
|
+
const workspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, opts.path);
|
|
990
1093
|
const agentsPath = _path2.default.join(workspaceRoot, "AGENTS.md");
|
|
991
1094
|
const exists = await _fsextra2.default.pathExists(agentsPath);
|
|
992
1095
|
if (exists) {
|
|
993
1096
|
console.log(_chalk2.default.yellow("AGENTS.md already exists in this workspace."));
|
|
994
1097
|
process.exit(0);
|
|
995
1098
|
}
|
|
996
|
-
const
|
|
997
|
-
|
|
998
|
-
"",
|
|
999
|
-
"## Project Context",
|
|
1000
|
-
"Describe your project here so the agent understands the codebase.",
|
|
1001
|
-
"",
|
|
1002
|
-
"## Coding Standards",
|
|
1003
|
-
"- List your coding conventions",
|
|
1004
|
-
"- Preferred patterns and practices",
|
|
1005
|
-
"",
|
|
1006
|
-
"## Important Files",
|
|
1007
|
-
"- `src/index.ts` - Entry point",
|
|
1008
|
-
""
|
|
1009
|
-
].join("\n");
|
|
1010
|
-
await _fsextra2.default.writeFile(agentsPath, template);
|
|
1099
|
+
const generator = new (0, _chunkCMEZ42F2cjs.AgentsGenerator)();
|
|
1100
|
+
await _fsextra2.default.writeFile(agentsPath, generator.generateContent({}));
|
|
1011
1101
|
console.log(_chalk2.default.green(`Created ${agentsPath}`));
|
|
1012
1102
|
process.exit(0);
|
|
1013
1103
|
});
|
|
1014
1104
|
program.command("completion <shell>").description("Generate shell completion scripts (bash, zsh, fish)").action(async (shell) => {
|
|
1015
|
-
const { runCompletionCommand } = await Promise.resolve().then(() => _interopRequireWildcard(require("./completion-
|
|
1105
|
+
const { runCompletionCommand } = await Promise.resolve().then(() => _interopRequireWildcard(require("./completion-G7Z436TF.cjs")));
|
|
1016
1106
|
await runCompletionCommand(shell);
|
|
1017
1107
|
process.exit(0);
|
|
1018
1108
|
});
|
|
1019
1109
|
program.command("update").description("Check for updates and install if available").option("--check", "Only check for updates without installing").action(async (opts) => {
|
|
1020
1110
|
const { runUpdate } = await Promise.resolve().then(() => _interopRequireWildcard(require("./update-NV6QRYY7.cjs")));
|
|
1021
1111
|
await runUpdate({
|
|
1022
|
-
currentVersion:
|
|
1112
|
+
currentVersion: _chunkCSUGNNJYcjs.package_default.version,
|
|
1023
1113
|
check: _nullishCoalesce(opts.check, () => ( false))
|
|
1024
1114
|
});
|
|
1025
1115
|
});
|
|
1026
1116
|
program.command("upgrade").description("Check for updates and install if available").option("--check", "Only check for updates without installing").action(async (opts) => {
|
|
1027
1117
|
const { runUpdate } = await Promise.resolve().then(() => _interopRequireWildcard(require("./update-NV6QRYY7.cjs")));
|
|
1028
1118
|
await runUpdate({
|
|
1029
|
-
currentVersion:
|
|
1119
|
+
currentVersion: _chunkCSUGNNJYcjs.package_default.version,
|
|
1030
1120
|
check: _nullishCoalesce(opts.check, () => ( false))
|
|
1031
1121
|
});
|
|
1032
1122
|
});
|
|
1033
|
-
program.command("import [source]").description("Import data from other coding agents (claude, codex, gemini, cursor, cline, continue, augment)").option("--all", "Import all available categories without prompting").option("--categories <list>", "Comma-separated list of categories to import (sessions,settings,skills,memory,mcp,hooks)", (val) => val.split(",")).option("--dry-run", "Preview what would be imported without making changes").option("--retry-failed", "Retry previously failed import items").action(async (source, opts) => {
|
|
1034
|
-
const { runImport } = await Promise.resolve().then(() => _interopRequireWildcard(require("./import-
|
|
1123
|
+
program.command("import [source]").description("Import data from other coding agents (claude, codex, gemini, cursor, cline, continue, augment, opencode, kimi)").option("--all", "Import all available categories without prompting").option("--categories <list>", "Comma-separated list of categories to import (sessions,settings,skills,memory,mcp,hooks)", (val) => val.split(",")).option("--dry-run", "Preview what would be imported without making changes").option("--retry-failed", "Retry previously failed import items").action(async (source, opts) => {
|
|
1124
|
+
const { runImport } = await Promise.resolve().then(() => _interopRequireWildcard(require("./import-2IG76KAN.cjs")));
|
|
1035
1125
|
await runImport({
|
|
1036
1126
|
source,
|
|
1037
1127
|
categories: opts.categories,
|
|
@@ -1043,15 +1133,18 @@ program.command("import [source]").description("Import data from other coding ag
|
|
|
1043
1133
|
});
|
|
1044
1134
|
async function runCLI(options) {
|
|
1045
1135
|
try {
|
|
1046
|
-
let config = await
|
|
1047
|
-
|
|
1136
|
+
let config = await _asyncNullishCoalesce(options._authConfig, async () => ( await _chunkCNQKIWIScjs.loadConfig.call(void 0, options.config, process.cwd())));
|
|
1137
|
+
if (options.bare) {
|
|
1138
|
+
config = await _chunkEFXFURDYcjs.prepareBareModeConfig.call(void 0, config, options);
|
|
1139
|
+
}
|
|
1140
|
+
const originalWorkspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, options.path);
|
|
1048
1141
|
let workspaceRoot = originalWorkspaceRoot;
|
|
1049
1142
|
let sessionWorktree = null;
|
|
1050
|
-
const { locale: detectedLocale } =
|
|
1143
|
+
const { locale: detectedLocale } = _chunkRJCZLFHEcjs.detectLocale.call(void 0, {
|
|
1051
1144
|
cliOverride: options.displayLanguage,
|
|
1052
|
-
configLocale: _optionalChain([config, 'access',
|
|
1145
|
+
configLocale: _optionalChain([config, 'access', _45 => _45.ui, 'optionalAccess', _46 => _46.locale])
|
|
1053
1146
|
});
|
|
1054
|
-
await
|
|
1147
|
+
await _chunkRJCZLFHEcjs.initI18n.call(void 0, detectedLocale);
|
|
1055
1148
|
const {
|
|
1056
1149
|
buildPermissionSettingsFromYolo,
|
|
1057
1150
|
normalizeYoloInput,
|
|
@@ -1072,9 +1165,9 @@ async function runCLI(options) {
|
|
|
1072
1165
|
}
|
|
1073
1166
|
}
|
|
1074
1167
|
const providerName = _nullishCoalesce(config.provider, () => ( "openrouter"));
|
|
1075
|
-
const providerConfig =
|
|
1168
|
+
const providerConfig = _chunkCNQKIWIScjs.getProviderConfig.call(void 0, config, providerName);
|
|
1076
1169
|
if (!providerConfig) {
|
|
1077
|
-
const { SetupWizard } = await Promise.resolve().then(() => _interopRequireWildcard(require("./onboarding-
|
|
1170
|
+
const { SetupWizard } = await Promise.resolve().then(() => _interopRequireWildcard(require("./onboarding-5DZFCO5Q.cjs")));
|
|
1078
1171
|
const wizard = new SetupWizard(originalWorkspaceRoot, config);
|
|
1079
1172
|
const result = await wizard.run({ skipWelcome: !config.isNewConfig });
|
|
1080
1173
|
if (result.cancelled) {
|
|
@@ -1083,7 +1176,7 @@ async function runCLI(options) {
|
|
|
1083
1176
|
}
|
|
1084
1177
|
if (result.success) {
|
|
1085
1178
|
config = { ...config, ...result.config };
|
|
1086
|
-
await
|
|
1179
|
+
await _chunkCNQKIWIScjs.saveConfig.call(void 0, config);
|
|
1087
1180
|
console.log();
|
|
1088
1181
|
}
|
|
1089
1182
|
}
|
|
@@ -1097,8 +1190,8 @@ async function runCLI(options) {
|
|
|
1097
1190
|
_chunkWGNMOVMTcjs.printDangerousWorkspaceWarning.call(void 0, originalWorkspaceRoot, safetyCheck);
|
|
1098
1191
|
process.exit(1);
|
|
1099
1192
|
}
|
|
1100
|
-
if (
|
|
1101
|
-
sessionWorktree =
|
|
1193
|
+
if (_chunkEFXFURDYcjs.isSessionWorktreeEnabled.call(void 0, options.worktree)) {
|
|
1194
|
+
sessionWorktree = _chunkEFXFURDYcjs.prepareSessionWorktree.call(void 0, {
|
|
1102
1195
|
cwd: originalWorkspaceRoot,
|
|
1103
1196
|
worktree: options.worktree,
|
|
1104
1197
|
mode: "cli"
|
|
@@ -1146,81 +1239,87 @@ async function runCLI(options) {
|
|
|
1146
1239
|
}
|
|
1147
1240
|
const { shouldUseInkRenderer } = await Promise.resolve().then(() => _interopRequireWildcard(require("./inkMode-VUE6ZDLD.cjs")));
|
|
1148
1241
|
const inkEnabled = shouldUseInkRenderer();
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1242
|
+
if (!options.bare) {
|
|
1243
|
+
initPingService({
|
|
1244
|
+
cliVersion: _chunkCSUGNNJYcjs.package_default.version,
|
|
1245
|
+
clientType: "cli"
|
|
1246
|
+
});
|
|
1247
|
+
startPingService();
|
|
1248
|
+
const stopPing = () => stopPingService();
|
|
1249
|
+
process.on("exit", stopPing);
|
|
1250
|
+
process.on("SIGINT", stopPing);
|
|
1251
|
+
process.on("SIGTERM", stopPing);
|
|
1252
|
+
}
|
|
1158
1253
|
printWelcome(runtime, void 0, null);
|
|
1159
1254
|
if (inkEnabled && process.stdout.isTTY) {
|
|
1160
1255
|
process.stdout.write("\x1B[s");
|
|
1161
1256
|
process.stdout.write("\x1B[u");
|
|
1162
1257
|
}
|
|
1163
1258
|
const agentHolder = { current: null };
|
|
1164
|
-
|
|
1165
|
-
const checkResults = await _chunkQLZOMZO5cjs.runStartupChecks.call(void 0, workspaceRoot);
|
|
1166
|
-
_chunkQLZOMZO5cjs.printStartupCheckResults.call(void 0, checkResults);
|
|
1167
|
-
if (!checkResults.allRequiredMet) {
|
|
1168
|
-
console.log(_chalk2.default.yellow("Continuing anyway, but some features may not work correctly.\n"));
|
|
1169
|
-
}
|
|
1170
|
-
} catch (e9) {
|
|
1171
|
-
}
|
|
1172
|
-
(async () => {
|
|
1259
|
+
if (!options.bare) {
|
|
1173
1260
|
try {
|
|
1174
|
-
const
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
validateAuthOnStartup(config),
|
|
1179
|
-
versionCheckPromise
|
|
1180
|
-
]);
|
|
1181
|
-
if (versionResult && agentHolder.current) {
|
|
1182
|
-
agentHolder.current.setVersionCheckResult(versionResult);
|
|
1261
|
+
const checkResults = await _chunkQLZOMZO5cjs.runStartupChecks.call(void 0, workspaceRoot);
|
|
1262
|
+
_chunkQLZOMZO5cjs.printStartupCheckResults.call(void 0, checkResults);
|
|
1263
|
+
if (!checkResults.allRequiredMet) {
|
|
1264
|
+
console.log(_chalk2.default.yellow("Continuing anyway, but some features may not work correctly.\n"));
|
|
1183
1265
|
}
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1266
|
+
} catch (e10) {
|
|
1267
|
+
}
|
|
1268
|
+
}
|
|
1269
|
+
if (!options.bare) {
|
|
1270
|
+
(async () => {
|
|
1271
|
+
try {
|
|
1272
|
+
const versionCheckPromise = _optionalChain([config, 'access', _47 => _47.ui, 'optionalAccess', _48 => _48.checkForUpdates]) !== false ? _chunkFMB3TSWPcjs.checkForUpdates.call(void 0, _chunkCSUGNNJYcjs.package_default.version, {
|
|
1273
|
+
checkIntervalHours: _nullishCoalesce(_optionalChain([config, 'access', _49 => _49.ui, 'optionalAccess', _50 => _50.updateCheckInterval]), () => ( 24))
|
|
1274
|
+
}) : Promise.resolve(null);
|
|
1275
|
+
const [authUser, versionResult] = await Promise.all([
|
|
1276
|
+
validateAuthOnStartup(config),
|
|
1277
|
+
versionCheckPromise
|
|
1278
|
+
]);
|
|
1279
|
+
if (versionResult && agentHolder.current) {
|
|
1280
|
+
agentHolder.current.setVersionCheckResult(versionResult);
|
|
1281
|
+
}
|
|
1282
|
+
if (authUser && _optionalChain([config, 'access', _51 => _51.auth, 'optionalAccess', _52 => _52.token])) {
|
|
1283
|
+
const syncEnabled = options.syncSettings !== false && _optionalChain([config, 'access', _53 => _53.sync, 'optionalAccess', _54 => _54.enabled]) !== false;
|
|
1284
|
+
if (syncEnabled) {
|
|
1285
|
+
try {
|
|
1286
|
+
const { createSyncService, DEFAULT_SYNC_CONFIG } = await Promise.resolve().then(() => _interopRequireWildcard(require("./sync-254WF6JI.cjs")));
|
|
1287
|
+
const { setSyncService } = await Promise.resolve().then(() => _interopRequireWildcard(require("./sync-2DIZN4EH.cjs")));
|
|
1288
|
+
const syncService = createSyncService({
|
|
1289
|
+
authToken: config.auth.token,
|
|
1290
|
+
userId: authUser.id,
|
|
1291
|
+
config: {
|
|
1292
|
+
...DEFAULT_SYNC_CONFIG,
|
|
1293
|
+
...config.sync,
|
|
1294
|
+
enabled: true
|
|
1295
|
+
},
|
|
1296
|
+
onAuthFailure: async () => {
|
|
1297
|
+
const message = "Session sync failed. Run /logout and /login if you continue to see this message.";
|
|
1298
|
+
if (agentHolder.current) {
|
|
1299
|
+
agentHolder.current.notifyUser(message);
|
|
1300
|
+
} else {
|
|
1301
|
+
const { promptNotify } = await Promise.resolve().then(() => _interopRequireWildcard(require("./inputPrompt-WVGVWAHS.cjs")));
|
|
1302
|
+
promptNotify(_chalk2.default.yellow(message));
|
|
1303
|
+
}
|
|
1205
1304
|
}
|
|
1206
|
-
}
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1305
|
+
});
|
|
1306
|
+
syncService.start();
|
|
1307
|
+
setSyncService(syncService);
|
|
1308
|
+
const stopSync = () => {
|
|
1309
|
+
_optionalChain([syncService, 'optionalAccess', _55 => _55.stop, 'call', _56 => _56()]);
|
|
1310
|
+
setSyncService(null);
|
|
1311
|
+
};
|
|
1312
|
+
process.on("exit", stopSync);
|
|
1313
|
+
process.on("SIGINT", stopSync);
|
|
1314
|
+
process.on("SIGTERM", stopSync);
|
|
1315
|
+
} catch (e11) {
|
|
1316
|
+
}
|
|
1218
1317
|
}
|
|
1219
1318
|
}
|
|
1319
|
+
} catch (e12) {
|
|
1220
1320
|
}
|
|
1221
|
-
}
|
|
1222
|
-
|
|
1223
|
-
})();
|
|
1321
|
+
})();
|
|
1322
|
+
}
|
|
1224
1323
|
if (options.model) {
|
|
1225
1324
|
const providerName2 = _nullishCoalesce(config.provider, () => ( "openrouter"));
|
|
1226
1325
|
if (config[providerName2]) {
|
|
@@ -1231,13 +1330,13 @@ async function runCLI(options) {
|
|
|
1231
1330
|
config.agent = _nullishCoalesce(config.agent, () => ( {}));
|
|
1232
1331
|
config.agent.debug = true;
|
|
1233
1332
|
}
|
|
1234
|
-
const { ProviderFactory } = await Promise.resolve().then(() => _interopRequireWildcard(require("./ProviderFactory-
|
|
1333
|
+
const { ProviderFactory } = await Promise.resolve().then(() => _interopRequireWildcard(require("./ProviderFactory-3BFS65V7.cjs")));
|
|
1235
1334
|
const { FileActionManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./filesystem-PGUPCMVK.cjs")));
|
|
1236
1335
|
const llmProvider = ProviderFactory.create(config);
|
|
1237
1336
|
const files = new FileActionManager(workspaceRoot, runtime.additionalDirs);
|
|
1238
1337
|
if (options.autoSkill) {
|
|
1239
1338
|
console.log(_chalk2.default.cyan("\nAuto-generating skills for this project...\n"));
|
|
1240
|
-
const { runAutoSkillGeneration } = await Promise.resolve().then(() => _interopRequireWildcard(require("./autoSkill-
|
|
1339
|
+
const { runAutoSkillGeneration } = await Promise.resolve().then(() => _interopRequireWildcard(require("./autoSkill-YL6PN6AV.cjs")));
|
|
1241
1340
|
const result = await runAutoSkillGeneration(workspaceRoot, llmProvider);
|
|
1242
1341
|
if (!result.success) {
|
|
1243
1342
|
console.log(_chalk2.default.yellow(result.error || "Failed to generate skills"));
|
|
@@ -1279,7 +1378,7 @@ async function runCLI(options) {
|
|
|
1279
1378
|
configurable: true
|
|
1280
1379
|
});
|
|
1281
1380
|
pipeInitialInstruction = pipedInput;
|
|
1282
|
-
} catch (
|
|
1381
|
+
} catch (e13) {
|
|
1283
1382
|
options.prompt = pipedInput;
|
|
1284
1383
|
}
|
|
1285
1384
|
} else {
|
|
@@ -1287,12 +1386,12 @@ async function runCLI(options) {
|
|
|
1287
1386
|
}
|
|
1288
1387
|
}
|
|
1289
1388
|
}
|
|
1290
|
-
const { AutohandAgent } = await Promise.resolve().then(() => _interopRequireWildcard(require("./agent-
|
|
1389
|
+
const { AutohandAgent } = await Promise.resolve().then(() => _interopRequireWildcard(require("./agent-YYEHGDAK.cjs")));
|
|
1291
1390
|
const agent = new AutohandAgent(llmProvider, files, runtime);
|
|
1292
1391
|
agentHolder.current = agent;
|
|
1293
1392
|
if (options.chrome) {
|
|
1294
|
-
const { ensureNativeHostInstalled, createBrowserHandoff, buildChromeOpenUrl: buildChromeOpenUrl2, openChromeContinuation: openChromeContinuation2 } = await Promise.resolve().then(() => _interopRequireWildcard(require("./chrome-
|
|
1295
|
-
const extensionId = _optionalChain([config, 'access',
|
|
1393
|
+
const { ensureNativeHostInstalled, createBrowserHandoff, buildChromeOpenUrl: buildChromeOpenUrl2, openChromeContinuation: openChromeContinuation2 } = await Promise.resolve().then(() => _interopRequireWildcard(require("./chrome-IFVZRHAT.cjs")));
|
|
1394
|
+
const extensionId = _optionalChain([config, 'access', _57 => _57.chrome, 'optionalAccess', _58 => _58.extensionId]);
|
|
1296
1395
|
await ensureNativeHostInstalled({ extensionId }).catch(() => {
|
|
1297
1396
|
});
|
|
1298
1397
|
const sessionManager = agent.getSessionManager();
|
|
@@ -1300,7 +1399,7 @@ async function runCLI(options) {
|
|
|
1300
1399
|
let currentSession = sessionManager.getCurrentSession();
|
|
1301
1400
|
if (!currentSession) {
|
|
1302
1401
|
const providerName2 = _nullishCoalesce(config.provider, () => ( "openrouter"));
|
|
1303
|
-
const modelName = _nullishCoalesce(_nullishCoalesce(options.model, () => ( _optionalChain([config, 'access',
|
|
1402
|
+
const modelName = _nullishCoalesce(_nullishCoalesce(options.model, () => ( _optionalChain([config, 'access', _59 => _59[providerName2], 'optionalAccess', _60 => _60.model]))), () => ( "unknown"));
|
|
1304
1403
|
currentSession = await sessionManager.createSession(workspaceRoot, modelName);
|
|
1305
1404
|
}
|
|
1306
1405
|
const sessionId = currentSession.metadata.sessionId;
|
|
@@ -1308,18 +1407,31 @@ async function runCLI(options) {
|
|
|
1308
1407
|
sessionId,
|
|
1309
1408
|
workspaceRoot,
|
|
1310
1409
|
extensionId,
|
|
1311
|
-
installUrl: _optionalChain([config, 'access',
|
|
1410
|
+
installUrl: _optionalChain([config, 'access', _61 => _61.chrome, 'optionalAccess', _62 => _62.installUrl])
|
|
1312
1411
|
});
|
|
1313
1412
|
await openChromeContinuation2(
|
|
1314
|
-
buildChromeOpenUrl2({ extensionId, installUrl: _optionalChain([config, 'access',
|
|
1315
|
-
_nullishCoalesce(_optionalChain([config, 'access',
|
|
1316
|
-
{ userDataDir: _optionalChain([config, 'access',
|
|
1413
|
+
buildChromeOpenUrl2({ extensionId, installUrl: _optionalChain([config, 'access', _63 => _63.chrome, 'optionalAccess', _64 => _64.installUrl]) }),
|
|
1414
|
+
_nullishCoalesce(_optionalChain([config, 'access', _65 => _65.chrome, 'optionalAccess', _66 => _66.browser]), () => ( "auto")),
|
|
1415
|
+
{ userDataDir: _optionalChain([config, 'access', _67 => _67.chrome, 'optionalAccess', _68 => _68.userDataDir]), profileDirectory: _optionalChain([config, 'access', _69 => _69.chrome, 'optionalAccess', _70 => _70.profileDirectory]) }
|
|
1317
1416
|
);
|
|
1318
1417
|
console.log(_chalk2.default.green("\n\u2713 Opened Chrome. Side panel (Cmd+E) to continue."));
|
|
1319
1418
|
console.log(_chalk2.default.gray(` Session: ${sessionId}
|
|
1320
1419
|
`));
|
|
1321
1420
|
}
|
|
1322
|
-
if (options.
|
|
1421
|
+
if (options.fork) {
|
|
1422
|
+
const forkEnabled = _optionalChain([_chunk7TO3PDMVcjs.getFeatureState.call(void 0, config, "experimental_fork"), 'optionalAccess', _71 => _71.enabled]) === true;
|
|
1423
|
+
if (!forkEnabled) {
|
|
1424
|
+
console.error(_chalk2.default.red("The --fork flag is behind experimental_fork. Run /features enable experimental_fork, then try again."));
|
|
1425
|
+
process.exit(1);
|
|
1426
|
+
}
|
|
1427
|
+
const sessionManager = agent.getSessionManager();
|
|
1428
|
+
await sessionManager.initialize();
|
|
1429
|
+
const forked = await sessionManager.branchSession(options.fork, { type: "fork" });
|
|
1430
|
+
console.log(_chalk2.default.green(`
|
|
1431
|
+
Forked session ${forked.metadata.sessionId}.`));
|
|
1432
|
+
await agent.resumeSession(forked.metadata.sessionId);
|
|
1433
|
+
process.exit(0);
|
|
1434
|
+
} else if (options.prompt) {
|
|
1323
1435
|
await agent.runCommandMode(options.prompt);
|
|
1324
1436
|
process.exit(0);
|
|
1325
1437
|
} else if (options.resumeSessionId) {
|
|
@@ -1344,7 +1456,7 @@ function printBanner() {
|
|
|
1344
1456
|
}
|
|
1345
1457
|
if (process.stdout.isTTY) {
|
|
1346
1458
|
process.stdout.write("\x1B[3J\x1B[2J\x1B[H");
|
|
1347
|
-
console.log(
|
|
1459
|
+
console.log(_chunkEFXFURDYcjs.formatStartupBanner.call(void 0, _chunkSD3NTC7Dcjs.renderAutohandLogo.call(void 0, { columns: _chunkSD3NTC7Dcjs.getTerminalColumns.call(void 0, process.stdout) })));
|
|
1348
1460
|
} else {
|
|
1349
1461
|
console.log("autohand");
|
|
1350
1462
|
}
|
|
@@ -1373,50 +1485,50 @@ function printWelcome(runtime, authUser, versionCheck) {
|
|
|
1373
1485
|
}
|
|
1374
1486
|
const model = (() => {
|
|
1375
1487
|
try {
|
|
1376
|
-
const settings =
|
|
1377
|
-
return _nullishCoalesce(_nullishCoalesce(runtime.options.model, () => ( _optionalChain([settings, 'optionalAccess',
|
|
1378
|
-
} catch (
|
|
1488
|
+
const settings = _chunkCNQKIWIScjs.getProviderConfig.call(void 0, runtime.config);
|
|
1489
|
+
return _nullishCoalesce(_nullishCoalesce(runtime.options.model, () => ( _optionalChain([settings, 'optionalAccess', _72 => _72.model]))), () => ( "unknown"));
|
|
1490
|
+
} catch (e14) {
|
|
1379
1491
|
return _nullishCoalesce(runtime.options.model, () => ( "unknown"));
|
|
1380
1492
|
}
|
|
1381
1493
|
})();
|
|
1382
1494
|
const dir = runtime.workspaceRoot;
|
|
1383
|
-
let versionLine =
|
|
1495
|
+
let versionLine = _chunkEFXFURDYcjs.formatWelcomeVersionPrefix.call(void 0, getVersionString());
|
|
1384
1496
|
if (versionCheck) {
|
|
1385
1497
|
if (versionCheck.isUpToDate) {
|
|
1386
|
-
versionLine +=
|
|
1498
|
+
versionLine += _chunkEFXFURDYcjs.formatUpdateReady.call(void 0, );
|
|
1387
1499
|
} else if (versionCheck.updateAvailable && versionCheck.latestVersion) {
|
|
1388
|
-
versionLine +=
|
|
1500
|
+
versionLine += _chunkEFXFURDYcjs.formatUpdateAvailable.call(void 0, versionCheck.latestVersion);
|
|
1389
1501
|
}
|
|
1390
1502
|
}
|
|
1391
1503
|
console.log(versionLine);
|
|
1392
|
-
if (_optionalChain([versionCheck, 'optionalAccess',
|
|
1393
|
-
console.log(
|
|
1504
|
+
if (_optionalChain([versionCheck, 'optionalAccess', _73 => _73.updateAvailable])) {
|
|
1505
|
+
console.log(_chunkEFXFURDYcjs.formatInstallHint.call(void 0, _chunkFMB3TSWPcjs.getInstallHint.call(void 0, versionCheck.channel)));
|
|
1394
1506
|
}
|
|
1395
|
-
const isLoggedIn = !!(authUser || _optionalChain([runtime, 'access',
|
|
1507
|
+
const isLoggedIn = !!(authUser || _optionalChain([runtime, 'access', _74 => _74.config, 'access', _75 => _75.auth, 'optionalAccess', _76 => _76.token]));
|
|
1396
1508
|
if (authUser) {
|
|
1397
|
-
console.log(
|
|
1509
|
+
console.log(_chunkEFXFURDYcjs.formatWelcomeGreeting.call(void 0, authUser.name || authUser.email));
|
|
1398
1510
|
}
|
|
1399
1511
|
const ccEnabled = runtime.options.contextCompact !== false;
|
|
1400
|
-
console.log(
|
|
1512
|
+
console.log(_chunkEFXFURDYcjs.formatWelcomeStatusLine.call(void 0, model, ccEnabled, dir));
|
|
1401
1513
|
console.log();
|
|
1402
1514
|
const suggestions = buildWelcomeSuggestions(isLoggedIn, dir);
|
|
1403
|
-
console.log(
|
|
1515
|
+
console.log(_chunkEFXFURDYcjs.formatWelcomeTitle.call(void 0, ));
|
|
1404
1516
|
for (const s of suggestions) {
|
|
1405
|
-
console.log(
|
|
1517
|
+
console.log(_chunkEFXFURDYcjs.formatWelcomeSuggestion.call(void 0, s.command, s.description));
|
|
1406
1518
|
}
|
|
1407
1519
|
console.log();
|
|
1408
1520
|
}
|
|
1409
1521
|
async function runSkillInstall(opts) {
|
|
1410
|
-
const config = await
|
|
1411
|
-
const workspaceRoot =
|
|
1522
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config);
|
|
1523
|
+
const workspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, opts.path);
|
|
1412
1524
|
const safetyCheck = _chunkWGNMOVMTcjs.checkWorkspaceSafety.call(void 0, workspaceRoot);
|
|
1413
1525
|
if (!safetyCheck.safe) {
|
|
1414
1526
|
_chunkWGNMOVMTcjs.printDangerousWorkspaceWarning.call(void 0, workspaceRoot, safetyCheck);
|
|
1415
1527
|
process.exit(1);
|
|
1416
1528
|
}
|
|
1417
|
-
const { SkillsRegistry } = await Promise.resolve().then(() => _interopRequireWildcard(require("./SkillsRegistry-
|
|
1418
|
-
const { AUTOHAND_PATHS } = await Promise.resolve().then(() => _interopRequireWildcard(require("./constants-
|
|
1419
|
-
const { skillsInstall } = await Promise.resolve().then(() => _interopRequireWildcard(require("./skills-install-
|
|
1529
|
+
const { SkillsRegistry } = await Promise.resolve().then(() => _interopRequireWildcard(require("./SkillsRegistry-PM34DQNA.cjs")));
|
|
1530
|
+
const { AUTOHAND_PATHS } = await Promise.resolve().then(() => _interopRequireWildcard(require("./constants-B4W5BT7F.cjs")));
|
|
1531
|
+
const { skillsInstall } = await Promise.resolve().then(() => _interopRequireWildcard(require("./skills-install-D7K476SL.cjs")));
|
|
1420
1532
|
const skillsRegistry = new SkillsRegistry(AUTOHAND_PATHS.skills);
|
|
1421
1533
|
await skillsRegistry.initialize();
|
|
1422
1534
|
await skillsRegistry.setWorkspace(workspaceRoot);
|
|
@@ -1427,21 +1539,21 @@ async function runSkillInstall(opts) {
|
|
|
1427
1539
|
}, skillName);
|
|
1428
1540
|
}
|
|
1429
1541
|
async function runLearnNonInteractive(opts, subcommand) {
|
|
1430
|
-
const config = await
|
|
1431
|
-
const workspaceRoot =
|
|
1542
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config);
|
|
1543
|
+
const workspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, opts.path);
|
|
1432
1544
|
const safetyCheck = _chunkWGNMOVMTcjs.checkWorkspaceSafety.call(void 0, workspaceRoot);
|
|
1433
1545
|
if (!safetyCheck.safe) {
|
|
1434
1546
|
_chunkWGNMOVMTcjs.printDangerousWorkspaceWarning.call(void 0, workspaceRoot, safetyCheck);
|
|
1435
1547
|
process.exit(1);
|
|
1436
1548
|
}
|
|
1437
|
-
const { learn } = await Promise.resolve().then(() => _interopRequireWildcard(require("./learn-
|
|
1438
|
-
const { SkillsRegistry } = await Promise.resolve().then(() => _interopRequireWildcard(require("./SkillsRegistry-
|
|
1439
|
-
const { AUTOHAND_PATHS } = await Promise.resolve().then(() => _interopRequireWildcard(require("./constants-
|
|
1440
|
-
const { HookManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./HookManager-
|
|
1549
|
+
const { learn } = await Promise.resolve().then(() => _interopRequireWildcard(require("./learn-NLSHI2MZ.cjs")));
|
|
1550
|
+
const { SkillsRegistry } = await Promise.resolve().then(() => _interopRequireWildcard(require("./SkillsRegistry-PM34DQNA.cjs")));
|
|
1551
|
+
const { AUTOHAND_PATHS } = await Promise.resolve().then(() => _interopRequireWildcard(require("./constants-B4W5BT7F.cjs")));
|
|
1552
|
+
const { HookManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./HookManager-ZL2CLAJW.cjs")));
|
|
1441
1553
|
const skillsRegistry = new SkillsRegistry(AUTOHAND_PATHS.skills);
|
|
1442
1554
|
await skillsRegistry.initialize();
|
|
1443
1555
|
await skillsRegistry.setWorkspace(workspaceRoot);
|
|
1444
|
-
const { ProviderFactory } = await Promise.resolve().then(() => _interopRequireWildcard(require("./ProviderFactory-
|
|
1556
|
+
const { ProviderFactory } = await Promise.resolve().then(() => _interopRequireWildcard(require("./ProviderFactory-3BFS65V7.cjs")));
|
|
1445
1557
|
const llmProvider = ProviderFactory.create(config);
|
|
1446
1558
|
const hookManager = new HookManager({ workspaceRoot });
|
|
1447
1559
|
const args = subcommand === "update" ? ["update"] : [];
|
|
@@ -1457,13 +1569,13 @@ async function runLearnNonInteractive(opts, subcommand) {
|
|
|
1457
1569
|
}
|
|
1458
1570
|
}
|
|
1459
1571
|
async function runGoalFlag(opts) {
|
|
1460
|
-
const config = await _asyncNullishCoalesce(opts._authConfig, async () => ( await
|
|
1461
|
-
const { GOAL_FEATURE_DISABLED_MESSAGE, isGoalFeatureEnabled } = await Promise.resolve().then(() => _interopRequireWildcard(require("./feature-
|
|
1572
|
+
const config = await _asyncNullishCoalesce(opts._authConfig, async () => ( await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config, process.cwd())));
|
|
1573
|
+
const { GOAL_FEATURE_DISABLED_MESSAGE, isGoalFeatureEnabled } = await Promise.resolve().then(() => _interopRequireWildcard(require("./feature-KP74CZ3F.cjs")));
|
|
1462
1574
|
if (!isGoalFeatureEnabled(config)) {
|
|
1463
1575
|
console.error(_chalk2.default.yellow(GOAL_FEATURE_DISABLED_MESSAGE));
|
|
1464
1576
|
process.exit(1);
|
|
1465
1577
|
}
|
|
1466
|
-
const workspaceRoot =
|
|
1578
|
+
const workspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, opts.path);
|
|
1467
1579
|
const workspacePathValidation = await _chunkQLZOMZO5cjs.validateWorkspacePath.call(void 0, workspaceRoot);
|
|
1468
1580
|
if (!workspacePathValidation.valid) {
|
|
1469
1581
|
console.error(_chalk2.default.red(`Error: ${workspacePathValidation.error}`));
|
|
@@ -1474,7 +1586,7 @@ async function runGoalFlag(opts) {
|
|
|
1474
1586
|
_chunkWGNMOVMTcjs.printDangerousWorkspaceWarning.call(void 0, workspaceRoot, safetyCheck);
|
|
1475
1587
|
process.exit(1);
|
|
1476
1588
|
}
|
|
1477
|
-
const { runGoalCli } = await Promise.resolve().then(() => _interopRequireWildcard(require("./goal-
|
|
1589
|
+
const { runGoalCli } = await Promise.resolve().then(() => _interopRequireWildcard(require("./goal-DL2N2AWT.cjs")));
|
|
1478
1590
|
const result = await runGoalCli(workspaceRoot, _nullishCoalesce(opts.goal, () => ( "")), config);
|
|
1479
1591
|
console.log(result);
|
|
1480
1592
|
}
|
|
@@ -1500,14 +1612,14 @@ function renderPermissionScope(title, pathLabel, allowList, denyList) {
|
|
|
1500
1612
|
console.log();
|
|
1501
1613
|
}
|
|
1502
1614
|
async function displayPermissions(opts) {
|
|
1503
|
-
const config = await
|
|
1504
|
-
const workspaceRoot =
|
|
1615
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config);
|
|
1616
|
+
const workspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, opts.path);
|
|
1505
1617
|
const safetyCheck = _chunkWGNMOVMTcjs.checkWorkspaceSafety.call(void 0, workspaceRoot);
|
|
1506
1618
|
if (!safetyCheck.safe) {
|
|
1507
1619
|
_chunkWGNMOVMTcjs.printDangerousWorkspaceWarning.call(void 0, workspaceRoot, safetyCheck);
|
|
1508
1620
|
process.exit(1);
|
|
1509
1621
|
}
|
|
1510
|
-
const { PermissionManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./PermissionManager-
|
|
1622
|
+
const { PermissionManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./PermissionManager-ZNURIEYR.cjs")));
|
|
1511
1623
|
const manager = new PermissionManager({
|
|
1512
1624
|
settings: config.permissions,
|
|
1513
1625
|
workspaceRoot
|
|
@@ -1546,8 +1658,8 @@ async function runPatchMode(opts) {
|
|
|
1546
1658
|
}
|
|
1547
1659
|
const fs3 = await Promise.resolve().then(() => _interopRequireWildcard(require("fs-extra")));
|
|
1548
1660
|
const { generateUnifiedPatch, formatChangeSummary } = await Promise.resolve().then(() => _interopRequireWildcard(require("./patch-DJ2GPFST.cjs")));
|
|
1549
|
-
const config = await
|
|
1550
|
-
const originalWorkspaceRoot =
|
|
1661
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config);
|
|
1662
|
+
const originalWorkspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, opts.path);
|
|
1551
1663
|
let workspaceRoot = originalWorkspaceRoot;
|
|
1552
1664
|
const workspacePathValidation = await _chunkQLZOMZO5cjs.validateWorkspacePath.call(void 0, originalWorkspaceRoot);
|
|
1553
1665
|
if (!workspacePathValidation.valid) {
|
|
@@ -1559,8 +1671,8 @@ async function runPatchMode(opts) {
|
|
|
1559
1671
|
_chunkWGNMOVMTcjs.printDangerousWorkspaceWarning.call(void 0, originalWorkspaceRoot, safetyCheck);
|
|
1560
1672
|
process.exit(1);
|
|
1561
1673
|
}
|
|
1562
|
-
if (
|
|
1563
|
-
const sessionWorktree =
|
|
1674
|
+
if (_chunkEFXFURDYcjs.isSessionWorktreeEnabled.call(void 0, opts.worktree)) {
|
|
1675
|
+
const sessionWorktree = _chunkEFXFURDYcjs.prepareSessionWorktree.call(void 0, {
|
|
1564
1676
|
cwd: originalWorkspaceRoot,
|
|
1565
1677
|
worktree: opts.worktree,
|
|
1566
1678
|
mode: "patch"
|
|
@@ -1598,12 +1710,9 @@ async function runPatchMode(opts) {
|
|
|
1598
1710
|
}
|
|
1599
1711
|
}
|
|
1600
1712
|
if (opts.model) {
|
|
1601
|
-
|
|
1602
|
-
if (config[providerName]) {
|
|
1603
|
-
config[providerName].model = opts.model;
|
|
1604
|
-
}
|
|
1713
|
+
applyCliModelOverride(config, opts.model);
|
|
1605
1714
|
}
|
|
1606
|
-
const { ProviderFactory } = await Promise.resolve().then(() => _interopRequireWildcard(require("./ProviderFactory-
|
|
1715
|
+
const { ProviderFactory } = await Promise.resolve().then(() => _interopRequireWildcard(require("./ProviderFactory-3BFS65V7.cjs")));
|
|
1607
1716
|
const { FileActionManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./filesystem-PGUPCMVK.cjs")));
|
|
1608
1717
|
const llmProvider = ProviderFactory.create(config);
|
|
1609
1718
|
const files = new FileActionManager(workspaceRoot, additionalDirs);
|
|
@@ -1631,7 +1740,7 @@ async function runPatchMode(opts) {
|
|
|
1631
1740
|
parallelApiKey: _nullishCoalesce(searchConfig.parallelApiKey, () => ( process.env.PARALLEL_API_KEY))
|
|
1632
1741
|
});
|
|
1633
1742
|
try {
|
|
1634
|
-
const { AutohandAgent } = await Promise.resolve().then(() => _interopRequireWildcard(require("./agent-
|
|
1743
|
+
const { AutohandAgent } = await Promise.resolve().then(() => _interopRequireWildcard(require("./agent-YYEHGDAK.cjs")));
|
|
1635
1744
|
const agent = new AutohandAgent(llmProvider, files, runtime);
|
|
1636
1745
|
await agent.runCommandMode(opts.prompt);
|
|
1637
1746
|
const changes = files.getPendingChanges();
|
|
@@ -1664,8 +1773,8 @@ async function runAutoMode(opts) {
|
|
|
1664
1773
|
console.error(_chalk2.default.red("Error: --auto-mode requires a task prompt"));
|
|
1665
1774
|
process.exit(1);
|
|
1666
1775
|
}
|
|
1667
|
-
const config = await
|
|
1668
|
-
const originalWorkspaceRoot =
|
|
1776
|
+
const config = await _chunkCNQKIWIScjs.loadConfig.call(void 0, opts.config);
|
|
1777
|
+
const originalWorkspaceRoot = _chunkCNQKIWIScjs.resolveWorkspaceRoot.call(void 0, config, opts.path);
|
|
1669
1778
|
const workspacePathValidation = await _chunkQLZOMZO5cjs.validateWorkspacePath.call(void 0, originalWorkspaceRoot);
|
|
1670
1779
|
if (!workspacePathValidation.valid) {
|
|
1671
1780
|
console.error(_chalk2.default.red(`Error: ${workspacePathValidation.error}`));
|
|
@@ -1699,19 +1808,16 @@ async function runAutoMode(opts) {
|
|
|
1699
1808
|
}
|
|
1700
1809
|
}
|
|
1701
1810
|
if (opts.model) {
|
|
1702
|
-
|
|
1703
|
-
if (config[providerName2]) {
|
|
1704
|
-
config[providerName2].model = opts.model;
|
|
1705
|
-
}
|
|
1811
|
+
applyCliModelOverride(config, opts.model);
|
|
1706
1812
|
}
|
|
1707
1813
|
if (opts.debug) {
|
|
1708
1814
|
config.agent = _nullishCoalesce(config.agent, () => ( {}));
|
|
1709
1815
|
config.agent.debug = true;
|
|
1710
1816
|
}
|
|
1711
1817
|
const { AutomodeManager, getAutomodeOptions } = await Promise.resolve().then(() => _interopRequireWildcard(require("./AutomodeManager-MPSXT2RH.cjs")));
|
|
1712
|
-
const { HookManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./HookManager-
|
|
1713
|
-
const { SessionManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./SessionManager-
|
|
1714
|
-
const { MemoryManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./MemoryManager-
|
|
1818
|
+
const { HookManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./HookManager-ZL2CLAJW.cjs")));
|
|
1819
|
+
const { SessionManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./SessionManager-LGPQIA57.cjs")));
|
|
1820
|
+
const { MemoryManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./MemoryManager-UOEQZIDC.cjs")));
|
|
1715
1821
|
const readline = await Promise.resolve().then(() => _interopRequireWildcard(require("readline")));
|
|
1716
1822
|
const automodeOptions = getAutomodeOptions(opts, config);
|
|
1717
1823
|
if (!automodeOptions) {
|
|
@@ -1725,7 +1831,7 @@ async function runAutoMode(opts) {
|
|
|
1725
1831
|
console.log(_chalk2.default.gray("Completion Marker:"), _chalk2.default.cyan(_nullishCoalesce(automodeOptions.completionPromise, () => ( "DONE"))));
|
|
1726
1832
|
console.log(_chalk2.default.gray("Worktree Isolation:"), _chalk2.default.cyan(automodeOptions.useWorktree !== false ? "enabled" : "disabled"));
|
|
1727
1833
|
const providerName = _nullishCoalesce(config.provider, () => ( "openrouter"));
|
|
1728
|
-
const modelName = _nullishCoalesce(_nullishCoalesce(opts.model, () => ( _optionalChain([config, 'access',
|
|
1834
|
+
const modelName = _nullishCoalesce(_nullishCoalesce(opts.model, () => ( _optionalChain([config, 'access', _77 => _77[providerName], 'optionalAccess', _78 => _78.model]))), () => ( "unknown"));
|
|
1729
1835
|
const sessionManager = new SessionManager();
|
|
1730
1836
|
await sessionManager.initialize();
|
|
1731
1837
|
const session = await sessionManager.createSession(originalWorkspaceRoot, modelName);
|
|
@@ -1752,7 +1858,7 @@ async function runAutoMode(opts) {
|
|
|
1752
1858
|
}
|
|
1753
1859
|
}
|
|
1754
1860
|
console.log();
|
|
1755
|
-
const { ProviderFactory } = await Promise.resolve().then(() => _interopRequireWildcard(require("./ProviderFactory-
|
|
1861
|
+
const { ProviderFactory } = await Promise.resolve().then(() => _interopRequireWildcard(require("./ProviderFactory-3BFS65V7.cjs")));
|
|
1756
1862
|
const llmProvider = ProviderFactory.create(config);
|
|
1757
1863
|
const { FileActionManager } = await Promise.resolve().then(() => _interopRequireWildcard(require("./filesystem-PGUPCMVK.cjs")));
|
|
1758
1864
|
const files = new FileActionManager(effectiveWorkspace, additionalDirs);
|
|
@@ -1793,7 +1899,7 @@ async function runAutoMode(opts) {
|
|
|
1793
1899
|
braveApiKey: _nullishCoalesce(searchConfig.braveApiKey, () => ( process.env.BRAVE_SEARCH_API_KEY)),
|
|
1794
1900
|
parallelApiKey: _nullishCoalesce(searchConfig.parallelApiKey, () => ( process.env.PARALLEL_API_KEY))
|
|
1795
1901
|
});
|
|
1796
|
-
const { AutohandAgent } = await Promise.resolve().then(() => _interopRequireWildcard(require("./agent-
|
|
1902
|
+
const { AutohandAgent } = await Promise.resolve().then(() => _interopRequireWildcard(require("./agent-YYEHGDAK.cjs")));
|
|
1797
1903
|
const agent = new AutohandAgent(llmProvider, files, runtime);
|
|
1798
1904
|
const runIteration = async (iteration, prompt, _abortSignal) => {
|
|
1799
1905
|
const iterationPrompt = buildIterationPrompt(prompt, iteration);
|
|
@@ -1832,14 +1938,14 @@ async function runAutoMode(opts) {
|
|
|
1832
1938
|
console.log(_chalk2.default.gray(`
|
|
1833
1939
|
\u{1F4CA} Auto-mode ${statusText2} after ${finalState.currentIteration} iterations`));
|
|
1834
1940
|
}
|
|
1835
|
-
const statusText = _optionalChain([finalState, 'optionalAccess',
|
|
1836
|
-
const exitCode = _optionalChain([finalState, 'optionalAccess',
|
|
1941
|
+
const statusText = _optionalChain([finalState, 'optionalAccess', _79 => _79.status]) === "completed" ? "completed" : `ended (${_optionalChain([finalState, 'optionalAccess', _80 => _80.status])})`;
|
|
1942
|
+
const exitCode = _optionalChain([finalState, 'optionalAccess', _81 => _81.status]) === "completed" ? 0 : 1;
|
|
1837
1943
|
const shouldHandoffToInteractive = opts.interactiveOnComplete === true && process.stdin.isTTY;
|
|
1838
1944
|
if (opts.interactiveOnComplete && !process.stdin.isTTY) {
|
|
1839
1945
|
console.log(_chalk2.default.yellow("\n\u26A0 --interactive-on-complete requested, but no TTY is available. Exiting after auto-mode.\n"));
|
|
1840
1946
|
}
|
|
1841
1947
|
if (!shouldHandoffToInteractive) {
|
|
1842
|
-
await sessionManager.closeSession(`Auto-mode ${statusText} after ${_nullishCoalesce(_optionalChain([finalState, 'optionalAccess',
|
|
1948
|
+
await sessionManager.closeSession(`Auto-mode ${statusText} after ${_nullishCoalesce(_optionalChain([finalState, 'optionalAccess', _82 => _82.currentIteration]), () => ( 0))} iterations: ${_optionalChain([opts, 'access', _83 => _83.autoMode, 'optionalAccess', _84 => _84.slice, 'call', _85 => _85(0, 50)])}...`);
|
|
1843
1949
|
console.log(_chalk2.default.gray(`
|
|
1844
1950
|
\u{1F4C1} Session saved: ${session.metadata.sessionId}`));
|
|
1845
1951
|
process.exit(exitCode);
|
|
@@ -1882,7 +1988,11 @@ function isCliEntrypoint() {
|
|
|
1882
1988
|
return import.meta.url === _url.pathToFileURL.call(void 0, entryPath).href;
|
|
1883
1989
|
}
|
|
1884
1990
|
if (isCliEntrypoint()) {
|
|
1885
|
-
void program.parseAsync()
|
|
1991
|
+
void program.parseAsync().catch((error) => {
|
|
1992
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
1993
|
+
console.error(_chalk2.default.red(message));
|
|
1994
|
+
process.exit(1);
|
|
1995
|
+
});
|
|
1886
1996
|
}
|
|
1887
1997
|
function launchInTmuxIfRequested(opts) {
|
|
1888
1998
|
if (!opts.tmux) {
|
|
@@ -1906,7 +2016,7 @@ function launchInTmuxIfRequested(opts) {
|
|
|
1906
2016
|
encoding: "utf8"
|
|
1907
2017
|
});
|
|
1908
2018
|
if (create.status !== 0) {
|
|
1909
|
-
const details = _optionalChain([create, 'access',
|
|
2019
|
+
const details = _optionalChain([create, 'access', _86 => _86.stderr, 'optionalAccess', _87 => _87.trim, 'call', _88 => _88()]) || _optionalChain([create, 'access', _89 => _89.stdout, 'optionalAccess', _90 => _90.trim, 'call', _91 => _91()]) || "unknown error";
|
|
1910
2020
|
console.error(_chalk2.default.red(`Failed to start tmux session: ${details}`));
|
|
1911
2021
|
process.exit(1);
|
|
1912
2022
|
}
|
|
@@ -1929,6 +2039,11 @@ function launchInTmuxIfRequested(opts) {
|
|
|
1929
2039
|
|
|
1930
2040
|
|
|
1931
2041
|
exports.displayPermissions = displayPermissions;
|
|
2042
|
+
/**
|
|
2043
|
+
* @license
|
|
2044
|
+
* Copyright 2026 Autohand AI LLC
|
|
2045
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
2046
|
+
*/
|
|
1932
2047
|
/**
|
|
1933
2048
|
* PingService - Periodic device ping for usage tracking
|
|
1934
2049
|
* Runs independently of telemetry opt-in (anonymous usage counting)
|
|
@@ -1947,8 +2062,3 @@ exports.displayPermissions = displayPermissions;
|
|
|
1947
2062
|
* Copyright 2025 Autohand AI LLC
|
|
1948
2063
|
* SPDX-License-Identifier: Apache-2.0
|
|
1949
2064
|
*/
|
|
1950
|
-
/**
|
|
1951
|
-
* @license
|
|
1952
|
-
* Copyright 2026 Autohand AI LLC
|
|
1953
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
1954
|
-
*/
|