BatchCommand constructor

BatchCommand()

Creates a new batch command instance.

Implementation

BatchCommand() {
  argParser
    ..addOption(
      'collection',
      abbr: 'c',
      help: 'Collection path (e.g., users)',
      mandatory: true,
    )
    ..addOption(
      'file',
      abbr: 'f',
      help: 'JSON file path containing an array of documents',
      mandatory: true,
    )
    ..addOption(
      'id-field',
      help: 'Field name to use as document ID (auto-ID if not found)',
    )
    ..addFlag(
      'merge',
      help: 'Merge with existing documents instead of replacing',
    )
    ..addFlag(
      'apply',
      help: 'Apply changes (without this flag, runs in dry-run mode)',
    )
    ..addFlag(
      'verbose',
      abbr: 'v',
      help: 'Show detailed output',
    );
}