From 8da7fd26162fdeb75e4126dda1c691c9f70683b7 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Fri, 4 Mar 2016 00:30:20 +0530 Subject: [PATCH] Better fix for [options] header in generated manual pages --- manual/cli-options-header.rst | 3 --- manual/custom.py | 2 +- setup/translations.py | 2 +- 3 files changed, 2 insertions(+), 5 deletions(-) delete mode 100644 manual/cli-options-header.rst diff --git a/manual/cli-options-header.rst b/manual/cli-options-header.rst deleted file mode 100644 index 590f5eb0db..0000000000 --- a/manual/cli-options-header.rst +++ /dev/null @@ -1,3 +0,0 @@ -[options] ----------------- - diff --git a/manual/custom.py b/manual/custom.py index 3e3dc67476..e9d10ed09e 100644 --- a/manual/custom.py +++ b/manual/custom.py @@ -177,7 +177,7 @@ def update_cli_doc(name, raw, app): def render_options(cmd, groups, options_header=True, add_program=True, header_level='~'): lines = [''] if options_header: - lines = ['.. include:: /cli-options-header.rst', ''] + lines = [_('[options]'), '-'*40, ''] if add_program: lines += ['.. program:: '+cmd, ''] for title, desc, options in groups: diff --git a/setup/translations.py b/setup/translations.py index b56d6d6a66..6eaeda5da0 100644 --- a/setup/translations.py +++ b/setup/translations.py @@ -46,7 +46,7 @@ class POT(Command): # {{{ self.tx(['push', '-r', 'calibre.'+resource, '-s'], cwd=self.TRANSLATIONS) def source_files(self): - ans = [] + ans = [self.a(self.j(self.d(self.SRC), 'manual', 'custom.py'))] for root, _, files in os.walk(self.j(self.SRC, __appname__)): for name in files: if name.endswith('.py'):