#exercise #cargo #language-server #rust-analyzer #root #cargo-toml #fix

app rustlings-fix

Fixes rustlings exercises to work with rust-analyzer language server

3 releases

0.1.2 Mar 1, 2022
0.1.1 Jan 25, 2022
0.1.0 Jan 13, 2022

#1500 in Development tools

Download history 7/week @ 2024-03-11 18/week @ 2024-04-01

51 downloads per month

MIT license

7KB
86 lines

Rustlings Fix

Quickstart

# Install rustlings-fix from cargo
cargo install rustlings-fix

# Change directory into wherever rustlings is cloned
cd ~/src/rustlings

# Run the binary
rustlings-fix

Description

because rustlings is a special type of project where we don't have a cargo.toml linking to each exercise, we need a way to tell rust-analyzer how to parse the exercises. rust-analyzer can use a rust-project.json at the root of the folder you're working from, to work without having a Cargo.toml specifying the binary or library. rustlings-fix generates that file by looping through each exercise to build the configuration in a way that allows rust-analyzer to work with the exercises.

More information

Find more information about how this works here

Dependencies

~0.7–8.5MB
~71K SLoC