Skip to content

Commit

Permalink
Merge pull request #189 from mull-project/strip-only-newlines
Browse files Browse the repository at this point in the history
 Initially strip only newlines from matched lines
  • Loading branch information
stanislaw authored Feb 16, 2022
2 parents 01cc887 + 5fb3a7a commit a4b4468
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 0.0.21
current_version = 0.0.22
commit = True
tag = True

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci-mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:

strategy:
matrix:
python-version: [3.6, 3.7, 3.8, 3.9]
python-version: [3.7, 3.8, 3.9]

steps:
- uses: actions/checkout@v2
Expand Down
4 changes: 2 additions & 2 deletions filecheck/filecheck.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from difflib import SequenceMatcher
from enum import Enum

__version__ = "0.0.21"
__version__ = "0.0.22"

from typing import Optional, List, Iterable

Expand Down Expand Up @@ -597,7 +597,7 @@ def exit_handler(code):
failed_implicit_check = None

while True:
line = line.rstrip()
line = line.rstrip("\n\r")

unstripped_line = line

Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "filecheck"
version = "0.0.21"
version = "0.0.22"
description = "Python port of LLVM's FileCheck, flexible pattern matching file verifier"
authors = ["Stanislav Pankevich <s.pankevich@gmail.com>"]

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
CHECK: {{^}}hello {{$}}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
hello
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
RUN: %cat "%S/filecheck.input" | %expect_exit 0 --expect-no-content %FILECHECK_EXEC "%S/filecheck.check"
2 changes: 1 addition & 1 deletion tests/integration/tests/py-only/version/sample.itest
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
RUN: %FILECHECK_EXEC --version | %FILECHECK_TESTER_EXEC %s --match-full-lines
CHECK: {{^.*}}FileCheck{{(\.py)?$}}
CHECK: Version: 0.0.21
CHECK: Version: 0.0.22
CHECK-EMPTY:

0 comments on commit a4b4468

Please sign in to comment.