Debug reading data files in a site (#8481)

Merge pull request 8481
This commit is contained in:
Ashwin Maroli 2020-11-26 23:51:50 +05:30 committed by GitHub
parent d8d1feec71
commit 58368cdacc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -8,6 +8,7 @@ module Jekyll
@site = site
@content = {}
@entry_filter = EntryFilter.new(site)
@source_dir = site.in_source_dir("/")
end
# Read all the files in <dir> and adds them to @content
@ -53,6 +54,8 @@ module Jekyll
#
# Returns the contents of the data file.
def read_data_file(path)
Jekyll.logger.debug "Reading:", path.sub(@source_dir, "")
case File.extname(path).downcase
when ".csv"
CSV.read(path,