-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Closed
Labels
A-timingsArea: timingsArea: timingsC-feature-requestCategory: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`Command-docS-triageStatus: This issue is waiting on initial triage.Status: This issue is waiting on initial triage.
Description
Problem
In most terminals, if a URL is printed it is turned into a link you can click on for easy opening. This is less true for file paths.
This is less of a problem for cargo doc --open as cargo will open the page up for you.
Places where we are falling short include
cargo doc --target foo --target bar(--opendoesn't work)- Wanting to a
cargo docinvocation that you can run multiple times, using shell history, without editing in/out--open cargo doccalls wrapped in other tools, likemakecargo build --timings(it'd be awkward to add a--openjust for--timings)
Proposed Solution
Turn the file paths into links using ANSI escape codes
Notes
From #12859 (review)
This looks great. Have you consider integrating something like hyperlinks in terminal emulators?
ripgrepjust got a similar feature, though not by using OSC escape sequence:
Metadata
Metadata
Assignees
Labels
A-timingsArea: timingsArea: timingsC-feature-requestCategory: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`Command-docS-triageStatus: This issue is waiting on initial triage.Status: This issue is waiting on initial triage.