blade-code 0.10.139 → 0.10.140
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/dist/blade.js +2 -2
- package/dist/{chunk-6qhbdcse.js → chunk-08z32sky.js} +2 -2
- package/dist/{chunk-mec8yedz.js → chunk-0c2y17xy.js} +1 -1
- package/dist/{chunk-x3c718v5.js → chunk-0kghtvxj.js} +2 -2
- package/dist/{chunk-3eskgvpy.js → chunk-0sx7ak0b.js} +1 -1
- package/dist/{chunk-sj4gz23a.js → chunk-15fpc0qg.js} +1 -1
- package/dist/{chunk-mtfjwsn2.js → chunk-19zsecpx.js} +2 -2
- package/dist/{chunk-7pg5y3pg.js → chunk-1myft5nb.js} +1 -1
- package/dist/chunk-1nreg14s.js +1 -0
- package/dist/{chunk-z9qv0d6k.js → chunk-2d3zksr0.js} +1 -1
- package/dist/{chunk-sdhdn0yx.js → chunk-2ff55pvt.js} +3 -3
- package/dist/{chunk-65c3vjwm.js → chunk-2g8avyq6.js} +1 -1
- package/dist/chunk-3kvt23m3.js +1 -0
- package/dist/chunk-4rh40xhc.js +1 -0
- package/dist/chunk-4xr4hz19.js +2 -0
- package/dist/{chunk-zz5n2qxk.js → chunk-50m1czz9.js} +1 -1
- package/dist/{chunk-earhezc8.js → chunk-5cw3bevx.js} +1 -1
- package/dist/{chunk-9m7d3ajv.js → chunk-5jq1mrqd.js} +1 -1
- package/dist/chunk-61yd46c0.js +1 -0
- package/dist/{chunk-8py443a5.js → chunk-6zxm9pen.js} +1 -1
- package/dist/{chunk-25r1v5rn.js → chunk-7eepxhcp.js} +34 -34
- package/dist/{chunk-jy7k2dwm.js → chunk-85b3kacc.js} +2 -2
- package/dist/chunk-8774agqd.js +1 -0
- package/dist/chunk-8brb7c6j.js +6 -0
- package/dist/{chunk-hrcz179j.js → chunk-8fx20am1.js} +2 -2
- package/dist/{chunk-16648v5c.js → chunk-8vqhcx3s.js} +1 -1
- package/dist/{chunk-6ezffjq1.js → chunk-9ced7jf0.js} +1 -1
- package/dist/chunk-abpmpyqa.js +1 -0
- package/dist/{chunk-yvmexv2c.js → chunk-ascjys4e.js} +1 -1
- package/dist/chunk-bb0z7c3g.js +1 -0
- package/dist/{chunk-5j68055h.js → chunk-c562kd2m.js} +1 -1
- package/dist/{chunk-bgzj85za.js → chunk-cf3dvysj.js} +1 -1
- package/dist/{chunk-bq6d0v5b.js → chunk-cww9pp1q.js} +2 -2
- package/dist/{chunk-7j4s1nrc.js → chunk-d1qe06f0.js} +1 -1
- package/dist/{chunk-40pd090k.js → chunk-e6j4vzta.js} +2 -2
- package/dist/{chunk-3ekz3zms.js → chunk-eh901zhx.js} +2 -2
- package/dist/{chunk-5w8pmsqe.js → chunk-eqe3smcg.js} +2 -2
- package/dist/{chunk-a5hkv8er.js → chunk-es0cbtx1.js} +2 -2
- package/dist/{chunk-gc4kj295.js → chunk-ffkzessq.js} +1 -1
- package/dist/{chunk-dv2m2xe5.js → chunk-g38d2ezm.js} +1 -1
- package/dist/{chunk-v2fewxvw.js → chunk-g4kydkyz.js} +2 -2
- package/dist/{chunk-qrv72yy6.js → chunk-g5scqxq3.js} +2 -2
- package/dist/{chunk-8rccn1y2.js → chunk-gq727fet.js} +1 -1
- package/dist/{chunk-5qwpdx3n.js → chunk-hj1yrssp.js} +1 -1
- package/dist/{chunk-d64b7wta.js → chunk-hvmrcd84.js} +1 -1
- package/dist/{chunk-zx78c1an.js → chunk-kmg8ad2j.js} +1 -1
- package/dist/{chunk-04t21rey.js → chunk-kxwc5wrx.js} +1 -1
- package/dist/chunk-m9dv5177.js +10 -0
- package/dist/{chunk-az08pq83.js → chunk-ma1mn6hn.js} +1 -1
- package/dist/{chunk-t88sfhjj.js → chunk-mnk0b4nz.js} +1 -1
- package/dist/chunk-mwgx87vw.js +1 -0
- package/dist/{chunk-cefmcwyv.js → chunk-n6tvswa8.js} +2 -2
- package/dist/{chunk-fbrdcveb.js → chunk-n8qg68y2.js} +1 -1
- package/dist/chunk-ntq4h4jh.js +1 -0
- package/dist/{chunk-1bqatrxs.js → chunk-nxsarfy6.js} +1 -1
- package/dist/{chunk-ft1bdqbs.js → chunk-pg7cgvs8.js} +2 -2
- package/dist/{chunk-1h3736q2.js → chunk-ppmy3n74.js} +219 -218
- package/dist/{chunk-grx6fv9w.js → chunk-pw9axk0e.js} +2 -2
- package/dist/{chunk-2jq9ed09.js → chunk-pwct7cj7.js} +1 -1
- package/dist/{chunk-esff371k.js → chunk-q9qts6bq.js} +2 -2
- package/dist/chunk-r324qme7.js +1 -0
- package/dist/{chunk-rhwkvx96.js → chunk-r4q06wbs.js} +1 -1
- package/dist/chunk-ra6ksfdy.js +1 -0
- package/dist/{chunk-dw0mewc2.js → chunk-rrtptbzv.js} +2 -2
- package/dist/{chunk-jb4hmk56.js → chunk-svsgtj41.js} +2 -2
- package/dist/{chunk-6j5v5emj.js → chunk-tagzy876.js} +6 -6
- package/dist/{chunk-516adpx6.js → chunk-tecbx0ek.js} +1 -1
- package/dist/chunk-tnts2de5.js +1 -0
- package/dist/chunk-w0710yj4.js +1 -0
- package/dist/{chunk-npc7jt96.js → chunk-w2m4yczv.js} +1 -1
- package/dist/{chunk-mh3ne2sf.js → chunk-w5057h27.js} +2 -2
- package/dist/chunk-we13xwds.js +180 -0
- package/dist/{chunk-f4cn6v8t.js → chunk-xagh2qb6.js} +2 -2
- package/dist/{chunk-05cv54r8.js → chunk-y5bqd8gh.js} +1 -1
- package/dist/{chunk-awheqy52.js → chunk-zfaenqqx.js} +2 -2
- package/dist/chunk-zp5097qk.js +2 -0
- package/dist/web/assets/ChatView-BlAGPVC-.js +63 -0
- package/dist/web/assets/{CodeBlockHighlighter-CYhxXWvb.js → CodeBlockHighlighter-BM1MZv6w.js} +1 -1
- package/dist/web/assets/{FilePreview-ByTaE1GR.js → FilePreview-P77KS9tr.js} +1 -1
- package/dist/web/assets/{KanbanBoard-KMmGvNPc.js → KanbanBoard-B0c7sE2y.js} +1 -1
- package/dist/web/assets/{MarkdownRenderer-C6lKOJaG.js → MarkdownRenderer-DHa0FqU0.js} +3 -3
- package/dist/web/assets/{ScrollArea-Bo6cZ3PH.js → ScrollArea-C6yf2fqq.js} +1 -1
- package/dist/web/assets/{SessionHistorySurface-Cymc4xw0.js → SessionHistorySurface-CXYBWqlN.js} +1 -1
- package/dist/web/assets/{SettingsModal-D36xhHwa.js → SettingsModal-BVjVlENY.js} +1 -1
- package/dist/web/assets/{Sidebar-DEGQINYb.js → Sidebar-DDW9Xs6e.js} +1 -1
- package/dist/web/assets/{TaskSwitcher-BEISb7-8.js → TaskSwitcher-D74_5q1F.js} +1 -1
- package/dist/web/assets/{TerminalPanel-B7PXaRGh.js → TerminalPanel-DNEKapEi.js} +1 -1
- package/dist/web/assets/{archive-Dyn5Oz68.js → archive-Ao0WD7pU.js} +1 -1
- package/dist/web/assets/{arrow-left-mWU3P1zb.js → arrow-left-a5_iLemp.js} +1 -1
- package/dist/web/assets/{calendar-clock-B6b0Cb3d.js → calendar-clock-BKbdz6Cu.js} +1 -1
- package/dist/web/assets/{chevron-right-Cl6g5_0e.js → chevron-right-8qYRfCj4.js} +1 -1
- package/dist/web/assets/{chevrons-up-down-FKryGzO4.js → chevrons-up-down-BXNG4GvK.js} +1 -1
- package/dist/web/assets/{clock-3-CfVjvMmA.js → clock-3-DEL1ixyh.js} +1 -1
- package/dist/web/assets/{copy-CIYuf7du.js → copy-Bd5v-KkM.js} +1 -1
- package/dist/web/assets/{download-DecDFX8n.js → download-CIKvpDBW.js} +1 -1
- package/dist/web/assets/{external-link-DaSwvjf7.js → external-link-B33h3DQN.js} +1 -1
- package/dist/web/assets/{folder-DZtlKvFm.js → folder-lOczceoh.js} +1 -1
- package/dist/web/assets/index-hZ37pkxs.js +203 -0
- package/dist/web/assets/{pause-Bd-STGLc.js → pause-nnvVbgsj.js} +1 -1
- package/dist/web/assets/{pencil-BoTIqqxX.js → pencil-_yfoOmUq.js} +1 -1
- package/dist/web/assets/{play-C4ctis0t.js → play-BilJ7SDs.js} +1 -1
- package/dist/web/assets/{plus-D08TlGJu.js → plus-BqqpYKaK.js} +1 -1
- package/dist/web/assets/{session-events-DKjIMNKI.js → session-events-FPOvcMBw.js} +19 -19
- package/dist/web/assets/{settings-BGRhMFaU.js → settings-CmJXtYTH.js} +1 -1
- package/dist/web/assets/{team-CPme0l2K.js → team-Bb04o2Tb.js} +1 -1
- package/dist/web/assets/{teamService-CVCtTVfY.js → teamService-B5w9cpsa.js} +1 -1
- package/dist/web/assets/{terminal-D7GsyYki.js → terminal-DOjdChj0.js} +1 -1
- package/dist/web/index.html +1 -1
- package/package.json +1 -1
- package/dist/chunk-2agbk8ef.js +0 -1
- package/dist/chunk-2bty4510.js +0 -6
- package/dist/chunk-2f7nr9hh.js +0 -1
- package/dist/chunk-2t9vtt75.js +0 -1
- package/dist/chunk-3aaehgva.js +0 -1
- package/dist/chunk-3t5r41yh.js +0 -1
- package/dist/chunk-5xgyx25z.js +0 -2
- package/dist/chunk-gjc1hhhv.js +0 -1
- package/dist/chunk-gx4seq5c.js +0 -10
- package/dist/chunk-h2gp7smy.js +0 -1
- package/dist/chunk-mc2mr1kn.js +0 -2
- package/dist/chunk-mkckss82.js +0 -1
- package/dist/chunk-ntpwqfy3.js +0 -1
- package/dist/chunk-q82ntq7t.js +0 -1
- package/dist/chunk-recafw5r.js +0 -171
- package/dist/chunk-smjfqtws.js +0 -1
- package/dist/chunk-wazhd8bm.js +0 -1
- package/dist/chunk-wf4s1hp2.js +0 -1
- package/dist/web/assets/ChatView-CQnuGDqk.js +0 -63
- package/dist/web/assets/index-DQaqO-lw.js +0 -203
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import{createRequire as a}from"node:module";var c=a(import.meta.url);
|
|
2
|
-
export{c as
|
|
2
|
+
export{c as Hk};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{pg as a,qg as b,rg as c}from"./chunk-8fx20am1.js";import"./chunk-hvmrcd84.js";import"./chunk-svsgtj41.js";import"./chunk-2g8avyq6.js";import"./chunk-mnk0b4nz.js";import"./chunk-tecbx0ek.js";export{b as resolveModelConfig,c as getModelDisplayName,a as getModelApiKeyEnvironmentVariable};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{Qg as a,Rg as b,Sg as c,Tg as d,Ug as e,Vg as f,Wg as g,Xg as h,Yg as i,Zg as j,_g as k}from"./chunk-xagh2qb6.js";import"./chunk-ascjys4e.js";import"./chunk-r4q06wbs.js";import"./chunk-ma1mn6hn.js";import"./chunk-2ff55pvt.js";import"./chunk-nxsarfy6.js";import"./chunk-e6j4vzta.js";import"./chunk-w2m4yczv.js";import"./chunk-zp5097qk.js";import"./chunk-g38d2ezm.js";import"./chunk-n8qg68y2.js";import"./chunk-pg7cgvs8.js";import"./chunk-svsgtj41.js";import"./chunk-2g8avyq6.js";import"./chunk-19zsecpx.js";import"./chunk-85b3kacc.js";import"./chunk-5cw3bevx.js";import"./chunk-mnk0b4nz.js";import"./chunk-tecbx0ek.js";export{g as withWorkspaceAgentResources,i as snapshotWorkspaceAgentResources,f as resolveWorkspaceAgentResources,k as resetWorkspaceAgentResources,d as refreshWorkspaceCommunicationStyles,h as getWorkspaceAgentResourceCacheStats,j as createEmptySessionAgentResources,e as configureInvocationPluginDirs,c as WorkspaceAgentResourceCapacityError,a as MAX_RESIDENT_WORKSPACE_AGENT_RESOURCES,b as MAX_ACTIVE_WORKSPACE_AGENT_RESOURCES};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
var F;((D)=>{D.DEFAULT="default";D.AUTO_EDIT="autoEdit";D.YOLO="yolo";D.PLAN="plan"})(F||={});import{Mutex as G}from"async-mutex";class H{entries=new Map;async runExclusive(C,E){let B=this.entries.get(C);if(!B)B={mutex:new G,operations:0},this.entries.set(C,B);B.operations++;try{return await B.mutex.runExclusive(E)}finally{if(B.operations--,B.operations===0&&this.entries.get(C)===B)this.entries.delete(C)}}getStats(){let C=0;for(let E of this.entries.values())C+=E.operations;return{keys:this.entries.size,operations:C}}}
|
|
2
|
-
export{F as
|
|
2
|
+
export{F as Oi,H as Pi};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{tf as v}from"./chunk-g4kydkyz.js";import{Mf as e}from"./chunk-0kghtvxj.js";import{$h as y,Ai as p,Ci as u,Di as d,Hi as l,Mi as i,Ni as t,bi as D,ci as h,ei as A,li as P,mi as T,oi as E,qi as _,ri as f,ti as C,xi as S,yi as m,zi as c}from"./chunk-e6j4vzta.js";import{Oi as Y}from"./chunk-w2m4yczv.js";import{Wi as X}from"./chunk-g38d2ezm.js";import{$i as L,_i as U,fj as M,gj as O,ij as $,jj as I,kj as G,mj as N,nj as j,pj as F,qj as R}from"./chunk-n8qg68y2.js";import{Aj as x,Cj as k,Fj as Z,yj as s}from"./chunk-pg7cgvs8.js";import{promises as a}from"node:fs";import g from"node:path";var r=["systemPrompt","appendSystemPrompt","initialMessage","resumeSessionId","forkSession","allowedTools","disallowedTools","mcpConfigPaths","strictMcpConfig","model","addDirs","outputFormat","inputFormat","print","includePartialMessages","replayUserMessages","agentsConfig","settingSources"],kk=new Set([...Object.keys(l),...r,"providerRequestConcurrency","providerGlobalConcurrency","providerOwnerConcurrency"]),W=k.Number({exclusiveMinimum:0}),z=k.String({minLength:1}),b=k.Array(k.String()),qk=k.Object({currentModelId:k.Optional(k.String()),modelProviders:k.Optional(k.Record(z,k.Object({name:z,baseUrl:z,wireApi:Z(["openai-completions","anthropic-messages"]),apiKeyEnv:k.Optional(z)}))),models:k.Optional(k.Array(k.Object({id:z,displayName:k.Optional(z),provider:z,model:z,overrides:k.Optional(k.Object({baseUrl:k.Optional(k.String()),temperature:k.Optional(k.Number()),maxOutputTokens:k.Optional(W),timeout:k.Optional(W),streamIdleTimeout:k.Optional(k.Number({minimum:1000})),apiVersion:k.Optional(k.String()),customHeaders:k.Optional(k.Record(k.String(),k.String())),maxRetries:k.Optional(k.Integer({minimum:0})),enablePromptCaching:k.Optional(k.Boolean())})),fallbackModels:k.Optional(k.Array(k.Object({provider:z,model:z,configId:k.Optional(z)})))}))),temperature:k.Optional(k.Number()),maxOutputTokens:k.Optional(W),stream:k.Optional(k.Boolean()),topP:k.Optional(k.Number()),topK:k.Optional(k.Number()),timeout:k.Optional(W),bashForegroundHandoffMs:k.Optional(k.Union([k.Literal(0),k.Integer({minimum:P,maximum:T})])),providerForegroundRecoveryMs:k.Optional(k.Union([k.Literal(0),k.Integer({minimum:U,maximum:L})])),providerCircuitBreakerOpenMs:k.Optional(k.Union([k.Literal(0),k.Integer({minimum:M,maximum:O})])),providerRequestConcurrency:k.Optional(k.Integer({minimum:$,maximum:I})),providerGlobalConcurrency:k.Optional(k.Integer({minimum:$,maximum:G})),providerOwnerConcurrency:k.Optional(k.Integer({minimum:$,maximum:G})),providerRequestAdmissionMs:k.Optional(k.Union([k.Literal(0),k.Integer({minimum:N,maximum:j})])),providerRequestPendingBytes:k.Optional(k.Integer({minimum:F,maximum:R})),agentTeamsEnabled:k.Optional(k.Boolean()),codeTheme:k.Optional(k.String()),uiTheme:k.Optional(Z(["light","dark","system"])),language:k.Optional(k.String()),fontSize:k.Optional(W),autoSaveSessions:k.Optional(k.Boolean()),notifyBuild:k.Optional(k.Boolean()),notifyErrors:k.Optional(k.Boolean()),notifySounds:k.Optional(k.Boolean()),privacyTelemetry:k.Optional(k.Boolean()),privacyCrash:k.Optional(k.Boolean()),debug:k.Optional(k.Union([k.Boolean(),k.String()])),mcpEnabled:k.Optional(k.Boolean()),mcpServers:k.Optional(k.Record(k.String(),k.Record(k.String(),k.Unknown()))),lspServers:k.Optional(k.Record(z,k.Object({command:z,args:k.Optional(k.Array(k.String())),extensionToLanguage:k.Record(z,z),env:k.Optional(k.Record(k.String(),k.String())),initializationOptions:k.Optional(k.Unknown()),settings:k.Optional(k.Unknown()),enabled:k.Optional(k.Boolean()),priority:k.Optional(k.Integer()),startupTimeout:k.Optional(k.Integer({minimum:100})),shutdownTimeout:k.Optional(k.Integer({minimum:100})),requestTimeout:k.Optional(k.Integer({minimum:100})),diagnosticWaitTimeout:k.Optional(k.Integer({minimum:0})),maxRestarts:k.Optional(k.Integer({minimum:0,maximum:10}))}))),permissionMode:k.Optional(k.Enum(Y)),maxTurns:k.Optional(k.Integer({minimum:-1})),maxConcurrentTasks:k.Optional(k.Integer({minimum:S,maximum:m})),maxQueuedTasks:k.Optional(k.Integer({minimum:c,maximum:p})),maxQueuedTaskBytes:k.Optional(k.Integer({minimum:u,maximum:d})),maxResidentSessionRuntimes:k.Optional(k.Integer({minimum:E,maximum:_})),sessionRuntimeIdleMs:k.Optional(k.Integer({minimum:f,maximum:C})),maxResidentSessionProjections:k.Optional(k.Integer({minimum:y,maximum:D})),sessionProjectionIdleMs:k.Optional(k.Integer({minimum:h,maximum:A})),systemPrompt:k.Optional(k.String()),appendSystemPrompt:k.Optional(k.String()),initialMessage:k.Optional(k.String()),resumeSessionId:k.Optional(k.String()),forkSession:k.Optional(k.Boolean()),allowedTools:k.Optional(k.Array(z)),disallowedTools:k.Optional(k.Array(z)),mcpConfigPaths:k.Optional(k.Array(z)),strictMcpConfig:k.Optional(k.Boolean()),model:k.Optional(z),addDirs:k.Optional(k.Array(z)),outputFormat:k.Optional(Z(["text","json","stream-json","jsonl"])),inputFormat:k.Optional(Z(["text","stream-json"])),print:k.Optional(k.Boolean()),includePartialMessages:k.Optional(k.Boolean()),replayUserMessages:k.Optional(k.Boolean()),agentsConfig:k.Optional(k.String()),settingSources:k.Optional(k.String()),permissions:k.Optional(k.Object({allow:k.Optional(b),ask:k.Optional(b),deny:k.Optional(b)})),env:k.Optional(k.Record(k.String(),k.String())),hooks:k.Optional(k.Record(k.String(),k.Unknown())),enabledPlugins:k.Optional(k.Record(z,k.Boolean())),pluginSourcePolicy:k.Optional(k.Object({restrictToAllowedSources:k.Optional(k.Boolean()),requireGitCommitSha:k.Optional(k.Boolean()),allowedGitHosts:k.Optional(k.Array(z)),allowedMarketplaces:k.Optional(k.Array(z)),allowedLocalRoots:k.Optional(k.Array(z))})),disableAllHooks:k.Optional(k.Boolean())}),wk=[["systemPrompt","systemPrompt"],["appendSystemPrompt","appendSystemPrompt"],["initialMessage","initialMessage"],["resumeSessionId","sessionId"],["forkSession","forkSession"],["allowedTools","allowedTools"],["disallowedTools","disallowedTools"],["mcpConfigPaths","mcpConfig"],["strictMcpConfig","strictMcpConfig"],["model","model"],["addDirs","addDir"],["outputFormat","outputFormat"],["inputFormat","inputFormat"],["print","print"],["includePartialMessages","includePartialMessages"],["replayUserMessages","replayUserMessages"],["agentsConfig","agents"],["settingSources","settingSources"],["permissionMode","permissionMode"],["maxTurns","maxTurns"],["maxConcurrentTasks","maxConcurrentTasks"],["maxQueuedTasks","maxQueuedTasks"],["maxQueuedTaskBytes","maxQueuedTaskBytes"],["maxResidentSessionRuntimes","maxResidentSessionRuntimes"],["sessionRuntimeIdleMs","sessionRuntimeIdleMs"],["maxResidentSessionProjections","maxResidentSessionProjections"],["sessionProjectionIdleMs","sessionProjectionIdleMs"]];function V(q,B){let w;try{w=JSON.parse(q)}catch(H){let K=H instanceof Error?`: ${H.message}`:"";throw Error(`Invalid JSON provided to --settings (${B})${K}`)}if(!w||typeof w!=="object"||Array.isArray(w))throw Error("--settings must contain a JSON object");for(let H of Object.keys(w))if(!kk.has(H))throw Error(`Unknown --settings field: ${H}`);let J=x(qk,w);if(!J.success){let H=J.error.issues.map((K)=>`${K.path.join(".")||"settings"}: ${K.message}`).join("; ");throw Error(`Invalid --settings value: ${H}`)}return J.data}async function n(q){if(q===void 0)return;let B=q.trim();if(!B)throw Error("--settings requires a JSON object or file path");if(B.startsWith("{"))return V(B,"inline JSON");let w=g.resolve(X(),B),J;try{J=await a.readFile(w,"utf8")}catch(H){let K=H instanceof Error?`: ${H.message}`:"";throw Error(`Unable to read --settings file ${w}${K}`)}return V(J,w)}function o(q,B){if(!B)return;let w=B;for(let[J,H]of wk){if(J==="permissionMode"&&q.yolo===!0)continue;if(q[H]===void 0&&w[J]!==void 0)q[H]=w[J]}}var Q=s("General"),Uk=(q)=>{if(q.yolo){if(q.permissionMode&&q.permissionMode!=="yolo")throw Error("Cannot use both --yolo and --permission-mode with different values");q.permissionMode="yolo"}if(Array.isArray(q.allowedTools))q.allowedTools=q.allowedTools.flatMap((B)=>B.split(",").map((w)=>w.trim()).filter((w)=>w.length>0));if(Array.isArray(q.disallowedTools))q.disallowedTools=q.disallowedTools.flatMap((B)=>B.split(",").map((w)=>w.trim()).filter((w)=>w.length>0));if(Array.isArray(q.allowedTools)&&Array.isArray(q.disallowedTools)){let B=q.allowedTools.filter((w)=>q.disallowedTools.includes(w));if(B.length>0)throw Error(`Tools cannot be both allowed and disallowed: ${B.join(", ")}`)}},Lk=async(q)=>{let B=await n(typeof q.settings==="string"?q.settings:void 0);if(o(q,B),typeof q.agents==="string")v(q.agents);zk(q);try{let J=await i.getInstance().initialize(B),H=t(J,q);if(e().config.actions.setConfig(H),q.debug)Q.info("[CLI] 配置已加载到 Store")}catch(w){Q.error("[CLI] [FAIL] 配置初始化失败",w instanceof Error?w.message:w),console.error(`
|
|
2
2
|
[FAIL] 配置初始化失败
|
|
3
3
|
`),console.error("原因:",w instanceof Error?w.message:"未知错误"),console.error(`
|
|
4
4
|
请检查:`),console.error(" 1. 配置文件格式是否正确 (~/.blade/config.json)"),console.error(" 2. 是否需要运行 blade 进行首次配置"),console.error(` 3. 配置文件权限是否正确
|
|
5
5
|
`),process.exit(1)}};function zk(q){if(q.continue&&q.resume)throw Error("Cannot use both --continue and --resume flags simultaneously");if(q.forkSession&&!q.continue&&!q.resume)throw Error("--fork-session requires --resume or --continue");if(q.sessionId&&(q.continue||q.resume)&&!q.forkSession)throw Error("--session-id can only be combined with --resume or --continue when --fork-session is set")}var Mk=(q)=>{if(q.jsonSchema&&q.outputSchema)throw Error("--json-schema cannot be combined with --output-schema");if((q.jsonSchema||q.outputSchema)&&!q.print&&!q.headless)throw Error("--json-schema and --output-schema can only be used with --print or --headless");if(q.outputFormat&&q.outputFormat!=="text"&&!q.print&&!q.headless)throw Error("--output-format can only be used with --print or --headless");if(q.headless&&q.outputFormat&&!["text","jsonl"].includes(q.outputFormat))throw Error(`--headless only supports --output-format text|jsonl, but got "${q.outputFormat}". Use --print for json|stream-json support.`);if(q.print&&q.outputFormat&&!["text","json","stream-json"].includes(q.outputFormat))throw Error(`--print only supports --output-format text|json|stream-json, but got "${q.outputFormat}". Use --headless for jsonl support.`);if(q.inputFormat==="stream-json"&&q.print)Q.warn("[WARN] Warning: stream-json input format may not work as expected with --print")};
|
|
6
|
-
export{Uk as
|
|
6
|
+
export{Uk as qf,Lk as rf,Mk as sf};
|