← Back to Kontasks
Adding Directories in Konsole vs Claude CLI
Explanation of how directory access works differently in konsole compared to Claude Code CLI
Output
📁 Adding Directories in Konsole
Key Difference
Konsole uses a hardcoded allowed path approach, not the Claude CLI's
/add command.Claude Code CLI
In the Claude Code CLI, you can dynamically add directories:
/add /path/to/directory /add ~/projects/myapp
This adds the directory to Claude's context for the current session.
Konsole (Current Implementation)
Konsole has a hardcoded allowlist in konsole/src/tools.ts:
const ALLOWED_PATH_PREFIXES = [ "/konnectvol/", ];
This means Claude (via konsole) can only access files within /konnectvol/.
Why This Design?
| ✓ | Security | Prevents Claude from accessing system files, secrets, etc. |
| ✓ | Simplicity | No session-level state to manage for paths |
| ✓ | Server Context | Konsole runs on a server, not your local machine |
To Add More Directories
Currently requires editing konsole/src/tools.ts:
const ALLOWED_PATH_PREFIXES = [ "/konnectvol/", "/home/myuser/projects/", // Add new paths here ];
Then restart konsole for changes to take effect.
💡 Future Enhancement Idea
Could add environment variable or config file support:
KONSOLE_ALLOWED_PATHS="/konnectvol/,/home/user/projects/"
This would make it configurable without code changes.
Quick Actions
Original Request
No layout configured
Details
Type
General
Status
Completed
Scope
vibetools
Tags
konsoleclaudeconfiguration
Created
8 Jan 2026, 12:20 am
Updated
8 Jan 2026, 12:20 am
Timing
⏱️ 50.5s
0 tools
● TTFE 0%
● Thinking 100%
● Tools 0%
Created By
claude
Raw Data
{
"id": "6eaf87f2-d476-4eb9-93db-7caefcce21b5",
"type": "general",
"status": "completed",
"title": "Adding Directories in Konsole vs Claude CLI",
"description": "Explanation of how directory access works differently in konsole compared to Claude Code CLI",
"context": {
"output": "<div style=\"background:#1e1e1e;color:#e0e0e0;padding:20px;border-radius:8px;font-family:'Segoe UI',sans-serif;\">\n<h2 style=\"color:#fff;margin:0 0 20px 0;\">📁 Adding Directories in Konsole</h2>\n\n<div style=\"background:#f59e0b20;border-left:4px solid #f59e0b;padding:12px 16px;border-radius:0 6px 6px 0;margin-bottom:20px;\">\n<strong style=\"color:#f59e0b;\">Key Difference</strong>\n<div style=\"color:#9ca3af;margin-top:4px;\">Konsole uses a <strong>hardcoded allowed path</strong> approach, not the Claude CLI's <code>/add</code> command.</div>\n</div>\n\n<h3 style=\"color:#3b82f6;margin:20px 0 12px 0;\">Claude Code CLI</h3>\n<div style=\"background:#2d2d2d;padding:16px;border-radius:6px;margin-bottom:16px;\">\n<p style=\"color:#9ca3af;margin:0 0 12px 0;\">In the Claude Code CLI, you can dynamically add directories:</p>\n<pre style=\"margin:0;background:#1e1e1e;padding:12px;border-radius:4px;color:#22c55e;font-family:monospace;\">/add /path/to/directory\n/add ~/projects/myapp</pre>\n<p style=\"color:#7f848e;margin:12px 0 0 0;font-size:0.9rem;\">This adds the directory to Claude's context for the current session.</p>\n</div>\n\n<h3 style=\"color:#ef4444;margin:20px 0 12px 0;\">Konsole (Current Implementation)</h3>\n<div style=\"background:#2d2d2d;padding:16px;border-radius:6px;margin-bottom:16px;\">\n<p style=\"color:#9ca3af;margin:0 0 12px 0;\">Konsole has a <strong>hardcoded allowlist</strong> in <code>konsole/src/tools.ts</code>:</p>\n<pre style=\"margin:0;background:#1e1e1e;padding:12px;border-radius:4px;color:#e5c07b;font-family:monospace;\">const ALLOWED_PATH_PREFIXES = [\n \"/konnectvol/\",\n];</pre>\n<p style=\"color:#7f848e;margin:12px 0 0 0;font-size:0.9rem;\">This means Claude (via konsole) can <strong>only</strong> access files within <code>/konnectvol/</code>.</p>\n</div>\n\n<h3 style=\"color:#8b5cf6;margin:20px 0 12px 0;\">Why This Design?</h3>\n<div style=\"background:#2d2d2d;padding:16px;border-radius:6px;margin-bottom:16px;\">\n<table style=\"width:100%;border-collapse:collapse;font-size:0.9rem;\">\n<tr style=\"border-bottom:1px solid #444;\">\n<td style=\"padding:8px;color:#22c55e;\">✓</td>\n<td style=\"padding:8px;color:#e0e0e0;\"><strong>Security</strong></td>\n<td style=\"padding:8px;color:#9ca3af;\">Prevents Claude from accessing system files, secrets, etc.</td>\n</tr>\n<tr style=\"border-bottom:1px solid #444;\">\n<td style=\"padding:8px;color:#22c55e;\">✓</td>\n<td style=\"padding:8px;color:#e0e0e0;\"><strong>Simplicity</strong></td>\n<td style=\"padding:8px;color:#9ca3af;\">No session-level state to manage for paths</td>\n</tr>\n<tr>\n<td style=\"padding:8px;color:#22c55e;\">✓</td>\n<td style=\"padding:8px;color:#e0e0e0;\"><strong>Server Context</strong></td>\n<td style=\"padding:8px;color:#9ca3af;\">Konsole runs on a server, not your local machine</td>\n</tr>\n</table>\n</div>\n\n<h3 style=\"color:#06b6d4;margin:20px 0 12px 0;\">To Add More Directories</h3>\n<div style=\"background:#2d2d2d;padding:16px;border-radius:6px;margin-bottom:16px;\">\n<p style=\"color:#9ca3af;margin:0 0 12px 0;\">Currently requires editing <code>konsole/src/tools.ts</code>:</p>\n<pre style=\"margin:0;background:#1e1e1e;padding:12px;border-radius:4px;color:#22c55e;font-family:monospace;\">const ALLOWED_PATH_PREFIXES = [\n \"/konnectvol/\",\n \"/home/myuser/projects/\", // Add new paths here\n];</pre>\n<p style=\"color:#7f848e;margin:12px 0 0 0;font-size:0.9rem;\">Then restart konsole for changes to take effect.</p>\n</div>\n\n<h3 style=\"color:#f59e0b;margin:20px 0 12px 0;\">💡 Future Enhancement Idea</h3>\n<div style=\"background:#2d2d2d;padding:16px;border-radius:6px;\">\n<p style=\"color:#9ca3af;margin:0;\">Could add environment variable or config file support:</p>\n<pre style=\"margin:12px 0 0 0;background:#1e1e1e;padding:12px;border-radius:4px;color:#61afef;font-family:monospace;\">KONSOLE_ALLOWED_PATHS=\"/konnectvol/,/home/user/projects/\"</pre>\n<p style=\"color:#7f848e;margin:12px 0 0 0;font-size:0.9rem;\">This would make it configurable without code changes.</p>\n</div>\n</div>",
"requestedAt": "2026-01-07T10:50:00Z",
"requestId": "4ad5bae3-30a8-40de-8349-7a631d7d326c",
"choices": [
{
"label": "Add env var support",
"value": "Implement KONSOLE_ALLOWED_PATHS environment variable support for configurable directory access",
"primary": true
},
{
"label": "Keep as-is",
"value": "The hardcoded approach is fine for now",
"primary": false
}
],
"turnTiming": {
"totalMs": 50509,
"ttfeMs": 50,
"thinkingMs": 50459,
"toolExecutionMs": 0,
"toolCallCount": 0,
"thinkingPct": 100,
"toolsPct": 0,
"ttfePct": 0
}
},
"createdBy": "claude",
"createdAt": "2026-01-07T14:20:51.631Z",
"updatedAt": "2026-01-07T14:20:58.313Z",
"requestId": "4ad5bae3-30a8-40de-8349-7a631d7d326c",
"scope": "vibetools",
"tags": [
"konsole",
"claude",
"configuration"
],
"targetUser": "claude"
}