Change settings.COMMAND_ARG_REGEX default to require a space or '/' between cmdname and argument. This better matches common expectations. Resolves #1541.

This commit is contained in:
Griatch 2021-10-31 23:08:33 +01:00
parent 36e985557f
commit c2a3c789d3
6 changed files with 35 additions and 12 deletions

View file

@ -476,9 +476,9 @@ CMDSET_FALLBACKS = {
COMMAND_DEFAULT_CLASS = "evennia.commands.default.muxcommand.MuxCommand"
# Command.arg_regex is a regular expression desribing how the arguments
# to the command must be structured for the command to match a given user
# input. By default there is no restriction as long as the input string
# starts with the command name.
COMMAND_DEFAULT_ARG_REGEX = None
# input. By default the command-name should end with a space or / (since the
# default commands uses MuxCommand and /switches).
COMMAND_DEFAULT_ARG_REGEX = r'^[ /]+.*$|$'
# By default, Command.msg will only send data to the Session calling
# the Command in the first place. If set, Command.msg will instead return
# data to all Sessions connected to the Account/Character associated with