Skip to content

feat(lsp): support an opt-in rust-glancer configuration - #364

Merged
fcoury merged 2 commits into
mainfrom
feat/rust-glancer
Sep 19, 2026
Merged

fcoury merged 2 commits into
mainfrom
feat/rust-glancer

Conversation

@fcoury

@fcoury fcoury commented Sep 19, 2026

Copy link
Copy Markdown
Contributor

Red applies rust-analyzer-specific startup and workspace settings to any server using the Rust language ID. That leaks rust-analyzer options into alternative servers such as Rust Glancer.

Scope those automatic settings to recognized rust-analyzer commands, preserving direct paths and rustup run launches. Add a complete opt-in Rust Glancer configuration plus installation, diagnostics, and switch-back instructions. Rust-analyzer remains the default, and the existing Cargo-workspace routing is reused.

How to Test

  1. Install Rust Glancer v0.2.0 and rust-src. Replace the Rust server section of a test Red user config with examples/rust-glancer.toml, then run red --check-config.
  2. Open a Rust project. Check hover (K), definition (gd), completion, and formatting (Space then f). Introduce a type error and save: diagnostics should appear; fixing and saving should clear them.
  3. Open files from two members of a Cargo workspace. They should share the workspace server. Remove the Glancer section and run :languages reload: Glancer should stop and rust-analyzer should provide hover again.

Validated with the worktree-built Red in tmux: standalone-crate hover, navigation, completion insertion, formatting, diagnostic appearance/clearing, warm restart, Red workspace cross-crate navigation, and switching back to rust-analyzer. Unit coverage reproduces the previous settings leak and checks the documented config and rust-analyzer launch forms. The real rust-analyzer workspace-formatting test also passes.

Local checks: 142 focused LSP tests; 3,658 tests passed with RUST_TEST_THREADS=4 cargo test --all-targets --all-features (3 ignored); Clippy with all targets/features and -D warnings; rustfmt; runtime self-check. At default test concurrency, git_dashboard_renders_numstat_for_a_large_tracked_file_list hit its 10-second timeout twice; its isolated rerun passed. That unrelated test was not modified.

@fcoury

fcoury commented Sep 19, 2026

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 19, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-19T16:04:22.886449Z 674f81e Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 674f81e5a0

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/lsp/workspace_settings.rs Resolved
@fcoury
fcoury merged commit 3fc3548 into main Sep 19, 2026
13 checks passed
@fcoury
fcoury deleted the feat/rust-glancer branch September 19, 2026 16:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant