Fixes #5498
Updated data_reader.rb comments to more accurately reflect read() and read_data_to() functionality.
This commit is contained in:
parent
d219b9f6c5
commit
ed9520cd3b
|
@ -7,20 +7,20 @@ module Jekyll
|
||||||
@entry_filter = EntryFilter.new(site)
|
@entry_filter = EntryFilter.new(site)
|
||||||
end
|
end
|
||||||
|
|
||||||
# Read all the files in <source>/<dir>/_drafts and create a new Draft
|
# Read all the files in <dir> and adds them to @content
|
||||||
# object with each one.
|
|
||||||
#
|
#
|
||||||
# dir - The String relative path of the directory to read.
|
# dir - The String relative path of the directory to read.
|
||||||
#
|
#
|
||||||
# Returns nothing.
|
# Returns @content, a Hash of the .yaml, .yml,
|
||||||
|
# .json, and .csv files in the base directory
|
||||||
def read(dir)
|
def read(dir)
|
||||||
base = site.in_source_dir(dir)
|
base = site.in_source_dir(dir)
|
||||||
read_data_to(base, @content)
|
read_data_to(base, @content)
|
||||||
@content
|
@content
|
||||||
end
|
end
|
||||||
|
|
||||||
# Read and parse all yaml files under <dir> and add them to the
|
# Read and parse all .yaml, .yml, .json, and .csv
|
||||||
# <data> variable.
|
# files under <dir> and add them to the <data> variable.
|
||||||
#
|
#
|
||||||
# dir - The string absolute path of the directory to read.
|
# dir - The string absolute path of the directory to read.
|
||||||
# data - The variable to which data will be added.
|
# data - The variable to which data will be added.
|
||||||
|
|
Loading…
Reference in New Issue