@minimax-ai/code 0.4.10 → 0.4.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +20 -0
- package/CHANGELOG.zh-CN.md +17 -0
- package/README.zh-CN.md +4 -0
- package/chunks/{launcher-BO2AIPOJ.js → launcher-TAS3WAUC.js} +125 -125
- package/chunks/{main-RV5CLB2O.js → main-6DJBGFQV.js} +1 -1
- package/cli.js +1 -1
- package/package.json +1 -1
|
@@ -27,4 +27,4 @@ Expecting one of '${n.join("', '")}'`);let i=`${e}Help`;return this.on(i,r=>{let
|
|
|
27
27
|
`),i="natural"},runPlugin:async(s,l)=>{let a=o.runPlugin??wt;e.stdout.write(`${await a(s,w,l)}
|
|
28
28
|
`),i="natural"}}).parseAsync(e.argv,{from:"node"}),i){let s=typeof e.exitCode=="number"?e.exitCode:0;await Promise.all([Re(e.stdout,o.outputDrainTimeoutMs??Me),Re(e.stderr,o.outputDrainTimeoutMs??Me)]),(o.platform??process.platform)==="win32"&&i==="natural"?e.exitCode=s:e.exit(s)}}catch(r){e.stderr.write(`${await ct(r)}
|
|
29
29
|
`),e.exitCode=1}}async function ct(o){let e=ie(o);if(!/better[-_]sqlite3/iu.test(e)||!/Could not locate the bindings file|Cannot find (?:module|package)|NODE_MODULE_VERSION|Module did not self-register/iu.test(e))return e;let{buildMcodePackageManagerCommand:t}=await import("./install-source-GWYHWTTG.js");return["MCode could not load its native SQLite dependency.","If npm reported blocked install scripts, the installation needs explicit script approval.","Reinstall with the original installer. For npm installations, run:",` ${t("npm-global",w).display} --foreground-scripts`,"",`Original error: ${e}`].join(`
|
|
30
|
-
`)}function Re(o,e){return o.destroyed||o.writableEnded?Promise.resolve():new Promise(t=>{let n=!1,i,r=()=>s(!0),s=(l=!1)=>{n||(n=!0,i&&clearTimeout(i),l||o.off?.("error",r),t())};i=setTimeout(s,e),i.unref?.(),o.once?.("error",r);try{o.write("",l=>s(!!l))}catch{s()}})}async function dt(o){let{launchTui:e}=await import("./launcher-
|
|
30
|
+
`)}function Re(o,e){return o.destroyed||o.writableEnded?Promise.resolve():new Promise(t=>{let n=!1,i,r=()=>s(!0),s=(l=!1)=>{n||(n=!0,i&&clearTimeout(i),l||o.off?.("error",r),t())};i=setTimeout(s,e),i.unref?.(),o.once?.("error",r);try{o.write("",l=>s(!!l))}catch{s()}})}async function dt(o){let{launchTui:e}=await import("./launcher-TAS3WAUC.js");await e(o)}async function ht(o,e,t){let{runTuiExecCommand:n}=await import("./run-exec-command-BQ2G5OY7.js");await n(o,e,t)}async function pt(o,e){let{runTuiAcpCommand:t}=await import("./run-acp-command-2SHKZJNF.js");await t(o,{},e)}async function mt(o,e=!0,t){let{runTuiLogin:n}=await import("./auth-command-T5DRRUNT.js");return n({region:o,openBrowser:e,lane:t})}async function ft(o){let{runTuiLogout:e}=await import("./auth-command-T5DRRUNT.js");return e({region:o})}async function gt(o){let{runMcodeUpdate:e}=await import("./update-CG3K6TMW.js");await e(o)}async function _t(o,e,t){let{runMcodeProviderCommand:n}=await import("./provider-command-TITVCVLJ.js");return n({request:o,version:e,lane:t})}async function wt(o,e,t){let{runMcodePluginCommand:n}=await import("./plugin-command-XCLCU4X3.js");return n({request:o,version:e,lane:t})}export{Re as drainTuiOutput,Xt as runTuiCli};
|
package/cli.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { createRequire as __mavis_cR } from "module"; import { basename as __mavis_basename, dirname as __mavis_dirname, join as __mavis_join } from "path"; import { fileURLToPath as __mavis_fileURLToPath, pathToFileURL as __mavis_pathToFileURL } from "url"; const __mavis_tuiCurrentModuleDir = __mavis_dirname(__mavis_fileURLToPath(import.meta.url)); const __mavis_tuiPackageRoot = __mavis_basename(__mavis_tuiCurrentModuleDir) === "chunks" ? __mavis_dirname(__mavis_tuiCurrentModuleDir) : __mavis_tuiCurrentModuleDir; const __mavis_tuiPackageEntryUrl = __mavis_pathToFileURL(__mavis_join(__mavis_tuiPackageRoot, "cli.js")).href; const require = __mavis_cR(__mavis_tuiPackageEntryUrl); const __dirname = __mavis_tuiPackageRoot;
|
|
3
3
|
import{f as s}from"./chunks/chunk-ZCP4JGO4.js";import{u as n,v as a}from"./chunks/chunk-VCJI7AJO.js";import"./chunks/chunk-O6RIRKRN.js";import"./chunks/chunk-HQ2U4QVQ.js";import{n as o,p as i}from"./chunks/chunk-WAVNKSSE.js";import"./chunks/chunk-DV5WIEGS.js";import"./chunks/chunk-ZITT4GJK.js";import"./chunks/chunk-2ZG44JU6.js";import"./chunks/chunk-Z44TXDGK.js";import"./chunks/chunk-CWWDVX6C.js";import"./chunks/chunk-D76SO2ME.js";import{fileURLToPath as u}from"node:url";async function l(){let c=n(u(__mavis_tuiPackageEntryUrl)),t=a(c),r;try{r=i(process.argv.slice(2),t)}catch(e){process.stderr.write(`${e instanceof Error?e.message:String(e)}
|
|
4
|
-
`),process.exitCode=1;return}let{getTuiDataDirPath:m}=await import("./chunks/data-dir-YVQZ5MXP.js");o({dataDir:m(),...r?{startupBuildEnvironment:r}:{}});let p=await s();try{let{runTuiCli:e}=await import("./chunks/main-
|
|
4
|
+
`),process.exitCode=1;return}let{getTuiDataDirPath:m}=await import("./chunks/data-dir-YVQZ5MXP.js");o({dataDir:m(),...r?{startupBuildEnvironment:r}:{}});let p=await s();try{let{runTuiCli:e}=await import("./chunks/main-6DJBGFQV.js");await e({allowStartupEnvironmentSelection:t})}finally{p.remove()}}await l();
|