mirror of
https://github.com/zed-industries/zed.git
synced 2026-11-19 15:10:34 +01:00
8385157b2f
# Objective using `editor: open docs` never chose the local file even when it existed, found it was because this was slicing off the leading `/` which gave an invalid path ## Solution slice the URI correctly to preserve the path ## Testing tested by using `editor: open docs` in my project before and after running `cargo doc`, before it went to doc.rs, after it opened the local docs file ## Self-Review Checklist: - [x] I've reviewed my own diff for quality, security, and reliability - [x] Unsafe blocks (if any) have justifying comments - [x] The content adheres to Zed's UI standards ([UX/UI](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist) and [icon](https://github.com/zed-industries/zed/blob/main/crates/icons/README.md) guidelines) - [x] Tests cover the new/changed behavior - [x] Performance impact has been considered and is acceptable --- Release Notes: - fixed opening local documentation when using `editor: open docs` --------- Co-authored-by: Kirill Bulatov <kirill@zed.dev>