Skip to content

Commit 427cd67

Browse files
committed
Implement two patterns us --> uk
The second set added is parallel to the immediately above but is missing the 'd' on purpose (otherwise a wide number of words that shouldn't match do - e.g. 'ambassador'). Causes misses on some words (e.g. 'odor').
1 parent f7ab7c4 commit 427cd67

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

src/pattern.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,13 +113,27 @@ const patterns:ReplacementPattern[] = [
113113
replacementString:"eled"
114114
},
115115

116+
{
117+
regex:/eled$/,
118+
originalIndex:[4],
119+
replacementIndex:[0,5],
120+
replacementString:"elled"
121+
},
122+
116123
{
117124
regex:/([cpviglnbmd])(our)(ed$|ing$|s$|al$|ally$|ful$|$)/,
118125
originalIndex:[0],
119126
replacementIndex:[4],
120127
replacementString:"$1or$3"
121128
},
122129

130+
{
131+
regex:/([cpviglnbm])(or)(ed$|ing$|s$|al$|ally$|ful$|$)/,
132+
originalIndex:[4],
133+
replacementIndex:[0],
134+
replacementString:"$1our$3"
135+
},
136+
123137
{
124138
regex:/(v|m|b|l|d|i|n|c|g|p)our/,
125139
originalIndex:[0,5],

0 commit comments

Comments
 (0)