Skip to content

Commit 979256b

Browse files
committed
update date formats, add support for EU, USA locale.
1 parent 637003a commit 979256b

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

pydateparser/date_formats.py

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
class DateFormats:
2+
locale = {'USA':[
3+
'%b %d %Y',
4+
'%b %-d %Y',
5+
'%b %d, %Y',
6+
'%b %-d, %Y',
7+
'%B %d, %Y',
8+
'%B %-d, %Y',
9+
'%B %d %Y',
10+
'%B %-d %Y',
11+
'%m/%d/%Y',
12+
'%m/%-d/%Y',
13+
'%m/%d/%y',
14+
'%m/%-d/%y'
15+
],
16+
'EU':[
17+
'%b %d %Y',
18+
'%b %-d %Y',
19+
'%b %d, %Y',
20+
'%b %-d, %Y',
21+
'%B %d, %Y',
22+
'%B %-d, %Y',
23+
'%B %d %Y',
24+
'%B %-d %Y',
25+
'%d/%m/%Y',
26+
'%-d/%m/%Y',
27+
'%d/%m/%y',
28+
'%-d/%m/%y'
29+
]}

0 commit comments

Comments
 (0)