Skip to content

source does not recognize specific regex expressions #2775

Answered by ldez
rexagod asked this question in Q&A
Discussion options

You must be logged in to vote

Hello,

line 14: found unknown escape character

the error message is right: in a string, the escape character must be escaped.

source: "^Expected '\\w'.*"

edit:

You also have a problem with your configuration: it is not source but text.

    - linters:
        - gci
      text: "Expected '\\w',.+"

Replies: 3 comments 4 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
3 replies
@rexagod
Comment options

@ldez
Comment options

ldez Apr 19, 2022
Maintainer

@rexagod
Comment options

Answer selected by ldez
Comment options

You must be logged in to vote
1 reply
@ldez
Comment options

ldez Apr 19, 2022
Maintainer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #2774 on April 19, 2022 22:05.