-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Open
Labels
A-build-scriptsArea: build.rs scriptsArea: build.rs scriptsA-diagnosticsArea: Error and warning messages generated by Cargo itself.Area: Error and warning messages generated by Cargo itself.C-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`S-needs-designStatus: Needs someone to work further on the design for the feature or fix. NOT YET accepted.Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted.
Description
Problem
I was giving a workshop to people new to rust and in one of the exercises they were instructed to create a build.rs
file.
However, this person either didn't read this correctly or typo-ed and created builds.rs
.
Obviously, (or rather very unobviously) this won't work and it took me and her about 5 minutes to figure out.
Proposed Solution
Cargo could try to see if there's no current build.rs
yet and then if there's a file that's a likely misspelling of the name. If it finds that's the case it could output a warning with a suggestion to rename the file.
Notes
There could be false positives with this in theory. But that would be a pretty strange project layout, so I feel that would almost never happen.
Metadata
Metadata
Assignees
Labels
A-build-scriptsArea: build.rs scriptsArea: build.rs scriptsA-diagnosticsArea: Error and warning messages generated by Cargo itself.Area: Error and warning messages generated by Cargo itself.C-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`S-needs-designStatus: Needs someone to work further on the design for the feature or fix. NOT YET accepted.Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted.