Add an option to use relative paths or full paths when building projects #11043
Labels
A-diagnostics
Area: Error and warning messages generated by Cargo itself.
C-feature-request
Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`
Problem
We are using Rust / Cargo to develop a JIT for Ruby called YJIT. YJIT is kind of a sub project of the Ruby programming language. The Ruby programming language is written in C and uses normal C build tools (
autoconf
,make
, etc). YJIT is a subproject, but we've integrated the build in to the normal Ruby compilation process. However, if there is any problem compiling the Rust files, the reported file will be relative to the YJIT directory and not the working directory. This causes a problem with Vim (and apparently other IDEs #8506) because they can't find the file.Here is a screenshot to kind of illustrate the problem:
I would like a command line option to ask
Cargo
to report either full paths, or paths relative to the current working directory.Proposed Solution
I would like a command line option that allows me to see files either as a full path, or as a path relative to the current working directory.
Notes
I found this issue which is similar, and they said it should be a feature request instead of a bug, so I'm filing a feature request.
We have a constraint in the Ruby project that we can't just move the
Cargo.toml
file to the root of the directory. Additionally I spend my time changing the C source code in tandem with Rust source code, so presumably I could keep changing Vim's working directory depending on what I'm editing, but that's kind of onerous.Thanks for your time!!
The text was updated successfully, but these errors were encountered: