run method

  1. @override
FutureOr<int> run()
override

Runs this command.

The return value is wrapped in a Future if necessary and returned by CommandRunner.runCommand.

Implementation

@override
FutureOr<int> run() async {
  final String licenseKey = argResults?['key'] ?? '';
  if (licenseKey.isEmpty) {
    print('No license key found');
    return 1;
  }
  await _activateLicense(licenseKey);
  return 0;
}