Navigation Menu

Skip to content

Commit

Permalink
catalog-generate: ensure output directory existence
Browse files Browse the repository at this point in the history
  • Loading branch information
kou committed Jun 25, 2014
1 parent d0d73d2 commit 224b6a7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions bin/droonga-engine-catalog-generate
Expand Up @@ -101,6 +101,7 @@ def open_output(path)
else
# Don't output the file directly to prevent loading of incomplete file!
path = Pathname(path).expand_path
FileUtils.mkdir_p(path.dirname.to_s)
Tempfile.open(path.basename.to_s, path.dirname.to_s, "w") do |output|
yield(output)
output.flush
Expand Down

0 comments on commit 224b6a7

Please sign in to comment.