error method
Prints a red error message and exits with code 1.
Implementation
void error(String message) {
final error =
'''
\x1B[31m$message\x1B[0m
\x1B[31mRun 'dart tool/feature_gen_cli.dart -h' for more information\x1B[0m''';
stdout.writeln(error);
exit(1);
}