PubGetCommand constructor

PubGetCommand({
  1. required PubspecLock pubspecLock,
  2. required PubspecYaml pubspecYaml,
  3. required FileSystem fs,
  4. required Logger logger,
  5. required Bindings bindings,
  6. required FindFile findFile,
  7. required ScriptsYaml scriptsYaml,
  8. required RunManyScripts runManyScripts,
  9. required RunOneScript runOneScript,
})

Implementation

PubGetCommand({
  required super.pubspecLock,
  required super.pubspecYaml,
  required super.fs,
  required super.logger,
  required super.bindings,
  required super.findFile,
  required super.scriptsYaml,
  required super.runManyScripts,
  required super.runOneScript,
}) {
  argParser
    ..addFlag(
      'offline',
      help: 'Use cached packages instead of accessing the network.',
    )
    ..addFlag(
      'dry-run',
      abbr: 'n',
      negatable: false,
      help: "Report what dependencies would change but don't change any.",
    )
    ..addFlag(
      'enforce-lockfile',
      negatable: false,
      help: 'Enforce pubspec.lock. Fail resolution if '
          'pubspec.lock does not satisfy pubspec.yaml',
    )
    ..addFlag(
      'unlock-transitive',
    )
    ..addFlag(
      'precompile',
      help: 'Build executables in immediate dependencies.',
    );
}