Navigation Menu

Skip to content

Commit

Permalink
Support for Catalan reply structure (#76)
Browse files Browse the repository at this point in the history
  • Loading branch information
SL-Gundam committed Apr 16, 2021
1 parent b5d2e29 commit ce2d030
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/EmailReplyParser/Parser/EmailParser.php
Expand Up @@ -34,6 +34,7 @@ class EmailParser
'/^\s*(On(?:(?!^>*\s*On\b|\bwrote:).){0,1000}wrote:)$/ms', // On DATE, NAME <EMAIL> wrote:
'/^\s*(Le(?:(?!^>*\s*Le\b|\bécrit:).){0,1000}écrit(\s|\xc2\xa0):)$/ms', // Le DATE, NAME <EMAIL> a écrit :
'/^\s*(El(?:(?!^>*\s*El\b|\bescribió:).){0,1000}escribió:)$/ms', // El DATE, NAME <EMAIL> escribió:
'/^\s*(El(?:(?!^>*\s*El\b|\bha escrit:).){0,1000}ha escrit:)$/ms', // El DATE, NAME <EMAIL> ha escrit:
'/^\s*(Il(?:(?!^>*\s*Il\b|\bscritto:).){0,1000}scritto:)$/ms', // Il DATE, NAME <EMAIL> ha scritto:
'/^[\S\s]+ (написа(л|ла|в)+)+:$/msu', // Everything before написал: not ending on wrote:
'/^\s*(Op\s.+?(schreef|geschreven).+:)$/ms', // Op DATE schreef NAME <EMAIL>:, Op DATE heeft NAME <EMAIL> het volgende geschreven:
Expand Down
1 change: 1 addition & 0 deletions tests/EmailReplyParser/Tests/Parser/EmailParserTest.php
Expand Up @@ -469,6 +469,7 @@ public function getDateFormats()
array('2014-03-09 20:48 GMT+01:00 Rémi Dolan <do_not_reply@dolan.com>:'), // Gmail
array('Le 19 mars 2014 10:37, Cédric Lombardot <cedric.lombardot@gmail.com> a écrit :'), // Gmail
array('El 19/03/2014 11:34, Juan Pérez <juan.perez@mailcatch.com> escribió:'), // Gmail in spanish
array('El 19/03/2014 11:34, Juan Pérez <juan.perez@mailcatch.com> ha escrit:'), // Gmail in catalan
array('W dniu 7 stycznia 2015 15:24 użytkownik Paweł Brzoski <pbrzoski91@gmail.com> napisał:'), //Gmail in polish
array('Le 19/03/2014 11:34, Georges du chemin a écrit :'), // Thunderbird
array('W dniu 2015-01-07 14:23, pbrzoski91@gmail.com pisze: '), // Thunderbird in polish
Expand Down

0 comments on commit ce2d030

Please sign in to comment.