diff options
| author | 2019-02-09 17:52:51 +0000 | |
|---|---|---|
| committer | 2019-02-09 17:52:51 +0000 | |
| commit | 90618e883b0e65f5ad02598a136685ad79b6754f (patch) | |
| tree | 198c486b82efc528e7a4488da378a77e502f891f | |
| parent | Move StdOut/StdErr specific consts to outs.py (commands) (diff) | |
| signature | ||
Move REGEX_CUTOFF to outs.py (commands)
| -rw-r--r-- | modules/commands/__init__.py | 1 | ||||
| -rw-r--r-- | modules/commands/outs.py | 3 |
2 files changed, 3 insertions, 1 deletions
diff --git a/modules/commands/__init__.py b/modules/commands/__init__.py index 14e26686..7319b2dd 100644 --- a/modules/commands/__init__.py +++ b/modules/commands/__init__.py @@ -5,7 +5,6 @@ from . import outs COMMAND_METHOD = "command-method" COMMAND_METHODS = ["PRIVMSG", "NOTICE"] -REGEX_CUTOFF = re.compile(r"^.{1,%d}(?:\s|$)" % OUT_CUTOFF) REGEX_ARG_NUMBER = re.compile(r"\$(\d+)") def _command_method_validate(s): diff --git a/modules/commands/outs.py b/modules/commands/outs.py index 935721ac..8e90f5e8 100644 --- a/modules/commands/outs.py +++ b/modules/commands/outs.py @@ -1,6 +1,9 @@ +import re from src import utils OUT_CUTOFF = 400 +REGEX_CUTOFF = re.compile(r"^.{1,%d}(?:\s|$)" % OUT_CUTOFF) + STR_MORE = "%s (more...)" % utils.consts.RESET STR_CONTINUED = "(...continued) " |
