howtofixcli 0.4.8 → 0.4.9

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 (2) hide show
  1. package/dist/main.js +1 -1
  2. package/package.json +1 -1
package/dist/main.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- var sS=Object.defineProperty;var m=(e,t,n)=>()=>{if(n)throw n[0];try{return e&&(t=e(e=0)),t}catch(r){throw n=[r],r}};var Rt=(e,t)=>{for(var n in t)sS(e,n,{get:t[n],enumerable:!0})};var Et,jr,Cl,Ll,vo=m(()=>{Et="HowToFix",jr="0.4.8",Cl=["You are HowToFix, a coding agent. The user wants the actual fix, not a tour of the problem.","Lead with the diagnosis in one or two sentences, then change the code. Prefer the smallest correct change over a rewrite.","When you edit files, say which file and why in a short line. Do not narrate tool calls. Never mention the underlying harness, its vendor, or its project name to the user."].join(`
2
+ var sS=Object.defineProperty;var m=(e,t,n)=>()=>{if(n)throw n[0];try{return e&&(t=e(e=0)),t}catch(r){throw n=[r],r}};var Rt=(e,t)=>{for(var n in t)sS(e,n,{get:t[n],enumerable:!0})};var Et,jr,Cl,Ll,vo=m(()=>{Et="HowToFix",jr="0.4.9",Cl=["You are HowToFix, a coding agent. The user wants the actual fix, not a tour of the problem.","Lead with the diagnosis in one or two sentences, then change the code. Prefer the smallest correct change over a rewrite.","When you edit files, say which file and why in a short line. Do not narrate tool calls. Never mention the underlying harness, its vendor, or its project name to the user."].join(`
3
3
  `),Ll=["# Project notes","","## What this is","","## Commands","- build:","- test:","","## Conventions","-",""].join(`
4
4
  `)});var Nl={};Rt(Nl,{AGENTS_STORE_DIR:()=>Fr,AGENT_DIR:()=>Xe,CUBENCE_CACHE_PATH:()=>uu,WORKFLOWS_DIR:()=>pu,pinAgentDir:()=>cu});import{homedir as iS}from"node:os";import{join as Hs}from"node:path";function cu(){process.env.PI_CODING_AGENT_DIR=Xe}var Xe,Fr,uu,pu,qn=m(()=>{Xe=process.env.HOWTOFIX_CODING_AGENT_DIR?.trim()||Hs(iS(),".howtofix","agent"),Fr=Hs(Xe,"agents"),uu=Hs(Xe,"cubence-cache.json"),pu=Hs(Xe,"workflows")});var zl={};Rt(zl,{DEFAULT_CONTEXT_WINDOW:()=>Gl,HOWTOFIX_BASE_URL:()=>Vs,HOWTOFIX_CONSOLE_URL:()=>Js,HOWTOFIX_MODEL_COMPAT:()=>fu,HOWTOFIX_PROVIDERS:()=>lu,HTTP_IDLE_TIMEOUT_MS:()=>Kl,applyCompat:()=>Xs,checkAccount:()=>bu,countNewModels:()=>hu,ensureGatewaySettings:()=>pS,isHowtofixProvider:()=>So,looksLikeToken:()=>gu,maskToken:()=>Ys,mergeModels:()=>xu,newProviderEntry:()=>du,parseModelIds:()=>Wl,probeModel:()=>yu,repairGatewayModels:()=>uS});import{existsSync as aS,mkdirSync as mS,readFileSync as ql,writeFileSync as _l}from"node:fs";import{join as Ul}from"node:path";function du(){return{baseUrl:Vs,api:"openai-completions"}}function uS(e){let t=Ul(e,"models.json"),n;try{n=JSON.parse(ql(t,"utf8"))}catch{return 0}let r=n.providers;if(!r||typeof r!="object")return 0;let o=0;for(let i of lu){let a=r[i];if(!a||!Array.isArray(a.models))continue;let p=Xs(a.models);p.changed!==0&&(a.models=p.models,o+=p.changed)}if(o===0)return 0;try{_l(t,`${JSON.stringify(n,null,2)}
5
5
  `)}catch{return 0}return o}function pS(e){let t=Ul(e,"settings.json"),n={};try{let r=ql(t,"utf8"),o=JSON.parse(r);o&&typeof o=="object"&&!Array.isArray(o)&&(n=o)}catch{if(aS(t))return!1}if("httpIdleTimeoutMs"in n)return!1;n.httpIdleTimeoutMs=Kl;try{mS(e,{recursive:!0}),_l(t,`${JSON.stringify(n,null,2)}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "howtofixcli",
3
- "version": "0.4.8",
3
+ "version": "0.4.9",
4
4
  "type": "module",
5
5
  "description": "HowToFix coding agent. Workbench TUI, sessions, background agents.",
6
6
  "license": "UNLICENSED",