@wrongstack/cli 0.1.3 → 0.1.7
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/LICENSE +17 -13
- package/README.md +98 -0
- package/dist/index.js +712 -86
- package/dist/index.js.map +1 -1
- package/package.json +36 -8
package/LICENSE
CHANGED
|
@@ -1,17 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
Version 2.0, January 2004
|
|
3
|
-
http://www.apache.org/licenses/
|
|
1
|
+
MIT License
|
|
4
2
|
|
|
5
|
-
|
|
3
|
+
Copyright (c) 2026 ECOSTACK TECHNOLOGY OÜ
|
|
6
4
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
10
11
|
|
|
11
|
-
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
12
14
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
# @wrongstack/cli
|
|
2
|
+
|
|
3
|
+
The terminal binary for WrongStack. Provides the `wstack` and `wrongstack` commands.
|
|
4
|
+
|
|
5
|
+
Most users don't depend on this package directly — they install [`wrongstack`](../../README.md) (the umbrella) and run `wrongstack` / `wstack` from any project directory.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm install -g wrongstack
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
The `wrongstack` umbrella package transitively installs `@wrongstack/cli` along with `core`, `providers`, `tools`, `mcp`, and `tui`.
|
|
14
|
+
|
|
15
|
+
## Commands
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
wstack # interactive REPL — no flags = default
|
|
19
|
+
wstack --tui # Ink-based TUI
|
|
20
|
+
wstack --yolo # auto-approve every tool call
|
|
21
|
+
wstack "refactor src/auth.ts" # one-shot query (no interactive loop)
|
|
22
|
+
|
|
23
|
+
wstack --provider <id> --model <id> # skip the picker
|
|
24
|
+
wstack --resume <session-id> # resume a saved session
|
|
25
|
+
wstack resume <session-id> # equivalent
|
|
26
|
+
|
|
27
|
+
wstack init # interactive provider+model wizard
|
|
28
|
+
wstack doctor # config/key/MCP/Node health check
|
|
29
|
+
wstack export <session-id> # render a session as markdown/JSON/plain text
|
|
30
|
+
wstack mcp add <preset> # add an MCP server (see @wrongstack/mcp)
|
|
31
|
+
wstack mcp list # show configured MCP servers
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
`--no-tui` forces REPL mode even when `--tui` is configured globally. `--alt-screen` opts into Ink's alt-screen rendering (off by default so the user keeps native scrollback).
|
|
35
|
+
|
|
36
|
+
## Slash commands inside the REPL/TUI
|
|
37
|
+
|
|
38
|
+
```
|
|
39
|
+
/help # list of commands
|
|
40
|
+
/help <name> # detailed help for one command
|
|
41
|
+
/clear # wipe context + memory + visible history
|
|
42
|
+
/model # change model mid-session
|
|
43
|
+
/use <provider> # switch provider
|
|
44
|
+
/mode <id> # activate a mode (debugger, code-reviewer, …)
|
|
45
|
+
/memory # show/edit project memory
|
|
46
|
+
/skill [name] # list skills / show a specific skill
|
|
47
|
+
/context # show token usage breakdown
|
|
48
|
+
/sessions # list past sessions
|
|
49
|
+
/resume <id> # resume a session
|
|
50
|
+
/exit # quit
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
## Configuration
|
|
54
|
+
|
|
55
|
+
```
|
|
56
|
+
~/.wrongstack/config.json global config (provider, model defaults, features)
|
|
57
|
+
~/.wrongstack/.key AES-256-GCM secret-vault key (mode 0600)
|
|
58
|
+
~/.wrongstack/memory.md user-global memory
|
|
59
|
+
~/.wrongstack/skills/ user-global skills
|
|
60
|
+
~/.wrongstack/projects/<hash>/ per-project state
|
|
61
|
+
memory.md project memory (auto-gitignored)
|
|
62
|
+
sessions/ JSONL session logs
|
|
63
|
+
trust.json per-project tool/permission trust
|
|
64
|
+
.wrongstack/AGENTS.md committable project memory
|
|
65
|
+
.wrongstack/skills/ committable project skills
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
API keys are encrypted at rest with AES-256-GCM and the key file at `~/.wrongstack/.key`. The vault auto-bootstraps on first run; the key never leaves the machine.
|
|
69
|
+
|
|
70
|
+
## Flags
|
|
71
|
+
|
|
72
|
+
| Flag | Effect |
|
|
73
|
+
|------|--------|
|
|
74
|
+
| `--tui` / `--no-tui` | Force/disable Ink TUI |
|
|
75
|
+
| `--yolo` | Auto-approve every tool call (use with care) |
|
|
76
|
+
| `--provider <id>` | Override the configured provider |
|
|
77
|
+
| `--model <id>` | Override the configured model |
|
|
78
|
+
| `--resume <id>` | Resume a saved session by id |
|
|
79
|
+
| `--alt-screen` | Opt into alt-screen TUI rendering |
|
|
80
|
+
| `--config <path>` | Use a non-default config file |
|
|
81
|
+
| `--debug` | Verbose logging to `~/.wrongstack/logs/wrongstack.log` |
|
|
82
|
+
| `--version` | Print version |
|
|
83
|
+
| `--help` | Print help |
|
|
84
|
+
|
|
85
|
+
## Environment variables
|
|
86
|
+
|
|
87
|
+
| Variable | Purpose |
|
|
88
|
+
|----------|---------|
|
|
89
|
+
| `WRONGSTACK_BASH_ENV_PASSTHROUGH=1` | Disable the bash-tool env allowlist (legacy unsafe mode — see [SECURITY.md](../../SECURITY.md)) |
|
|
90
|
+
| `WRONGSTACK_CONFIG_DIR` | Override `~/.wrongstack` location |
|
|
91
|
+
| `WRONGSTACK_DEBUG=1` | Same as `--debug` |
|
|
92
|
+
| `NO_COLOR=1` | Disable ANSI colors |
|
|
93
|
+
|
|
94
|
+
Provider API keys can be set via env (`ANTHROPIC_API_KEY`, `OPENAI_API_KEY`, …) or stored encrypted via `wstack` first-run wizard.
|
|
95
|
+
|
|
96
|
+
## License
|
|
97
|
+
|
|
98
|
+
MIT
|