Skip to content

Commit dd0301d

Browse files
authored
Merge pull request #20 from agoalofalife/patch-1
Update getting-started.md
2 parents 9d842a7 + 6f67112 commit dd0301d

File tree

1 file changed

+59
-1
lines changed

1 file changed

+59
-1
lines changed

docs/getting-started.md

Lines changed: 59 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,64 @@ curl -sSL https://raw.githubusercontent.com/context-hub/generator/main/download-
5151

5252
<br>
5353

54+
### Installation Location
55+
56+
**macOS:**
57+
58+
When installing ctx on macOS, the binary is installed to `~/.local/bin/ctx` by default. However, this directory may not be in your system's PATH, which can cause issues when using ctx with applications like Claude Desktop.
59+
60+
**Verifying Installation:**
61+
```bash
62+
which ctx
63+
# Should output: /Users/yourusername/.local/bin/ctx
64+
```
65+
66+
**Option 1: Use Full Path (Recommended for MCP)**
67+
68+
When configuring MCP servers in Claude Desktop or similar applications, use the full path to the ctx binary:
69+
```json
70+
{
71+
"mcpServers": {
72+
"ctx": {
73+
"command": "/Users/yourusername/.local/bin/ctx",
74+
"args": ["server", "-c", "/path/to/your/project"]
75+
}
76+
}
77+
}
78+
```
79+
80+
**Option 2: Add to System PATH**
81+
82+
To use `ctx` as a simple command everywhere, create a symlink in a system directory:
83+
```bash
84+
sudo ln -s ~/.local/bin/ctx /usr/local/bin/ctx
85+
```
86+
87+
Or add `~/.local/bin` to your PATH by adding this line to `~/.zshrc` (or `~/.bash_profile` for bash):
88+
```bash
89+
export PATH="$HOME/.local/bin:$PATH"
90+
```
91+
92+
Then reload your shell:
93+
```bash
94+
source ~/.zshrc
95+
```
96+
97+
**Note:** Applications like Claude Desktop may not inherit your shell's PATH. In such cases, using the full path in the configuration is the most reliable approach.
98+
99+
**Linux:**
100+
101+
On Linux, ctx is typically installed to `~/.local/bin/ctx` or `/usr/local/bin/ctx` depending on your installation method. The same PATH considerations apply as with macOS.
102+
103+
**Troubleshooting:**
104+
105+
If you encounter "command not found" errors:
106+
1. Verify ctx is installed: `ls -la ~/.local/bin/ctx`
107+
2. Check the binary is executable: `chmod +x ~/.local/bin/ctx`
108+
3. Use the full path in your configuration
109+
4. For shell usage, ensure `~/.local/bin` is in your PATH
110+
111+
54112
---
55113

56114
<br>
@@ -68,4 +126,4 @@ the [GitHub releases page](https://github.com/context-hub/generator/releases)
68126

69127
## Requirements
70128

71-
- PHP 8.2 or higher
129+
- PHP 8.2 or higher

0 commit comments

Comments
 (0)