File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed
src/tools/generate-copyright/src Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -57,6 +57,10 @@ fn main() -> Result<(), Error> {
57
57
dependencies: collected_cargo_metadata,
58
58
};
59
59
let output = template.render()?;
60
+ // Git stores text files with \n, but this file may contain \r\n in files
61
+ // copied from dependencies. Normalise them before we write them out, for
62
+ // consistency.
63
+ let output = output.replace("\r\n", "\n");
60
64
std::fs::write(&dest_file, output)?;
61
65
62
66
// Output libstd subset file
@@ -65,6 +69,10 @@ fn main() -> Result<(), Error> {
65
69
dependencies: library_collected_cargo_metadata,
66
70
};
67
71
let output = template.render()?;
72
+ // Git stores text files with \n, but this file may contain \r\n in files
73
+ // copied from dependencies. Normalise them before we write them out, for
74
+ // consistency.
75
+ let output = output.replace("\r\n", "\n");
68
76
std::fs::write(&libstd_dest_file, output)?;
69
77
70
78
Ok(())
You can’t perform that action at this time.
0 commit comments