publicUsageWithoutDescription property

String get publicUsageWithoutDescription
inherited

Implementation

String get publicUsageWithoutDescription {
  final length = argParser.usageLineLength ?? 0;
  final usegeLines = argParser.customUsage.split('\n');
  final buffer = StringBuffer();
  if (subcommands.isNotEmpty) {
    buffer.write(
      getStyledCommandUsage(
        subcommands,
        isSubcommand: true,
        lineLength: length,
        helpUsageLength: getUsagePrefixLength,
      ),
    );
  } else {
    buffer
      ..withPrefix(theme.symbols.dotStep, theme.promptTheme.hintStyle('No subcommands available'))
      ..newLine()
      ..prefixLine()
      ..newLine();
  }
  buffer.write(getStyleCommandUsegeBottom(usegeLines, usageFooter, invocation));

  return buffer.toString();
}