diff options
author | Mauro Carvalho Chehab <mchehab+huawei@kernel.org> | 2025-02-24 10:08:11 +0100 |
---|---|---|
committer | Jonathan Corbet <corbet@lwn.net> | 2025-03-04 09:47:40 -0700 |
commit | b9609ecba35ecf7fa85d9bcd519242009174e6a2 (patch) | |
tree | c86b3c00d255938f432ab1aa6d79c03d73e1894f /scripts | |
parent | 99326b2155d8e37346d4bd1c5ebea7012cc63200 (diff) |
scripts/kernel-doc: don't add not needed new lines
This helps comparing kernel-doc output with the new .py version
of it.
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Link: https://lore.kernel.org/r/6b036ef7d746f26d7d0044626b04d1f0880a2188.1740387599.git.mchehab+huawei@kernel.org
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/kernel-doc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/kernel-doc b/scripts/kernel-doc index 2c77b914d017..d59552e1a31d 100755 --- a/scripts/kernel-doc +++ b/scripts/kernel-doc @@ -760,6 +760,10 @@ sub output_highlight_rst { if ($block) { $output .= highlight_block($block); } + + $output =~ s/^\n+//g; + $output =~ s/\n+$//g; + foreach $line (split "\n", $output) { print $lineprefix . $line . "\n"; } |