From c46bf5ed25f6be0733473ebe7af88396fee0cb3a Mon Sep 17 00:00:00 2001 From: "Andrei G." Date: Tue, 3 Feb 2026 16:08:52 +0100 Subject: [PATCH] feat: add Ruby language support Add Ruby/Gemfile support to the extension by registering Ruby language with deps-lsp. Update documentation with Ruby-specific instructions. --- README.md | 40 ++++++++++++++++++++++++++++++++++------ extension.toml | 12 +++++++++--- 2 files changed, 43 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 46183d6..61f3975 100644 --- a/README.md +++ b/README.md @@ -2,14 +2,14 @@ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](../../LICENSE) -Zed extension for intelligent dependency management in `Cargo.toml`, `package.json`, and more. +Zed extension for [deps-lsp](https://github.com/bug-ops/deps-lsp) — intelligent dependency management in `Cargo.toml`, `package.json`, `Gemfile`, and more. ![Deps extension in action](assets/img.png) ## Features - **Version Hints** — Inline status indicators (✅ up-to-date, ❌ outdated) -- **Lock File Support** — Resolved versions from Cargo.lock, package-lock.json, poetry.lock, uv.lock +- **Lock File Support** — Resolved versions from Cargo.lock, package-lock.json, Gemfile.lock, etc. - **Hover Information** — Version list with resolved version from lock file - **Diagnostics** — Warnings for outdated, yanked, or unknown packages - **Code Actions** — Quick version updates via `Cmd+.` @@ -55,17 +55,45 @@ Configure in Zed settings (`Cmd+,`): | Rust | `Cargo.toml` | `Cargo.lock` | | npm | `package.json` | `package-lock.json` | | Python | `pyproject.toml` | `poetry.lock`, `uv.lock` | +| Go | `go.mod` | `go.sum` | +| Ruby | `Gemfile` | `Gemfile.lock` | ## Development -> [!NOTE] -> This crate compiles to WASM and is distributed via Zed Extensions marketplace. +### Prerequisites + +Install Rust via [rustup](https://rustup.rs/) and add the WASM target: ```bash -# Build WASM extension -cargo build -p deps-zed --target wasm32-wasip1 +rustup target add wasm32-wasip1 ``` +### Build WASM Extension + +```bash +cd crates/deps-zed +cargo build --release --target wasm32-wasip1 +``` + +### Install as Dev Extension + +1. Build the extension (see above) +2. Open Zed +3. Run command: `zed: install dev extension` +4. Select the `crates/deps-zed` directory + +The extension will load from your local build. To see logs, run Zed from terminal: + +```bash +zed --foreground +``` + +### Testing with Gemfile + +1. Install the [Ruby extension](https://zed.dev/extensions/ruby) in Zed +2. Open a project with `Gemfile` and `Gemfile.lock` +3. Verify inlay hints and hover information appear + ## License [MIT](../../LICENSE) diff --git a/extension.toml b/extension.toml index 4a8ec29..fdb5b8d 100644 --- a/extension.toml +++ b/extension.toml @@ -1,11 +1,17 @@ id = "deps" name = "Deps" -description = "Dependency management LSP with lock file support for Cargo.toml, package.json, pyproject.toml" -version = "0.1.0" +description = "Intelligent dependency insights across package ecosystems" +version = "0.1.1" schema_version = 1 authors = ["Andrei G"] repository = "https://github.com/bug-ops/deps-lsp" [language_servers.deps-lsp] name = "Deps LSP" -languages = ["TOML", "JSON"] +languages = ["TOML", "JSON", "Go Mod", "Ruby"] + +[language_servers.deps-lsp.language_ids] +"TOML" = "toml" +"JSON" = "json" +"Go Mod" = "gomod" +"Ruby" = "ruby"