printUsage method

  1. @override
void printUsage()
override

Prints the usage information for this command.

This is called internally by run and can be overridden by subclasses to control how output is displayed or integrate with a logging system.

Implementation

@override
void printUsage() {
  print('Add Flutter packages to your project\n');
  print('Usage:');
  print('  dcf add <package1> [package2] [...]');
  print('  dcf add --dev <package1> [package2] [...]');
  print('\nOptions:');
  print('  --dev    Add as dev dependency');
  print('\nExamples:');
  print('  dcf add http');
  print('  dcf add http dio shared_preferences');
  print('  dcf add --dev build_runner');
}