Skip to content

Commit e5d6a27

Browse files
davidsmfreireclaude
andcommitted
feat(zed): add Zed extension wrapping sqlshield-lsp
A native Zed extension under editors/zed/. Compiles to wasm32-wasip1 via zed_extension_api 0.7.0 and registers a `sqlshield` language server attached to SQL, Python, Rust, Go, JS/JSX, and TS/TSX buffers. Binary discovery is layered: explicit `lsp.sqlshield.binary.path` → `sqlshield-lsp` on PATH (the cargo install path) → a GitHub-release download keyed by `(platform, arch)`. The release-download path is guarded by an `sqlshield-lsp-v*` tag check so it won't grab assets from a sibling crate's tag. Workspace-configuration hook forwards `lsp.sqlshield.settings` to the LSP unchanged, so the same `schema` / `dialect` knobs that already work in VS Code work here too — server-side merging with .sqlshield.toml is unchanged. The crate is excluded from the main Cargo workspace because it targets wasm32-wasip1 and pulls in zed_extension_api, which would otherwise interfere with native cargo build/test/clippy. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 72bab80 commit e5d6a27

7 files changed

Lines changed: 1098 additions & 0 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
.venv
22
/target
3+
**/target/
34
.vscode
45

56
# Python

Cargo.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ members = [
77
"sqlshield-lsp",
88
"sqlshield-py",
99
]
10+
# editors/zed targets wasm32-wasip1 and uses zed_extension_api; keep
11+
# it out of the main workspace so it doesn't interfere with normal
12+
# cargo build/test/clippy commands.
13+
exclude = ["editors/zed"]
1014
# Root `sqlshield-precommit` package is a pre-commit shim; exclude from
1115
# default builds so it doesn't clobber sqlshield-cli's `sqlshield` bin.
1216
default-members = [

0 commit comments

Comments
 (0)