lib/softcover/builders/pdf.rb in softcover-1.0.5 vs lib/softcover/builders/pdf.rb in softcover-1.1.beta1

- old
+ new

@@ -39,11 +39,11 @@ end end File.write(Softcover::Utils.tmpify(manifest, filename), latex) end write_pygments_file(:latex, Softcover::Directories::STYLES) - copy_polytexnic_sty + copy_polytexnic_sty(options) # Renaming the PDF in the command is necessary because `execute` # below uses `exec` (except in tests, where it breaks). Since `exec` # causes the Ruby process to end, any Ruby code after `exec` # is ignored. @@ -146,14 +146,14 @@ def keep_tmp_files?(options) options[:once] || options[:'find-overfull'] || Softcover.test? end # Copies the style file to ensure it's always fresh. - def copy_polytexnic_sty + def copy_polytexnic_sty(options) softcover_sty = File.join(Softcover::Directories::STYLES, 'softcover.sty') - source_sty = File.join(File.dirname(__FILE__), - '..', 'template', softcover_sty) + source_sty = File.join(Softcover::Utils.template_dir(options), + softcover_sty) FileUtils.cp source_sty, softcover_sty end end end end