Skip to content

Commit

Permalink
fix color config bug
Browse files Browse the repository at this point in the history
  • Loading branch information
SilenZcience committed Nov 16, 2024
1 parent 20029cb commit f42c197
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions cat_win/src/const/regex.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,10 @@
RE_F_IND = re.compile(r"\Af[\=\:].*\Z", re.IGNORECASE)
RE_Q_REPLACE = re.compile(r"\Areplace[\=\:].*\Z", re.IGNORECASE)
RE_R_EPLACE = re.compile(r"\Ar[\=\:].*\Z", re.IGNORECASE)
RE_TRUNC = re.compile(r"\Atrunc[\=\:][0-9\(\)\+\-\*\/]*"
RE_Q_TRUNC = re.compile(r"\Atrunc[\=\:][0-9\(\)\+\-\*\/]*"
r"\:[0-9\(\)\+\-\*\/]*\:?"
r"[0-9\(\)\+\-\*\/]*\Z",re.IGNORECASE)
RE_T_RUNC = re.compile(r"\At[\=\:][0-9\(\)\+\-\*\/]*"
r"\:[0-9\(\)\+\-\*\/]*\:?"
r"[0-9\(\)\+\-\*\/]*\Z",re.IGNORECASE)
RE_CUT = re.compile(r"\A\[[0-9\(\)\+\-\*\/]*\:"
Expand All @@ -43,7 +46,7 @@
r"(?:(?:\;(?:[0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])){2})?\Z",
re.IGNORECASE
)
CONFIG_VALID_ANSI = re.compile(r"\[(?:\d|;)*m") # custom ansi escape code
CONFIG_VALID_ANSI = re.compile(r"\A\[(?:\d|;)*m\Z") # custom ansi escape code

# matches a mathematical expression consisting of
# either hex-numbers = (0x...), octal-numbers (0o...),
Expand Down

0 comments on commit f42c197

Please sign in to comment.