Regular Expressions 101

Community Patterns

Git merge theirs

0

Regular Expression
PCRE (PHP <7.3)

/
(?<first><<<<<<< HEAD\n.*?)(?<========)|(?<second>(?=>>>>>>>).*?\n)
/
gs

Description

Removes the merge conflict syntax and our content
>>>>>>
our content...
======
their content
<<<<<< commit name
Submitted by anonymous - 4 years ago