lib/take/unit.rb in take-0.0.5 vs lib/take/unit.rb in take-0.0.6

- old
+ new

@@ -11,10 +11,12 @@ def self.create(file) file = File.open(file, "r") scanner = Scanner.new(file.read) compiler = Compiler.new(file.path, scanner.scan) - generator = Generator.new(compiler.compile, {}).generate + generator = Generator.new(compiler.compile, + directory: File.dirname(file.path)).tap(&:generate) + generator.write_file end end end