Skip to content

Commit ef03e78

Browse files
Merge pull request #11 from crimsonsunset/root-resolution
feat(gateway): exact per-call Cursor workspace routing
2 parents f4cf81c + f1d967f commit ef03e78

88 files changed

Lines changed: 6659 additions & 1286 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

AGENTS.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@ mcp-mux/
1616
├── crates/
1717
│ ├── mcpmux-core/ # Domain entities, repository traits, service layer, EventBus
1818
│ ├── mcpmux-gateway/ # Axum gateway — routing, OAuth refresh, FeatureSet filtering
19-
│ ├── mcpmux-storage/ # SQLite + AES-256-GCM field encryption + OS keychain
20-
│ └── mcpmux-mcp/ # MCP protocol client wrapper (rmcp SDK)
19+
│ └── mcpmux-storage/ # SQLite + AES-256-GCM field encryption + OS keychain
2120
├── packages/ui/ # Shared UI components (`@mcpmux/ui`)
2221
├── schemas/ # JSON Schemas surfaced in the Monaco editor
2322
└── tests/ # Rust integration, TS unit (vitest), desktop E2E (WDIO), web E2E (playwright)

CLAUDE.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,11 @@ pnpm typecheck # TypeScript type checking (recursive)
6666

6767
### Rust Crate Architecture
6868

69-
The Cargo workspace has 4 library crates + 1 app crate + 1 test crate:
69+
The Cargo workspace has 3 library crates + 1 app crate + 1 test crate:
7070

7171
- **mcpmux-core** (`crates/mcpmux-core/`) - Domain layer: entities (Space, InstalledServer, FeatureSet, Client), repository traits, domain services, application services with event emission, and the central EventBus
7272
- **mcpmux-gateway** (`crates/mcpmux-gateway/`) - Axum HTTP gateway: routes MCP calls to correct servers, manages OAuth 2.1+PKCE token refresh, filters tools/resources/prompts based on FeatureSets, per-client access key auth, server connection pooling
7373
- **mcpmux-storage** (`crates/mcpmux-storage/`) - SQLite persistence with AES-256-GCM field-level encryption via ring, typed credential rows (per-token encryption), DPAPI key storage on Windows (`keychain_dpapi.rs`), OS keychain on macOS/Linux via keyring crate, zeroize for secure memory clearing
74-
- **mcpmux-mcp** (`crates/mcpmux-mcp/`) - MCP protocol client management using rmcp SDK
7574
- **apps/desktop/src-tauri** - Tauri 2 app shell, Tauri commands, system tray, deep-link handler (`mcpmux://`)
7675
- **tests/rust** - Integration test crate
7776

Cargo.lock

Lines changed: 144 additions & 31 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ members = [
44
"apps/desktop/src-tauri",
55
"crates/mcpmux-core",
66
"crates/mcpmux-gateway",
7-
"crates/mcpmux-mcp",
87
"crates/mcpmux-storage",
98
"tests/rust",
109
]
@@ -78,7 +77,6 @@ http-body-util = "0.1"
7877
# Internal crates (path-only for workspace)
7978
mcpmux-core = { path = "crates/mcpmux-core" }
8079
mcpmux-gateway = { path = "crates/mcpmux-gateway" }
81-
mcpmux-mcp = { path = "crates/mcpmux-mcp" }
8280
mcpmux-storage = { path = "crates/mcpmux-storage" }
8381

8482
[profile.release]

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -242,8 +242,7 @@ mcp-mux/
242242
├── crates/
243243
│ ├── mcpmux-core/ # Domain logic
244244
│ ├── mcpmux-gateway/ # HTTP gateway, OAuth, routing
245-
│ ├── mcpmux-storage/ # SQLite + encryption + OS keychain
246-
│ └── mcpmux-mcp/ # MCP protocol
245+
│ └── mcpmux-storage/ # SQLite + encryption + OS keychain
247246
├── packages/ui/ # Shared UI components
248247
└── tests/ # Unit, integration, E2E tests
249248
```

THIRD_PARTY_LICENSES

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Generated via `cargo license`
2828
- openssl
2929
- sync_wrapper
3030
- tao
31-
- mcpmux-core, mcpmux-gateway, mcpmux-mcp, mcpmux-storage (internal)
31+
- mcpmux-core, mcpmux-gateway, mcpmux-storage (internal)
3232

3333
### Apache-2.0 OR MIT (Dual Licensed)
3434
- tokio, tokio-macros, tokio-util (async runtime)
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
//! Tauri IPC wrappers for the managed Cursor `preToolUse` hook installer.
2+
3+
use mcpmux_gateway::cursor_hook::{self, CursorHookResult};
4+
5+
/// Current install state of the managed Cursor hook.
6+
#[tauri::command]
7+
pub fn cursor_hook_status() -> CursorHookResult {
8+
cursor_hook::status()
9+
}
10+
11+
/// Install or update the managed `preToolUse` hook.
12+
#[tauri::command]
13+
pub fn install_cursor_hook() -> CursorHookResult {
14+
cursor_hook::install()
15+
}
16+
17+
/// Remove the managed hook entry and delete the managed script.
18+
#[tauri::command]
19+
pub fn uninstall_cursor_hook() -> CursorHookResult {
20+
cursor_hook::uninstall()
21+
}

apps/desktop/src-tauri/src/commands/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ pub mod client;
88
pub mod client_install;
99
pub mod config_export;
1010
pub mod credential;
11+
pub mod cursor_hook_install;
1112
pub mod feature_members;
1213
pub mod feature_set;
1314
pub mod gateway;
@@ -31,6 +32,7 @@ pub use builtin_servers::*;
3132
pub use client::*;
3233
pub use client_install::*;
3334
pub use config_export::*;
35+
pub use cursor_hook_install::*;
3436
pub use feature_members::*;
3537
pub use feature_set::*;
3638
pub use gateway::*;

0 commit comments

Comments
 (0)