From 367437fec595abf06ec254a3e2993a9840d885fe Mon Sep 17 00:00:00 2001 From: Marko Mikulicic Date: Fri, 26 Mar 2010 12:00:47 +0100 Subject: [PATCH] honour -o --- bin/rocco | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/rocco b/bin/rocco index 5f03958..1d0e219 100755 --- a/bin/rocco +++ b/bin/rocco @@ -83,7 +83,7 @@ Dir.mkdir output_dir if !File.directory?(output_dir) # Run each file through Rocco and write output. sources.each do |filename| rocco = Rocco.new(filename, sources, options) - dest = filename.split('.')[0..-2].join('.') + '.html' + dest = File.join(output_dir, filename.split('.')[0..-2].join('.') + '.html') puts "rocco: #{filename} -> #{dest}" File.open(dest, 'wb') { |fd| fd.write(rocco.to_html) } end