You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In this case the configuration file is not picked up, and I have to symlink it to the root as a workaround or open it separately so that project is the root. I suggest calling rustfmt from the directory of the formatted .rs file instead of the project root.
The text was updated successfully, but these errors were encountered:
Consider a freshly
cargo init
-ed project with an added.rustfmt.toml
. ├── .rustfmt.toml ├── Cargo.toml └── src └── main.rs
In this case the format config is picked up as usual and when formatting
main.rs
is formatted according to the configuration file.Now consider a project where this rust project lives in a subdirectory
. └── project ├── .rustfmt.toml ├── Cargo.toml ├── LICENSE └── src └── main.rs
In this case the configuration file is not picked up, and I have to symlink it to the root as a workaround or open it separately so that
project
is the root. I suggest callingrustfmt
from the directory of the formatted.rs
file instead of the project root.The text was updated successfully, but these errors were encountered: