Sha256: eb16b71f156d6ea7bfbbafb276380df288ad9af51d6e15fc3afec8aa9fa2580e
Contents?: true
Size: 378 Bytes
Versions: 2
Compression:
Stored size: 378 Bytes
Contents
module Contentful module Exporter module Database module Utils def write_json_to_file(path, data) File.open(path, 'w') do |file| file.write(JSON.pretty_generate(data)) end end def create_directory(path) FileUtils.mkdir_p(path) unless File.directory?(path) end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
database-exporter-0.0.2 | lib/database/modules/utils.rb |
database-exporter-0.0.1 | lib/database/modules/utils.rb |