mirror of
https://github.com/dense-analysis/ale.git
synced 2026-02-24 18:49:27 +08:00
rust-analyzer for non-Cargo projects (#4118)
* rust-analyzer in non-cargo projects rust-analyzer can also be used in non-cargo projects. This requires a rust-project.json file in the project root [1]. Make the rust-analyzer linter search for a rust-project.json file if no Cargo.toml file could be found. [1]: https://rust-analyzer.github.io/manual.html#non-cargo-based-projects * Document rust-analyzer without cargo * Test rust-analyzer with non-cargo projects Change the other rust tests to match the new directory structure of the test files.
This commit is contained in:
@@ -13,9 +13,9 @@ Execute(The options should be configurable):
|
||||
AssertLinter 'rustc', 'rustc --error-format=json --foo -'
|
||||
|
||||
Execute(Some default paths should be included when the project is a Cargo project):
|
||||
call ale#test#SetFilename('../test-files/cargo/test.rs')
|
||||
call ale#test#SetFilename('../test-files/rust/cargo/testfile.rs')
|
||||
|
||||
AssertLinter 'rustc', 'rustc --error-format=json --emit=mir -o /dev/null'
|
||||
\ . ' -L ' . ale#Escape(ale#path#GetAbsPath(g:dir, '../test-files/cargo/target/debug/deps'))
|
||||
\ . ' -L ' . ale#Escape(ale#path#GetAbsPath(g:dir, '../test-files/cargo/target/release/deps'))
|
||||
\ . ' -L ' . ale#Escape(ale#path#GetAbsPath(g:dir, '../test-files/rust/cargo/target/debug/deps'))
|
||||
\ . ' -L ' . ale#Escape(ale#path#GetAbsPath(g:dir, '../test-files/rust/cargo/target/release/deps'))
|
||||
\ . ' -'
|
||||
|
||||
Reference in New Issue
Block a user