@karmaniverous/stan-cli 0.11.7 → 0.12.0
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 +16 -16
- package/dist/cjs/classifier-Bqzr65UC-D9z0tWqn.js +1 -0
- package/dist/cjs/index.js +1 -1
- package/dist/cli/{capture-DKrVoDyl.js → capture-CiVimFuL.js} +1 -1
- package/dist/cli/classifier-Bqzr65UC-BlsMFS8t.js +7 -0
- package/dist/cli/{config-fallback-CV720XTz.js → config-fallback-CL_TDiMw.js} +1 -1
- package/dist/cli/{context-PS5ukh8q.js → context-BzEQ3A1v.js} +1 -1
- package/dist/cli/{index-Cq8YEju6.js → index-DXJaQ46Q.js} +1236 -867
- package/dist/cli/stan.js +904 -170
- package/dist/mjs/classifier-Bqzr65UC-DJLYQY2b.js +1 -0
- package/dist/mjs/index.js +1 -1
- package/dist/types/index.d.ts +30 -2
- package/package.json +27 -27
- package/dist/cjs/classifier-DeYwffC_-CjzCgatc.js +0 -1
- package/dist/cli/classifier-DeYwffC_-DftahF7h.js +0 -7
- package/dist/mjs/classifier-DeYwffC_-C7wwqop3.js +0 -1
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
# STAN — STAN Tames Autoregressive Nonsense
|
|
4
4
|
|
|
5
|
-
[](https://www.npmjs.com/package/@karmaniverous/stan-cli)  <!-- TYPEDOC_EXCLUDE --> [](https://docs.karmanivero.us/stan) [](https://github.com/karmaniverous/stan-cli/tree/main/CHANGELOG.md)<!-- /TYPEDOC_EXCLUDE --> [](https://github.com/karmaniverous/stan-cli/tree/main/LICENSE
|
|
5
|
+
[](https://www.npmjs.com/package/@karmaniverous/stan-cli)  <!-- TYPEDOC_EXCLUDE --> [](https://docs.karmanivero.us/stan) [](https://github.com/karmaniverous/stan-cli/tree/main/CHANGELOG.md)<!-- /TYPEDOC_EXCLUDE --> [](https://github.com/karmaniverous/stan-cli/tree/main/LICENSE)
|
|
6
6
|
|
|
7
7
|

|
|
8
8
|
|
|
@@ -100,7 +100,7 @@ scripts:
|
|
|
100
100
|
typecheck: npm run typecheck
|
|
101
101
|
```
|
|
102
102
|
|
|
103
|
-
See [STAN Configuration](./
|
|
103
|
+
See [STAN Configuration](./guides/configuration.md) for more!
|
|
104
104
|
|
|
105
105
|
---
|
|
106
106
|
|
|
@@ -130,7 +130,7 @@ See [STAN Configuration](./docs-src/configuration.md) for more!
|
|
|
130
130
|
stan patch -f file.patch # from file
|
|
131
131
|
```
|
|
132
132
|
|
|
133
|
-
See [CLI Usage & Examples](./
|
|
133
|
+
See [CLI Usage & Examples](./guides/cli-examples.md) for more!
|
|
134
134
|
|
|
135
135
|
---
|
|
136
136
|
|
|
@@ -138,23 +138,23 @@ See [CLI Usage & Examples](./docs-src/cli-examples.md) for more!
|
|
|
138
138
|
|
|
139
139
|
- [API reference](https://docs.karmanivero.us/stan)
|
|
140
140
|
- Guides:
|
|
141
|
-
- [Getting Started](./
|
|
142
|
-
- [The STAN Loop](./
|
|
143
|
-
- [CLI Usage & Examples](./
|
|
144
|
-
- [Migration — Namespaced Configuration](./
|
|
145
|
-
- [Stan Configuration](./
|
|
146
|
-
- [Patch Workflow & Diagnostics](./
|
|
147
|
-
- [Archives & Snapshots](./
|
|
148
|
-
|
|
141
|
+
- [Getting Started](./guides/getting-started.md) — Install the CLI, initialize a repo, and attach archives in chat. Recommended chat setup: import the STAN GPT agent into TypingMind (bootloader included; requires GPT‑5 access) via [this link](https://www.typingmind.com/characters/c-01K5X5RVA4N1DWBQWWJBYDNX2W).
|
|
142
|
+
- [The STAN Loop](./guides/the-stan-loop.md) — How Build & Snapshot → Share & Baseline → Discuss & Patch work together.
|
|
143
|
+
- [CLI Usage & Examples](./guides/cli-examples.md) — Common flags and invocation patterns, including `-p`, `-P`, `-S`, `-A`, and `-c`.
|
|
144
|
+
- [Migration — Namespaced Configuration](./guides/migration.md) — Upgrade legacy configs using `stan init` (backs up `.bak`; supports `--dry-run`).
|
|
145
|
+
- [Stan Configuration](./guides/configuration.md) — All config keys, includes/excludes semantics, and phase‑scoped CLI defaults.
|
|
146
|
+
- [Patch Workflow & Diagnostics](./guides/patch-workflow.md) — Unified diff policy, diagnostics envelopes, and assistant expectations.
|
|
147
|
+
- [Archives & Snapshots](./guides/archives-and-snapshots.md) — What goes into `archive.tar`/`archive.diff.tar`, combine mode, and snapshot history. Additional references:
|
|
148
|
+
- [Bootloader & Assistant Setup](./guides/bootloader.md) — How the assistant loads `.stan/system/stan.system.md` from attached archives.
|
|
149
149
|
- The following documents are maintained by STAN and live under `<stanPath>/system/` in your repo:
|
|
150
150
|
- `stan.project.md` contains your evolving project requirements.
|
|
151
|
-
- `stan
|
|
151
|
+
- `stan.todo.md` contains your evolving development plan.
|
|
152
152
|
|
|
153
153
|
- Case studies:
|
|
154
|
-
- [rrstack](./
|
|
155
|
-
- Comparison: [Why STAN Over Alternatives?](./
|
|
156
|
-
- Tutorial: [Quickstart (End‑to‑End)](./
|
|
157
|
-
- FAQ
|
|
154
|
+
- [rrstack](./guides/case-studies/rrstack.md) — how STAN enabled rapid development in a couple of days.
|
|
155
|
+
- Comparison: [Why STAN Over Alternatives?](./guides/why-stan-over-alternatives.md)
|
|
156
|
+
- Tutorial: [Quickstart (End‑to‑End)](./guides/tutorial-quickstart.md)
|
|
157
|
+
- [FAQ](./guides/faq.md) — answers to common questions and pitfalls.
|
|
158
158
|
- Contributing: [Dev Quickstart](./contributing.md)
|
|
159
159
|
|
|
160
160
|
---
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var t=require("node:fs/promises"),e=require("node:path");const n=1048576;exports.classifyForArchive=async function(s,r){const i=[],a=[],o=[];await Promise.all(r.map(async r=>{const c=r.replace(/\\/g,"/"),l=e.resolve(s,r);let h=0;try{h=(await t.stat(l)).size}catch{return}let u,p=!1;try{p=await(async e=>{try{const n=await t.open(e,"r");try{const t=Buffer.allocUnsafe(8192),{bytesRead:e}=await n.read(t,0,t.length,0);for(let n=0;n<e;n+=1)if(0===t[n])return!0;return!1}finally{await n.close().catch(()=>{})}}catch{return!1}})(l)}catch{p=!1}if(p)a.push({path:c,size:h});else{i.push(c);try{(h<=n||h<5*n)&&(u=(t=>{const e=t.replace(/\r\n/g,"\n");return 0===e.length?0:e.split("\n").length})(await t.readFile(l,"utf8")))}catch{}(h>n||"number"==typeof u&&u>3e3)&&o.push({path:c,size:h,loc:u})}}));const c=[];if(a.length>0){c.push(`Binary files excluded from archive (${a.length.toString()}):`);for(const t of a)c.push(` - ${t.path} (${t.size.toString()} bytes)`);c.push("")}if(o.length>0){c.push(`Large text files (included; consider excludes if unwanted) (${o.length.toString()}):`);for(const t of o){const e=[` - ${t.path}`,`(${t.size.toString()} bytes)`];"number"==typeof t.loc&&e.push(`${t.loc.toString()} LOC`),c.push(e.join(" "))}c.push(""),c.push(`Thresholds: size > ${n.toString()} bytes or LOC > ${3e3.toString()}`)}0===c.length&&c.push("No archive warnings.");const l=c.join("\n")+(c.length?"\n":"");return{textFiles:i,excludedBinaries:a,largeText:o,warningsBody:l}};
|