From: Jan Nieuwenhuizen Date: Wed, 12 Aug 2009 14:55:36 +0000 (+0200) Subject: WEB: extract_texi_filenames.py: Also look in '.'. Fix error message. X-Git-Tag: release/2.13.4-1~179^2~97 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=7d1ae99102f8563457c5410d941d7edca0192d87;p=lilypond.git WEB: extract_texi_filenames.py: Also look in '.'. Fix error message. --- diff --git a/scripts/build/extract_texi_filenames.py b/scripts/build/extract_texi_filenames.py index f91bae3982..e58b0ddc7b 100644 --- a/scripts/build/extract_texi_filenames.py +++ b/scripts/build/extract_texi_filenames.py @@ -49,7 +49,7 @@ def help (text): outdir = '.' split = "custom" -include_path = [] +include_path = ['.',] master_map_file = '' initial_map = {} for opt in options_list: @@ -87,15 +87,17 @@ section_translation_re = re.compile ('^@(node|(?:unnumbered|appendix)\ external_node_re = re.compile (r'\s+@c\s+external.*') def expand_includes (m, filename): - filepath = os.path.join (os.path.dirname (filename), m.group(1)) + include_name = m.group (1) + filepath = os.path.join (os.path.dirname (filename), include_name) if os.path.exists (filepath): return extract_sections (filepath)[1] else: for directory in include_path: - filepath = os.path.join (directory, m.group(1)) + filepath = os.path.join (directory, include_name) if os.path.exists (filepath): return extract_sections (filepath)[1] - print 'No such file: ' + filepath + print 'No such file: ' + include_name + print 'Search path: ' + ':'.join (include_path) return '' lang_re = re.compile (r'^@documentlanguage (.+)', re.M)