ProjectIdOption.nonMandatory constructor

const ProjectIdOption.nonMandatory({
  1. bool asFirstArg = false,
  2. bool excludeSettings = false,
  3. OptionGroup? group,
})

Used for commands that interactively ask for the project ID if not already specified.

If asFirstArg is true, the project ID can be also passed as the first positional argument. If excludeSettings is true, the user's context setting will not affect this value.

Implementation

const ProjectIdOption.nonMandatory({
  final bool asFirstArg = false,
  final bool excludeSettings = false,
  final OptionGroup? group,
}) : this._(
       asFirstArg: asFirstArg,
       excludeSettings: excludeSettings,
       mandatory: false,
       helpText: asFirstArg ? _helpTextFirstArg : _helpText,
       group: group,
     );