infernoflow 0.44.12 → 0.44.13
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 +3 -2
- package/dist/lib/commands/refresh.mjs +5 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -123,8 +123,9 @@ The injected memory block is paid for on every AI turn (and twice when a tool lo
|
|
|
123
123
|
Or write the same values via CLI flags:
|
|
124
124
|
|
|
125
125
|
```bash
|
|
126
|
-
infernoflow setup --max-memory 3 --max-commits 5 --max-entry-chars 200 --
|
|
127
|
-
infernoflow refresh --
|
|
126
|
+
infernoflow setup --max-memory 3 --max-commits 5 --max-entry-chars 200 --protocol-style compact
|
|
127
|
+
infernoflow refresh --targets CLAUDE.md,.cursorrules # only these get the block; the rest are stripped
|
|
128
|
+
infernoflow refresh --targets auto # canonical file for the IDE you're in (kills Copilot's double-load)
|
|
128
129
|
infernoflow prune --apply --max-age-days 14 # one-off cleanup
|
|
129
130
|
```
|
|
130
131
|
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import{refreshRuleFilesFromMemory as
|
|
2
|
-
`+
|
|
1
|
+
import*as y from"node:path";import{refreshRuleFilesFromMemory as h}from"../ruleFiles.mjs";import{updateInjectionConfig as x}from"../amp/io.mjs";import{findProjectRoot as C}from"../projectRoot.mjs";import{detectIdeContext as E}from"../ai/ideDetection.mjs";import{bold as u,cyan as f,gray as c,green as d,red as m}from"../ui/output.mjs";const a=y.join(".github","copilot-instructions.md"),O=[".cursorrules","CLAUDE.md",a];function i(o,r){const t=o.indexOf(r);if(t===-1)return;const n=parseInt(o[t+1],10);return Number.isFinite(n)?n:void 0}function p(o,r){const t=o.indexOf(r);return t!==-1&&o[t+1]?o[t+1]:void 0}function j(){const o=process.env;if(o.CLAUDE_CODE_SESSION||o.CLAUDECODE)return["CLAUDE.md"];const{ideDetected:r}=E("auto");return r==="cursor"?[".cursorrules"]:r==="vscode"?[a]:O}function L(o){const r={},t=i(o,"--max-memory");t!==void 0&&(r.maxEntries=t);const n=i(o,"--max-commits");n!==void 0&&(r.maxCommits=n);const s=i(o,"--max-entry-chars");s!==void 0&&(r.maxEntryChars=s),o.includes("--no-protocol")&&(r.includeProtocol=!1),o.includes("--protocol")&&(r.includeProtocol=!0);const l=p(o,"--protocol-style");l&&["compact","full","off"].includes(l)&&(r.protocolStyle=l);const e=p(o,"--targets");return e&&(r.targets=e==="auto"?j():e.split(",").map(g=>g.trim()).filter(Boolean)),r}async function R(o){const r=o.includes("--dry-run")||o.includes("-n"),t=o.includes("--json"),n=C(process.cwd()),s=L(o);if(!r&&Object.keys(s).length)try{x(n,s)}catch{}if(s.targets&&!t){const e=s.targets.length<3;console.log(`
|
|
2
|
+
`+d("\u2714")+c(" memory block \u2192 ")+f(s.targets.join(", "))+(e?c(" (other rule files' blocks are stripped \u2014 no double-load)"):""))}if(r){if(t){console.log(JSON.stringify({dryRun:!0,projectRoot:n},null,2));return}console.log(`
|
|
3
|
+
`+u("\u{1F525} infernoflow refresh")+c(" \u2014 dry run")),console.log(" "+c("Project root: ")+f(n)),console.log(" "+c("Would rewrite: ")+".cursorrules, CLAUDE.md, .github/copilot-instructions.md"),console.log();return}let l;try{l=h(n)}catch(e){t?console.log(JSON.stringify({ok:!1,error:e.message},null,2)):console.error(m(`
|
|
3
4
|
\u2718 refresh failed: `)+e.message+`
|
|
4
|
-
`),process.exit(1)}if(t){console.log(JSON.stringify({ok:!0,projectRoot:n,results:
|
|
5
|
-
`+
|
|
5
|
+
`),process.exit(1)}if(t){console.log(JSON.stringify({ok:!0,projectRoot:n,results:l},null,2));return}console.log(`
|
|
6
|
+
`+u("\u{1F525} infernoflow refresh")),console.log(" "+"\u2500".repeat(50));for(const e of l)"error"in e&&e.error?console.log(" "+m("\u2718 ")+e.rel+c(" \u2014 "+e.error)):"created"in e&&(e.created||e.updated)?console.log(" "+d("\u2714 ")+e.rel+c(e.created?" \u2014 created":" \u2014 updated")):console.log(" "+c("\xB7 ")+e.rel+c(" \u2014 unchanged"));console.log()}export{L as injectionPatchFromArgs,R as refreshCommand,j as resolveAutoTargets};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "infernoflow",
|
|
3
|
-
"version": "0.44.
|
|
3
|
+
"version": "0.44.13",
|
|
4
4
|
"description": "Persistent memory for AI coding sessions — captures what agents can't infer from code alone. Works with Copilot, Cursor, Claude, and Windsurf.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|