Skip to content

Commit 5de579e

Browse files
committed
Fix the changelog message
1 parent d495856 commit 5de579e

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

CHANGELOG.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5318,7 +5318,7 @@ Released 2018-09-13
53185318
[`zero_width_space`]: https://rust-lang.github.io/rust-clippy/master/index.html#zero_width_space
53195319
[`zst_offset`]: https://rust-lang.github.io/rust-clippy/master/index.html#zst_offset
53205320
<!-- end autogenerated links to lint list -->
5321-
<!-- Start configuration's links to the book, DO NOT EDIT MANUALLY -->
5321+
<!-- begin autogenerated links to configuration documentation -->
53225322
[`arithmetic-side-effects-allowed`]: https://doc.rust-lang.org/clippy/lint_configuration.html#arithmetic-side-effects-allowed
53235323
[`arithmetic-side-effects-allowed-binary`]: https://doc.rust-lang.org/clippy/lint_configuration.html#arithmetic-side-effects-allowed-binary
53245324
[`arithmetic-side-effects-allowed-unary`]: https://doc.rust-lang.org/clippy/lint_configuration.html#arithmetic-side-effects-allowed-unary
@@ -5373,3 +5373,5 @@ Released 2018-09-13
53735373
[`future-size-threshold`]: https://doc.rust-lang.org/clippy/lint_configuration.html#future-size-threshold
53745374
[`unnecessary-box-size`]: https://doc.rust-lang.org/clippy/lint_configuration.html#unnecessary-box-size
53755375
[`allow-private-module-inception`]: https://doc.rust-lang.org/clippy/lint_configuration.html#allow-private-module-inception
5376+
<!-- end autogenerated links to configuration documentation -->
5377+

clippy_lints/src/utils/internal_lints/metadata_collector.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -267,15 +267,14 @@ Please use that command to update the file and do not edit it by hand.
267267
let mut changelog = std::fs::read_to_string(CHANGELOG_PATH).unwrap();
268268
let mut changelog_file = OpenOptions::new().read(true).write(true).open(CHANGELOG_PATH).unwrap();
269269

270-
if let Some(position) = changelog.find("<!-- Start configuration's links to the book, DO NOT EDIT MANUALLY -->")
271-
{
270+
if let Some(position) = changelog.find("<!-- begin autogenerated links to configuration documentation -->") {
272271
// I know this is kinda wasteful, we just don't have regex on `clippy_lints` so... this is the best
273272
// we can do AFAIK.
274273
changelog = changelog[..position].to_string();
275274
}
276275
writeln!(
277276
changelog_file,
278-
"{changelog}<!-- Start configuration's links to the book, DO NOT EDIT MANUALLY -->\n{}",
277+
"{changelog}<!-- begin autogenerated links to configuration documentation -->\n{}\n<!-- end autogenerated links to configuration documentation -->\n",
279278
self.configs_to_markdown(ClippyConfiguration::to_markdown_link)
280279
)
281280
.unwrap();

0 commit comments

Comments
 (0)