@maincode-ai/matilda-code 0.22.2-nightly.20261107.317646b99 → 0.22.2-nightly.20261108.6294d1bfb

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.
Files changed (83) hide show
  1. package/chunks/agent-57XAQHVM.js +3 -0
  2. package/chunks/agent-headless-HAPKRYIE.js +3 -0
  3. package/chunks/{askUserQuestion-DHYKAZWH.js → askUserQuestion-2VKCJUZN.js} +1 -1
  4. package/chunks/chunk-2NTXP5AZ.js +8 -0
  5. package/chunks/{chunk-ECXO253T.js → chunk-3BBYMSRF.js} +511 -509
  6. package/chunks/chunk-3I3FFJWY.js +80 -0
  7. package/chunks/{chunk-VWM3GUBH.js → chunk-4PVHNEU3.js} +1 -1
  8. package/chunks/chunk-5PYAMBM2.js +8 -0
  9. package/chunks/{chunk-3TTI3ZQT.js → chunk-BJUD4NXI.js} +16 -16
  10. package/chunks/chunk-GSJK7SGP.js +121 -0
  11. package/chunks/{chunk-42UM7T4B.js → chunk-IXILJSRE.js} +30 -30
  12. package/chunks/{chunk-N2BE647T.js → chunk-LXLLH53T.js} +1 -1
  13. package/chunks/{chunk-ZUQRP3N6.js → chunk-OWVBDJ7E.js} +1 -1
  14. package/chunks/chunk-T4674TNM.js +12 -0
  15. package/chunks/{chunk-BS7Q7KA6.js → chunk-W45FOPLA.js} +1 -1
  16. package/chunks/chunk-WUMI5YVV.js +13 -0
  17. package/chunks/{chunk-FY3LL4OC.js → chunk-XZJ4RV46.js} +1 -1
  18. package/chunks/{chunk-L2FKLLEC.js → chunk-YN2SAMUR.js} +1 -1
  19. package/chunks/{chunk-P24OL22U.js → chunk-ZT36XNDG.js} +10 -10
  20. package/chunks/{computer-use-DIGHVJ7N.js → computer-use-UOCOK6SQ.js} +7 -7
  21. package/chunks/{cron-create-5RRFCP36.js → cron-create-62PNWR2P.js} +1 -1
  22. package/chunks/{cron-delete-7DTRWCSV.js → cron-delete-IYE6E33N.js} +1 -1
  23. package/chunks/{cron-list-HY6XJD7D.js → cron-list-L2SVZRPY.js} +1 -1
  24. package/chunks/{edit-IVOZQDG7.js → edit-QLBVLVHY.js} +1 -1
  25. package/chunks/{en-V4AM2EKE.js → en-UXQJBGFG.js} +1 -1
  26. package/chunks/{enter-worktree-LQKNE24C.js → enter-worktree-YAQ6HDVT.js} +1 -1
  27. package/chunks/{enterPlanMode-AMKRMA4Q.js → enterPlanMode-EGI24N3P.js} +1 -1
  28. package/chunks/{exit-worktree-353X52E6.js → exit-worktree-3OPW3OAW.js} +1 -1
  29. package/chunks/{exitPlanMode-FA7FBOPZ.js → exitPlanMode-RTFHVTCT.js} +4 -4
  30. package/chunks/{glob-OLQLERJP.js → glob-JJXYCPDP.js} +1 -1
  31. package/chunks/{goal-tools-POD6LCKM.js → goal-tools-NJF2SBXC.js} +1 -1
  32. package/chunks/{grep-WCOSLJAC.js → grep-PQRV7OZR.js} +1 -1
  33. package/chunks/keychain-token-storage-M4SAHQOZ.js +3 -0
  34. package/chunks/{ls-JORGCXES.js → ls-OYI6LAAH.js} +1 -1
  35. package/chunks/{lsp-Y46R5DO5.js → lsp-U52XKS3X.js} +1 -1
  36. package/chunks/mcp-client-6MW2KO57.js +3 -0
  37. package/chunks/monitor-TPB66N7V.js +32 -0
  38. package/chunks/notebook-edit-O45G2OS2.js +17 -0
  39. package/chunks/{openaiContentGenerator-7UTX34FH.js → openaiContentGenerator-T2E7ARNR.js} +7 -7
  40. package/chunks/read-file-2XDCTNU6.js +3 -0
  41. package/chunks/ripGrep-WB4PIZYI.js +3 -0
  42. package/chunks/scheduler-YG2LUC5E.js +8 -0
  43. package/chunks/{send-message-VY4DP63A.js → send-message-EWM35CIV.js} +1 -1
  44. package/chunks/shell-UEHJRUPV.js +3 -0
  45. package/chunks/{skill-3RC6M3O5.js → skill-MGFDUWWX.js} +1 -1
  46. package/chunks/{symbol-search-YNGX4Z5T.js → symbol-search-PFI76DKS.js} +1 -1
  47. package/chunks/syntheticOutput-J7B556VM.js +3 -0
  48. package/chunks/{task-create-NRBVXURQ.js → task-create-DUMMTB5V.js} +1 -1
  49. package/chunks/{task-detach-VHDDAO2K.js → task-detach-QYMWZUO6.js} +1 -1
  50. package/chunks/{task-list-T2IET466.js → task-list-OXXHFYZR.js} +1 -1
  51. package/chunks/{task-stop-OEAEE5R7.js → task-stop-IN4YP24W.js} +1 -1
  52. package/chunks/{task-update-4ANRU74G.js → task-update-CXGD6VP2.js} +1 -1
  53. package/chunks/{team-create-RUBIKSDJ.js → team-create-YEPFGLCA.js} +1 -1
  54. package/chunks/{team-delete-M4ORNSTT.js → team-delete-C4XRGL2J.js} +1 -1
  55. package/chunks/{todoWrite-RN2OP46T.js → todoWrite-DGBA6PPS.js} +1 -1
  56. package/chunks/tool-call-HNUF467C.js +3 -0
  57. package/chunks/tool-search-DN3B6IMF.js +26 -0
  58. package/chunks/{web-fetch-VA2BZ4VR.js → web-fetch-YFXYV2CO.js} +1 -1
  59. package/chunks/{web-search-TZUX7I6D.js → web-search-HUQRJF44.js} +1 -1
  60. package/chunks/{workflow-7YOFJC77.js → workflow-HJ5O2E7S.js} +2 -2
  61. package/chunks/write-file-RDLXOLHP.js +15 -0
  62. package/cli.js +438 -436
  63. package/locales/en.js +9 -8
  64. package/npm-postinstall.js +1 -1
  65. package/package.json +2 -2
  66. package/chunks/agent-CUHHPELW.js +0 -3
  67. package/chunks/agent-headless-P2DULOWS.js +0 -3
  68. package/chunks/chunk-355M6IU5.js +0 -80
  69. package/chunks/chunk-46FFWNRO.js +0 -12
  70. package/chunks/chunk-55YW6EUC.js +0 -8
  71. package/chunks/chunk-FPGKJJJY.js +0 -13
  72. package/chunks/chunk-O2WOUWDJ.js +0 -121
  73. package/chunks/keychain-token-storage-BCODB632.js +0 -3
  74. package/chunks/mcp-client-UUQFLTQ2.js +0 -3
  75. package/chunks/monitor-S7LII2PV.js +0 -32
  76. package/chunks/notebook-edit-R35SRELR.js +0 -17
  77. package/chunks/read-file-UNA4JSSL.js +0 -3
  78. package/chunks/ripGrep-LSOMEB27.js +0 -3
  79. package/chunks/scheduler-BCZEO32E.js +0 -8
  80. package/chunks/shell-BXOPTHWD.js +0 -3
  81. package/chunks/syntheticOutput-4JANVS4D.js +0 -3
  82. package/chunks/tool-search-O2ZT6LK7.js +0 -28
  83. package/chunks/write-file-NK4IW2I5.js +0 -15
