-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from zschreur/zschreur/push-vmkqntnllvwo
Fix conflicts so that it works when there are less than 3 spaces
- Loading branch information
Showing
2 changed files
with
13 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
local s1 = "file two-sided conflict" | ||
local s2 = "file two-sided conflict" | ||
local s3 = "file two-sided conflict" | ||
local s4 = "file three-sided conflict" | ||
local s5 = "file two-sided conflict two-sided conflict" | ||
|
||
local pattern = "^(.-)%s+%a+%-sided conflict$" | ||
assert(string.match(s1, pattern) == "file") | ||
assert(string.match(s2, pattern) == "file") | ||
assert(string.match(s3, pattern) == "file") | ||
assert(string.match(s4, pattern) == "file") | ||
assert(string.match(s5, pattern) == "file two-sided conflict") |