Changed the date used by Jekyll to be the date the post was authored on instead of the date it was created. If the latter is used on an imported post, it gets the import date instead of the date the post was originally written.
This commit is contained in:
parent
adf9ca5a05
commit
f6acbb869e
|
@ -18,7 +18,7 @@ module Jekyll
|
||||||
# This query will pull blog posts from all entries across all blogs. If
|
# This query will pull blog posts from all entries across all blogs. If
|
||||||
# you've got unpublished, deleted or otherwise hidden posts please sift
|
# you've got unpublished, deleted or otherwise hidden posts please sift
|
||||||
# through the created posts to make sure nothing is accidently published.
|
# through the created posts to make sure nothing is accidently published.
|
||||||
QUERY = "SELECT entry_id, entry_basename, entry_text, entry_text_more, entry_created_on, entry_title, entry_convert_breaks FROM mt_entry"
|
QUERY = "SELECT entry_id, entry_basename, entry_text, entry_text_more, entry_authored_on, entry_title, entry_convert_breaks FROM mt_entry"
|
||||||
|
|
||||||
def self.process(dbname, user, pass, host = 'localhost')
|
def self.process(dbname, user, pass, host = 'localhost')
|
||||||
db = Sequel.mysql(dbname, :user => user, :password => pass, :host => host)
|
db = Sequel.mysql(dbname, :user => user, :password => pass, :host => host)
|
||||||
|
@ -28,7 +28,7 @@ module Jekyll
|
||||||
db[QUERY].each do |post|
|
db[QUERY].each do |post|
|
||||||
title = post[:entry_title]
|
title = post[:entry_title]
|
||||||
slug = post[:entry_basename]
|
slug = post[:entry_basename]
|
||||||
date = post[:entry_created_on]
|
date = post[:entry_authored_on]
|
||||||
content = post[:entry_text]
|
content = post[:entry_text]
|
||||||
more_content = post[:entry_text_more]
|
more_content = post[:entry_text_more]
|
||||||
entry_convert_breaks = post[:entry_convert_breaks]
|
entry_convert_breaks = post[:entry_convert_breaks]
|
||||||
|
|
Loading…
Reference in New Issue