Skip to content

A value doesn't fit a generator

error: "button" can't be name for generator component: it must match [A-Z][A-Za-z0-9]*
hint: Give another value with --set name=<value>.

A value given to axle generate was refused before anything was written, because:

  • it doesn’t match the variable’s pattern, or isn’t one of its choices;
  • it’s empty;
  • --set names a variable the generator doesn’t have (the message then says generator component has no variable named colour and lists the ones it has), or wasn’t written as <variable>=<value>;
  • name was given both as the argument and with --set;
  • for the package generator, a package with that name is already in the workspace.

Give a value that fits what the message says. axle generate in a terminal shows each variable’s question and choices, and asks again when an answer doesn’t fit.