Skip to main content

Syntax and separators

Naming rules, the definition separator, and how argument declarations are parsed.
Every ;cc set looks like this:

Command names

  • Allowed characters: lowercase letters, digits, _, and - (regex ^[a-z0-9_-]{1,32}$).
  • Length: 1–32 characters.
  • Collisions: the name cannot match any built-in raze command, nor the reserved names cc, customcommand, or customcommands.
Names are lowercased automatically, so ;cc set Greet ... saves as greet.

Separators

The separator marks where the declaration ends and the response begins. Any one of these works: Only the first standalone occurrence counts. Later occurrences are ordinary text in your response, so an arrow inside the response is safe:
The separator must stand alone, surrounded by whitespace or at the start/end of the input. ;cc set ping--Pong! is rejected with a missing-separator error.

Argument declarations

Declarations go between the name and the separator. There are three kinds.
Declared as (name). Captures exactly one word. If the invoker leaves it out, the command replies with a missing-argument error and stops.
@you hugs @wanderer!
Declared as [name]. Captures one word if present, otherwise resolves to an empty string. Pair it with a fallback so it never renders blank.
Hello stranger!
Declared as (name...) or [name...]. Captures everything remaining on the line, spaces included. A rest argument must be the last declaration.
hello everyone, welcome back
Angle brackets are accepted as a legacy alias for required arguments — <member> behaves exactly like (member), and <message...> like (message...). New commands should use parentheses; brackets must match, so (member> is rejected.
Declaring anything after a rest argument is rejected at creation time: `[extra]` cannot follow a rest argument (`...`) — it must be last.

How input is split

Arguments are filled left to right:
  1. Single-word arguments take the next whitespace-separated word.
  2. A rest argument takes everything still unconsumed, trimmed.
  3. Leftover text beyond your declarations is dropped from named arguments — but it is still reachable through {args} and the positional {1}, {2}, … placeholders.
Given ;cc set report (target) (category) [details...] -- ...:
Declaration names must start with a letter and may contain letters, digits, _, and -. Mismatched brackets like <member] are rejected.