diff --git a/lib/review/pdfmaker.rb b/lib/review/pdfmaker.rb index a9b50f925..71b8c8fde 100644 --- a/lib/review/pdfmaker.rb +++ b/lib/review/pdfmaker.rb @@ -164,6 +164,7 @@ def make_input_files(book, yamlfile) input_files = Hash.new { |h, key| h[key] = '' } book.parts.each do |part| if part.name.present? + @config['use_part'] = true if part.file? output_chaps(part.name, yamlfile) input_files['CHAPS'] << %Q(\\input{#{part.name}.tex}\n) diff --git a/templates/latex/config.erb b/templates/latex/config.erb index 9b02b02c3..fa750ec66 100644 --- a/templates/latex/config.erb +++ b/templates/latex/config.erb @@ -94,5 +94,8 @@ \def\reviewchapterfiles{<%= @input_files['CHAPS'] %>} \def\reviewappendixfiles{<%= @input_files['APPENDIX'] %>} \def\reviewpostdeffiles{<%= @input_files['POSTDEF'] %>} +<%- if @config['use_part'] -%> +\def\reviewusepart{true} +<%- end -%> \makeatother