Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lib/pismo/internal_attributes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ module InternalAttributes

MONTHS_REGEX = %r{(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec|January|February|March|April|May|June|July|August|September|October|November|December)\.?}i
DATETIME_REGEXEN = [
/#{MONTHS_REGEX}\b\.\s+\d{2}\,\s+\d{4}\s+\d{2}\:\d{2}\s+(a|p)\.m\./i, #Jul. 25, 2012 10:46 a.m.
/#{MONTHS_REGEX}\b\s+\d+\D{1,10}\d{4}/i,
/(on\s+)?\d+\s+#{MONTHS_REGEX}\s+\D{0,10}\d+/i,
/(on[^\d+]{1,10})\d+(th|st|rd)?.{1,10}#{MONTHS_REGEX}\b[^\d]{1,10}\d+/i,
Expand Down
2 changes: 1 addition & 1 deletion test/corpus/metadata_expected.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -87,5 +87,5 @@
:datetime: 2010-02-17 12:00:00 +00:00
:thegoodbookblog:
:title: Signs Of Life
:datetime: 2012-07-25 12:00:00 +00:00
:datetime: 2012-07-25 10:46:00 +00:00
:tags: [Church Life, Marriage and Family, Ministry and Leadership]