From e40228cb84677b9391ddd173c9eb04058edff5ae Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 24 Feb 2025 17:51:14 +0530 Subject: [PATCH] Fix regression that broke help formatting --- src/calibre/utils/config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/calibre/utils/config.py b/src/calibre/utils/config.py index 2cd67e7549..58856666c8 100644 --- a/src/calibre/utils/config.py +++ b/src/calibre/utils/config.py @@ -82,8 +82,8 @@ class CustomHelpFormatter(optparse.IndentedHelpFormatter): for line in help_text: help_lines.extend(textwrap.wrap(line, self.help_width)) - result.append(' '*indent_first + f'{help_lines[0]}') - result.extend([' '*self.help_position + f'{line}' for line in help_lines[1:]]) + result.append(' '*indent_first + f'{help_lines[0]}\n') + result.extend(' '*self.help_position + f'{line}\n' for line in help_lines[1:]) elif opts[-1] != '\n': result.append('\n') return ''.join(result)+'\n'