Add Windows installation steps

This commit is contained in:
Justin Spahr-Summers 2024-11-21 12:52:38 +00:00
commit d51617a40a
No known key found for this signature in database

View file

@ -76,8 +76,8 @@ This gives you a secure way to let Claude analyze and interact with your local d
## Prerequisites ## Prerequisites
- macOS (Windows/Linux guides coming soon) - macOS or Windows
- [Claude Desktop](https://claude.ai/download) v0.7.0 or newer installed (Claude > About Claude to check) - The latest version of [Claude Desktop](https://claude.ai/download) installed
- Node.js v18 or higher (`node --version` to check) - Node.js v18 or higher (`node --version` to check)
- Git (`git --version` to check) - Git (`git --version` to check)
- SQLite (`sqlite3 --version` to check) - SQLite (`sqlite3 --version` to check)
@ -96,67 +96,136 @@ brew install node git sqlite3
## Installation ## Installation
<Steps> <Tabs>
<Step title="Install example servers"> <Tab title="macOS">
Let's start by getting the pre-built MCP servers: <Steps>
<Step title="Install example servers">
Let's start by getting the pre-built MCP servers:
```bash ```bash
npm install -g @modelcontextprotocol/servers npm install -g @modelcontextprotocol/servers
``` ```
This makes the MCP servers available as command-line tools that Claude Desktop can launch. This makes the MCP servers available as command-line tools that Claude Desktop can launch.
</Step> </Step>
<Step title="Create a sample database"> <Step title="Create a sample database">
Let's create a simple SQLite database for testing: Let's create a simple SQLite database for testing:
```bash ```bash
# Create a new SQLite database # Create a new SQLite database
sqlite3 ~/test.db <<EOF sqlite3 ~/test.db <<EOF
CREATE TABLE products ( CREATE TABLE products (
id INTEGER PRIMARY KEY, id INTEGER PRIMARY KEY,
name TEXT, name TEXT,
price REAL price REAL
); );
INSERT INTO products (name, price) VALUES INSERT INTO products (name, price) VALUES
('Widget', 19.99), ('Widget', 19.99),
('Gadget', 29.99), ('Gadget', 29.99),
('Gizmo', 39.99); ('Gizmo', 39.99);
EOF EOF
``` ```
</Step> </Step>
<Step title="Configure Claude Desktop"> <Step title="Configure Claude Desktop">
Open your Claude Desktop App configuration at `~/Library/Application Support/Claude/claude_desktop_config.json` in a text editor. Open your Claude Desktop App configuration at `~/Library/Application Support/Claude/claude_desktop_config.json` in a text editor.
For example, if you have [VS Code](https://code.visualstudio.com/) installed: For example, if you have [VS Code](https://code.visualstudio.com/) installed:
```bash ```bash
code ~/Library/Application\ Support/Claude/claude_desktop_config.json code ~/Library/Application\ Support/Claude/claude_desktop_config.json
``` ```
Add this configuration (replace YOUR_USERNAME with your actual username): Add this configuration (replace YOUR_USERNAME with your actual username):
```json ```json
{ {
"mcpServers": { "mcpServers": {
"sqlite": { "sqlite": {
"command": "mcp-server-sqlite", "command": "mcp-server-sqlite",
"args": ["/Users/YOUR_USERNAME/test.db"] "args": ["/Users/YOUR_USERNAME/test.db"]
}
}
} }
} ```
}
```
This tells Claude Desktop: This tells Claude Desktop:
1. There's an MCP server named "sqlite" 1. There's an MCP server named "sqlite"
2. Launch it using the `mcp-server-sqlite` command 2. Launch it using the `mcp-server-sqlite` command
3. Connect it to your test database 3. Connect it to your test database
Save the file, and restart **Claude Desktop**. Save the file, and restart **Claude Desktop**.
</Step> </Step>
</Steps> </Steps>
</Tab>
<Tab title="Windows">
<Steps>
<Step title="Install example servers">
Let's start by getting the pre-built MCP servers:
```bash
npm install -g @modelcontextprotocol/servers
```
This makes the MCP servers available as command-line tools that Claude Desktop can launch.
</Step>
<Step title="Create a sample database">
Let's create a simple SQLite database for testing:
```powershell
# Create a new SQLite database
$sql = @'
CREATE TABLE products (
id INTEGER PRIMARY KEY,
name TEXT,
price REAL
);
INSERT INTO products (name, price) VALUES
('Widget', 19.99),
('Gadget', 29.99),
('Gizmo', 39.99);
'@
& sqlite3 test.db $sql
```
</Step>
<Step title="Configure Claude Desktop">
Open your Claude Desktop App configuration at `%APPDATA%\Claude\claude_desktop_config.json` in a text editor.
For example, if you have [VS Code](https://code.visualstudio.com/) installed:
```bash
$env:AppData\Claude\claude_desktop_config.json
```
Add this configuration (replace YOUR_USERNAME with your actual username):
```json
{
"mcpServers": {
"sqlite": {
"command": "mcp-server-sqlite",
"args": ["/Users/YOUR_USERNAME/test.db"]
}
}
}
```
This tells Claude Desktop:
1. There's an MCP server named "sqlite"
2. Launch it using the `mcp-server-sqlite` command
3. Connect it to your test database
Save the file, and restart **Claude Desktop**.
</Step>
</Steps>
</Tab>
</Tabs>
## Test it out ## Test it out