Skip to content

Draft: Add single quotes and quote escaping to command parser

Hanicef requested to merge Hanicef/SRB2:misc-console-features into next

this patch adds two convenience features to the command parser:

  • parameters can be wrapped in single quotes
  • quotes can be escaped with backslash

these two features solves a minor issue with command parameters where double quotes can't easily be escaped. with this patch, you now have two options: either wrap it in single quotes (say 'i can say "quotes" here'), or escape it with a backslash (say "i can say \"quotes\" here")

EDIT: single quotes was removed due to concerns of breaking changes (thanks @Zwip-Zwap_Zapony for pointing that out).

Edited by Hanicef

Merge request reports