diff options
author | Donald Hunter <donald.hunter@gmail.com> | 2024-05-28 15:06:49 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2024-05-29 18:10:25 -0700 |
commit | c697f515b6390b17e4a54a6f93aedf27133929c5 (patch) | |
tree | 9d5ea170ccaee2a21e4d5ed538a66053115b43f3 /tools | |
parent | 1e37449fe3aa32e453eadaaba6e75b66c365efc4 (diff) | |
download | linux-stable-c697f515b6390b17e4a54a6f93aedf27133929c5.tar.gz linux-stable-c697f515b6390b17e4a54a6f93aedf27133929c5.tar.bz2 linux-stable-c697f515b6390b17e4a54a6f93aedf27133929c5.zip |
doc: netlink: Fix generated .rst for multi-line docs
Fix the newline replacement in ynl-gen-rst.py to put spaces between
concatenated lines. This fixes the broken doc string formatting.
See the dpll docs for an example of broken concatenation:
https://docs.kernel.org/6.9/networking/netlink_spec/dpll.html#lock-status
Signed-off-by: Donald Hunter <donald.hunter@gmail.com>
Link: https://lore.kernel.org/r/20240528140652.9445-2-donald.hunter@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/net/ynl/ynl-gen-rst.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/net/ynl/ynl-gen-rst.py b/tools/net/ynl/ynl-gen-rst.py index 657e881d2ea4..5c7465d6befa 100755 --- a/tools/net/ynl/ynl-gen-rst.py +++ b/tools/net/ynl/ynl-gen-rst.py @@ -49,7 +49,7 @@ def inline(text: str) -> str: def sanitize(text: str) -> str: """Remove newlines and multiple spaces""" # This is useful for some fields that are spread across multiple lines - return str(text).replace("\n", "").strip() + return str(text).replace("\n", " ").strip() def rst_fields(key: str, value: str, level: int = 0) -> str: |