@@ -0,0 +1,3 @@
1
+ // Force strict mode and setup for ESM
2
+ "use strict";
3
+ import{Bc as a,Cc as b,Dc as c,Ec as d,Fc as e,Gc as f}from"./chunk-3BBYMSRF.js";import"./chunk-OWVBDJ7E.js";import"./chunk-XZJ4RV46.js";import"./chunk-OWEBLTAN.js";import"./chunk-BQDEPKIG.js";import"./chunk-TXMXCR7D.js";import"./chunk-YULUB745.js";import"./chunk-DZKI2CAC.js";import"./chunk-BJUD4NXI.js";import"./chunk-YN2SAMUR.js";import"./chunk-LXLLH53T.js";import"./chunk-QXSBPCBA.js";import"./chunk-HRD7WD3P.js";import"./chunk-V6UPUMP3.js";import"./chunk-5B2QERWR.js";import"./chunk-W45FOPLA.js";import"./chunk-MZ73LBEY.js";import"./chunk-2NTXP5AZ.js";import"./chunk-3I3FFJWY.js";import"./chunk-GT6MSEK4.js";import"./chunk-GSJK7SGP.js";import"./chunk-225CZWD7.js";import"./chunk-LBQNFSZ2.js";import"./chunk-WUMI5YVV.js";import"./chunk-IXILJSRE.js";import"./chunk-HJK3NKAR.js";import"./chunk-PFXCFIHY.js";import"./chunk-XPVKH5TC.js";import"./chunk-7ZODGQO6.js";import"./chunk-5PYAMBM2.js";import"./chunk-UM6CLO7D.js";import"./chunk-T4674TNM.js";import"./chunk-ZT36XNDG.js";import"./chunk-WL27X35X.js";import"./chunk-HEJO7OBH.js";import"./chunk-GZPNIYVZ.js";import"./chunk-OWGSC52X.js";export{f as AgentTool,b as TOOL_REGISTRY_REBUILT,e as createApprovalModeOverride,c as hasRebuiltToolRegistry,d as rebuildToolRegistryOnOverride,a as resolveSubagentApprovalMode};
@@ -0,0 +1,3 @@
1
+ // Force strict mode and setup for ESM
2
+ "use strict";
3
+ import{oc as a,pc as b,qc as c}from"./chunk-3BBYMSRF.js";import"./chunk-OWVBDJ7E.js";import"./chunk-XZJ4RV46.js";import"./chunk-OWEBLTAN.js";import"./chunk-BQDEPKIG.js";import"./chunk-TXMXCR7D.js";import"./chunk-YULUB745.js";import"./chunk-DZKI2CAC.js";import"./chunk-BJUD4NXI.js";import"./chunk-YN2SAMUR.js";import"./chunk-LXLLH53T.js";import"./chunk-QXSBPCBA.js";import"./chunk-HRD7WD3P.js";import"./chunk-V6UPUMP3.js";import"./chunk-5B2QERWR.js";import"./chunk-W45FOPLA.js";import"./chunk-MZ73LBEY.js";import"./chunk-2NTXP5AZ.js";import"./chunk-3I3FFJWY.js";import"./chunk-GT6MSEK4.js";import"./chunk-GSJK7SGP.js";import"./chunk-225CZWD7.js";import"./chunk-LBQNFSZ2.js";import"./chunk-WUMI5YVV.js";import"./chunk-IXILJSRE.js";import"./chunk-HJK3NKAR.js";import"./chunk-PFXCFIHY.js";import"./chunk-XPVKH5TC.js";import"./chunk-7ZODGQO6.js";import"./chunk-5PYAMBM2.js";import"./chunk-UM6CLO7D.js";import"./chunk-T4674TNM.js";import"./chunk-ZT36XNDG.js";import"./chunk-WL27X35X.js";import"./chunk-HEJO7OBH.js";import"./chunk-GZPNIYVZ.js";import"./chunk-OWGSC52X.js";export{c as AgentHeadless,a as ContextState,b as templateString};
@@ -1,6 +1,6 @@
1
1
  // Force strict mode and setup for ESM
