validateOrg method

bool validateOrg()

Implementation

bool validateOrg() {
  String validator = '^[A-Za-z]{2,6}((?!-).[A-Za-z0-9-]{1,63})+\$';
  if (argResults!.wasParsed('org')) {
    String org = stringArg('org')!;
    Match? match = RegExp(validator).matchAsPrefix(org);
    return match != null && match.end == org.length;
  }
  return true;
}