creatorArgParser top-level property

ArgParser get creatorArgParser

Returns an argument parser configured for job and task creation commands.

This parser includes common options used across all creation commands:

  • --wizard or -w - Use interactive wizard mode for creation
  • --task-key or -t - Specify the task key for job creation
  • --name or -n - Set the name of the task or job
  • --key or -k - Set the unique key identifier
  • --description or -d - Set the description text
  • --package-name or -p - Set the package name (auto-detected from project)

Implementation

ArgParser get creatorArgParser => ArgParser(allowTrailingOptions: true)
  ..addFlag(
    'wizard',
    abbr: 'w',
    help: "Use the wizard to create a task or job.",
    defaultsTo: false,
  )
  ..addOption(
    "task-key",
    abbr: 't',
    help: "Option is used to specify the task for the command.",
  )
  ..addOption("name", abbr: 'n', help: "The name of the job to create.")
  ..addOption("key", abbr: 'k', help: "The key of the job to create.")
  ..addOption(
    "description",
    abbr: 'd',
    help: "The description of the job to create.",
  )
  ..addOption(
    "package-name",
    abbr: 'p',
    help: "Package name of the app to publish.",
    defaultsTo:
        BuildInfo.androidPackageName ??
        BuildInfo.iosBundleId ??
        "\${ANDROID_PACKAGE}",
  );