2
2
  "use strict";
3
- import{a as r}from"./chunk-ILBTI4K5.js";import{f as m,g as h,m as f,n as g}from"./chunk-P24OL22U.js";import{ea as d}from"./chunk-WL27X35X.js";import"./chunk-HEJO7OBH.js";import{b as p}from"./chunk-GZPNIYVZ.js";import"./chunk-OWGSC52X.js";p();var a=d("ASK_USER_QUESTION"),b=`Use this tool when you need to ask the user questions during execution. This allows you to:
3
+ import{a as r}from"./chunk-ILBTI4K5.js";import{f as m,g as h,m as f,n as g}from"./chunk-ZT36XNDG.js";import{ea as d}from"./chunk-WL27X35X.js";import"./chunk-HEJO7OBH.js";import{b as p}from"./chunk-GZPNIYVZ.js";import"./chunk-OWGSC52X.js";p();var a=d("ASK_USER_QUESTION"),b=`Use this tool when you need to ask the user questions during execution. This allows you to:
4
4
  1. Gather user preferences or requirements
5
5
  2. Clarify ambiguous instructions
6
6
  3. Get decisions on implementation choices as you work
@@ -0,0 +1,8 @@
1
+ // Force strict mode and setup for ESM
2
+ "use strict";
3
+ import{b as k}from"./chunk-7ZODGQO6.js";import{ea as m}from"./chunk-WL27X35X.js";import{b as n}from"./chunk-GZPNIYVZ.js";import{f as g}from"./chunk-OWGSC52X.js";n();var f=g(k(),1);import*as u from"node:crypto";import{promises as p}from"node:fs";import*as v from"node:os";import*as c from"node:path";import{isDeepStrictEqual as b}from"node:util";n();var l=class{serviceName;constructor(e){this.serviceName=e}validateCredentials(e){if(!e.serverName)throw new Error("Server name is required");if(!e.token)throw new Error("Token is required");if(!e.token.accessToken)throw new Error("Access token is required");if(!e.token.tokenType)throw new Error("Token type is required")}sanitizeServerName(e){return e.replace(/[^a-zA-Z0-9-_.]/g,"_")}};var o=m("MCP_KEYCHAIN"),A={retries:{retries:300,minTimeout:5,maxTimeout:200,factor:2,randomize:!0},stale:5e3,realpath:!1,onCompromised:h=>{o.warn(`The keychain lock was lost: ${h.message}`)}},d="__keychain_test__",s="__secret__",w=class extends l{keychainAvailable=null;keytarModule=null;keytarLoadAttempted=!1;async getKeytar(){if(this.keytarLoadAttempted)return this.keytarModule;this.keytarLoadAttempted=!0;try{let t=await import("keytar");this.keytarModule=t.default||t}catch(e){o.error(`Failed to load keytar module: ${e}`)}return this.keytarModule}async getCredentials(e){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let t=await this.getKeytar();if(!t)throw new Error("Keytar module not available");try{let r=this.sanitizeServerName(e),a=await t.getPassword(this.serviceName,r);if(!a)return null;let i=JSON.parse(a);return i.serverName===e?i:null}catch(r){throw r instanceof SyntaxError?new Error(`Failed to parse stored credentials for ${e}`):r}}async whileLocked(e){let t=c.join(v.userInfo().homedir,".matilda","mcp-oauth-keychain");await p.mkdir(c.dirname(t),{recursive:!0,mode:448});let r=await f.default.lock(t,A);try{return await e()}finally{await r()}}async setCredentials(e){await this.whileLocked(()=>this.writeCredentials(e))}async writeCredentials(e){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let t=await this.getKeytar();if(!t)throw new Error("Keytar module not available");this.validateCredentials(e);let r=this.sanitizeServerName(e.serverName),a={...e,updatedAt:Date.now()},i=JSON.stringify(a);await t.setPassword(this.serviceName,r,i)}async replaceCredentials(e,t){return this.whileLocked(async()=>{let r=await this.getCredentials(e.serverName);return b(r,e)?(await this.writeCredentials(t),!0):!1})}async deleteCredentials(e){return this.whileLocked(()=>this.removeCredentials(e))}async removeCredentials(e){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let t=await this.getKeytar();if(!t)throw new Error("Keytar module not available");let r=this.sanitizeServerName(e);return t.deletePassword(this.serviceName,r)}async listServers(){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let e=await this.getKeytar();if(!e)throw new Error("Keytar module not available");try{return(await e.findCredentials(this.serviceName)).filter(r=>!r.account.startsWith(d)).filter(r=>!r.account.startsWith(s)).map(r=>r.account)}catch(t){return o.error(`Failed to list servers from keychain: ${t}`),[]}}async getAllCredentials(){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let e=await this.getKeytar();if(!e)throw new Error("Keytar module not available");let t=new Map;try{let r=(await e.findCredentials(this.serviceName)).filter(a=>!a.account.startsWith(d)).filter(a=>!a.account.startsWith(s));for(let a of r)try{let i=JSON.parse(a.password);this.validateCredentials(i),t.set(a.account,i)}catch(i){o.error(`Failed to parse credentials for ${a.account}: ${i}`)}}catch(r){o.error(`Failed to get all credentials from keychain: ${r}`)}return t}async clearAll(){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let e=this.keytarModule?await this.keytarModule.findCredentials(this.serviceName).then(r=>r.map(a=>a.account)).catch(r=>{throw new Error(`Failed to list servers for clearing: ${r.message}`)}):[],t=[];for(let r of e)try{await this.deleteCredentials(r)}catch(a){t.push(a)}if(t.length>0)throw new Error(`Failed to clear some credentials: ${t.map(r=>r.message).join(", ")}`)}async checkKeychainAvailability(){if(this.keychainAvailable!==null)return this.keychainAvailable;try{let e=await this.getKeytar();if(!e)return this.keychainAvailable=!1,!1;let t=`${d}${u.randomBytes(8).toString("hex")}`,r="test";await e.setPassword(this.serviceName,t,r);let a=await e.getPassword(this.serviceName,t),y=await e.deletePassword(this.serviceName,t)&&a===r;return this.keychainAvailable=y,y}catch{return this.keychainAvailable=!1,!1}}async isAvailable(){return this.checkKeychainAvailability()}async setSecret(e,t){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let r=await this.getKeytar();if(!r)throw new Error("Keytar module not available");await r.setPassword(this.serviceName,`${s}${e}`,t)}async getSecret(e){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let t=await this.getKeytar();if(!t)throw new Error("Keytar module not available");return t.getPassword(this.serviceName,`${s}${e}`)}async deleteSecret(e){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let t=await this.getKeytar();if(!t)throw new Error("Keytar module not available");if(!await t.deletePassword(this.serviceName,`${s}${e}`))throw new Error(`No secret found for key: ${e}`)}async listSecrets(){if(!await this.checkKeychainAvailability())throw new Error("Keychain is not available");let e=await this.getKeytar();if(!e)throw new Error("Keytar module not available");try{return(await e.findCredentials(this.serviceName)).filter(r=>r.account.startsWith(s)).map(r=>r.account.substring(s.length))}catch(t){return o.error(`Failed to list secrets from keychain: ${t}`),[]}}};export{l as a,w as b};
4
+ /**
5
+ * @license
6
+ * Copyright 2025 Google LLC
7
+ * SPDX-License-Identifier: Apache-2.0
8
+ */