monkeyscode-cli 0.1.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 +226 -0
- package/dist/monkeyscode-cli.cjs +710 -0
- package/package.json +61 -0
package/README.md
ADDED
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
# MonkeysCode CLI
|
|
2
|
+
|
|
3
|
+
> AI-powered coding agent for the terminal. Works on macOS, Linux, and Windows.
|
|
4
|
+
|
|
5
|
+
[](https://www.npmjs.com/package/@monkeyscode/cli)
|
|
6
|
+
[](https://github.com/MonkeysCloud/monkeyscode/actions)
|
|
7
|
+
[](LICENSE)
|
|
8
|
+
|
|
9
|
+
<!-- TODO: Replace with actual asciinema recording -->
|
|
10
|
+
<!--  -->
|
|
11
|
+
|
|
12
|
+
## Quick Install
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
# macOS / Linux
|
|
16
|
+
curl -fsSL https://monkeyscode.com/install.sh | sh
|
|
17
|
+
|
|
18
|
+
# Windows (PowerShell)
|
|
19
|
+
irm https://monkeyscode.com/install.ps1 | iex
|
|
20
|
+
|
|
21
|
+
# npm
|
|
22
|
+
npm install -g @monkeyscode/cli
|
|
23
|
+
|
|
24
|
+
# Homebrew
|
|
25
|
+
brew install monkeyscode
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Usage
|
|
29
|
+
|
|
30
|
+
```bash
|
|
31
|
+
# Interactive REPL
|
|
32
|
+
mc "refactor the auth module"
|
|
33
|
+
|
|
34
|
+
# Headless (CI/CD)
|
|
35
|
+
mc -p "fix all lint errors" --headless --auto-approve
|
|
36
|
+
|
|
37
|
+
# Background job with auto-PR
|
|
38
|
+
mc -p "write tests" --background --auto-branch --auto-pr
|
|
39
|
+
|
|
40
|
+
# Pipe mode
|
|
41
|
+
echo "explain this error" | mc
|
|
42
|
+
|
|
43
|
+
# Model selection
|
|
44
|
+
mc --model claude-opus "deep architecture review"
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
<!-- TODO: Record with asciinema and convert to GIF -->
|
|
48
|
+
<!--  -->
|
|
49
|
+
|
|
50
|
+
## Features
|
|
51
|
+
|
|
52
|
+
### 🤖 Multi-Model Support
|
|
53
|
+
Switch between Claude, GPT-4o, Gemini, and MonkeysCode's own Capuchin model.
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
mc --model auto "fix the bug" # Smart model selection
|
|
57
|
+
mc --model claude-opus "review PR" # Specific model
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### 📁 Full Tool Suite
|
|
61
|
+
The agent can edit files, run terminal commands, search code, and manage git — all locally.
|
|
62
|
+
|
|
63
|
+
<!-- TODO: Record with asciinema -->
|
|
64
|
+
<!--  -->
|
|
65
|
+
|
|
66
|
+
### 🔒 Sandboxed Execution
|
|
67
|
+
Run agent commands in isolated sandboxes (bubblewrap, sandbox-exec, Docker).
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
mc --sandbox "run the migration script"
|
|
71
|
+
mc --sandbox-network=none "process sensitive data"
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
### 🌐 Background Jobs
|
|
75
|
+
Submit long-running tasks to the cloud and get notified when done.
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
mc -p "write comprehensive tests" --background --auto-pr
|
|
79
|
+
mc jobs list
|
|
80
|
+
mc jobs logs abc123 --follow
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### 🧠 Memory & Conventions
|
|
84
|
+
The agent learns your project's conventions and remembers them.
|
|
85
|
+
|
|
86
|
+
```bash
|
|
87
|
+
mc memory add "Always use camelCase for variables"
|
|
88
|
+
mc memory show
|
|
89
|
+
mc dream # Consolidate session history into memory
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
### ⚡ CI/CD Integration
|
|
93
|
+
Run headlessly in GitHub Actions, GitLab CI, or any CI system.
|
|
94
|
+
|
|
95
|
+
```yaml
|
|
96
|
+
# .github/workflows/review.yml
|
|
97
|
+
- uses: MonkeysCloud/monkeyscode@main
|
|
98
|
+
with:
|
|
99
|
+
prompt: 'Review this PR'
|
|
100
|
+
mode: plan
|
|
101
|
+
output: github
|
|
102
|
+
api-key: ${{ secrets.MONKEYSCODE_API_KEY }}
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
### 🔌 MCP Servers
|
|
106
|
+
Extend the agent with custom tools via the Model Context Protocol.
|
|
107
|
+
|
|
108
|
+
```bash
|
|
109
|
+
mc mcp add jira npx @monkeyscode/mcp-jira
|
|
110
|
+
mc mcp add slack npx @monkeyscode/mcp-slack
|
|
111
|
+
mc mcp list
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
### 👥 Multi-Agent Teams
|
|
115
|
+
Spawn parallel agents to divide and conquer large tasks.
|
|
116
|
+
|
|
117
|
+
```bash
|
|
118
|
+
mc team spawn --task "Implement auth, payments, and email modules"
|
|
119
|
+
mc team status
|
|
120
|
+
mc team merge team-abc123
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
## Output Formats
|
|
124
|
+
|
|
125
|
+
| Format | Use Case |
|
|
126
|
+
|--------|----------|
|
|
127
|
+
| `text` | Interactive terminal (default) |
|
|
128
|
+
| `json` | Structured result for scripts |
|
|
129
|
+
| `jsonl` | Streaming events for real-time parsing |
|
|
130
|
+
| `diff` | Unified diff (`git apply` compatible) |
|
|
131
|
+
| `markdown` | Clean markdown (for PR descriptions) |
|
|
132
|
+
| `github` | GitHub Actions output format |
|
|
133
|
+
| `azure` | Azure DevOps format |
|
|
134
|
+
| `sarif` | SARIF 2.1.0 for code scanning |
|
|
135
|
+
|
|
136
|
+
## Configuration
|
|
137
|
+
|
|
138
|
+
```bash
|
|
139
|
+
mc config set defaultModel claude-sonnet # Set default model
|
|
140
|
+
mc config set theme dark # Set theme
|
|
141
|
+
mc config list # Show all settings
|
|
142
|
+
mc config path # Show config file locations
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
Project-level config: `.monkeyscode/config.json`
|
|
146
|
+
|
|
147
|
+
## Shell Completions
|
|
148
|
+
|
|
149
|
+
```bash
|
|
150
|
+
mc completions bash >> ~/.bashrc
|
|
151
|
+
mc completions zsh >> ~/.zshrc
|
|
152
|
+
mc completions fish > ~/.config/fish/completions/mc.fish
|
|
153
|
+
mc completions powershell >> $PROFILE
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
## Slash Commands (REPL)
|
|
157
|
+
|
|
158
|
+
| Command | Description |
|
|
159
|
+
|---------|-------------|
|
|
160
|
+
| `/help` | Show all commands |
|
|
161
|
+
| `/model <name>` | Switch model |
|
|
162
|
+
| `/mode <mode>` | Switch mode (agent/plan/ask) |
|
|
163
|
+
| `/compact` | Toggle compact output |
|
|
164
|
+
| `/diff` | Show session changes |
|
|
165
|
+
| `/undo` | Revert last edit |
|
|
166
|
+
| `/commit [msg]` | Commit changes |
|
|
167
|
+
| `/files` | List touched files |
|
|
168
|
+
| `/cost` | Show token usage |
|
|
169
|
+
| `/vim` | Toggle Vim keybindings |
|
|
170
|
+
| `/cloud` | Hand off to cloud |
|
|
171
|
+
| `/context <file>` | Add file to context |
|
|
172
|
+
|
|
173
|
+
## SDK
|
|
174
|
+
|
|
175
|
+
Build custom integrations with the TypeScript SDK:
|
|
176
|
+
|
|
177
|
+
```bash
|
|
178
|
+
npm install @monkeyscode/sdk
|
|
179
|
+
```
|
|
180
|
+
|
|
181
|
+
```typescript
|
|
182
|
+
import { MonkeysCode } from '@monkeyscode/sdk';
|
|
183
|
+
|
|
184
|
+
const agent = new MonkeysCode({ apiKey: process.env.MONKEYSCODE_API_KEY });
|
|
185
|
+
const result = await agent.run('Fix all TypeScript errors');
|
|
186
|
+
console.log(result.summary);
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
See [`@monkeyscode/sdk`](../packages/sdk-typescript/) for full documentation.
|
|
190
|
+
|
|
191
|
+
## Accessibility
|
|
192
|
+
|
|
193
|
+
Screen reader-friendly mode (no ANSI codes, no animations):
|
|
194
|
+
|
|
195
|
+
```bash
|
|
196
|
+
mc --accessible "fix the bug"
|
|
197
|
+
# or
|
|
198
|
+
export MONKEYSCODE_ACCESSIBLE=1
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
## Telemetry
|
|
202
|
+
|
|
203
|
+
Telemetry is enabled by default and collects anonymous usage data to improve the product.
|
|
204
|
+
|
|
205
|
+
```bash
|
|
206
|
+
mc telemetry status # Check status
|
|
207
|
+
mc telemetry disable # Opt out
|
|
208
|
+
mc telemetry show # See what's collected
|
|
209
|
+
```
|
|
210
|
+
|
|
211
|
+
Respects the `DO_NOT_TRACK=1` environment variable.
|
|
212
|
+
|
|
213
|
+
## Documentation
|
|
214
|
+
|
|
215
|
+
- [CLI Overview](../../docs/coding-agent/cli/00-cli-overview.md)
|
|
216
|
+
- [Core Runtime](../../docs/coding-agent/cli/01-core-runtime.md)
|
|
217
|
+
- [Interactive Experience](../../docs/coding-agent/cli/02-interactive-experience.md)
|
|
218
|
+
- [Auth & Configuration](../../docs/coding-agent/cli/03-auth-configuration.md)
|
|
219
|
+
- [Headless / CI/CD](../../docs/coding-agent/cli/04-headless-cicd.md)
|
|
220
|
+
- [Background & Cloud](../../docs/coding-agent/cli/05-background-cloud.md)
|
|
221
|
+
- [Distribution](../../docs/coding-agent/cli/06-distribution.md)
|
|
222
|
+
- [SDK & Extensibility](../../docs/coding-agent/cli/07-sdk-extensibility.md)
|
|
223
|
+
|
|
224
|
+
## License
|
|
225
|
+
|
|
226
|
+
MIT © [MonkeysCloud Corp](https://monkeyscode.com)
|