From 660c143a895ba43fb92823828500a2597f42bb45 Mon Sep 17 00:00:00 2001 From: Renan araujo Date: Tue, 5 Dec 2023 21:54:17 +0000 Subject: [PATCH] feat: add command runner constructor arguments --- .idea/misc.xml | 1 - lib/src/command_runner/completion_command_runner.dart | 7 ++++++- lib/src/installer/shell_completion_configuration.dart | 1 + 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.idea/misc.xml b/.idea/misc.xml index 639900d..6e86672 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,4 +1,3 @@ - diff --git a/lib/src/command_runner/completion_command_runner.dart b/lib/src/command_runner/completion_command_runner.dart index f333bbf..e619764 100644 --- a/lib/src/command_runner/completion_command_runner.dart +++ b/lib/src/command_runner/completion_command_runner.dart @@ -22,7 +22,12 @@ import 'package:meta/meta.dart'; /// manually install completion files. abstract class CompletionCommandRunner extends CommandRunner { /// {@macro completion_command_runner} - CompletionCommandRunner(super.executableName, super.description) { + CompletionCommandRunner( + super.executableName, + super.description, { + super.usageLineLength, + super.suggestionDistanceLimit, + }) { addCommand(HandleCompletionRequestCommand()); addCommand(InstallCompletionFilesCommand()); addCommand(UnistallCompletionFilesCommand()); diff --git a/lib/src/installer/shell_completion_configuration.dart b/lib/src/installer/shell_completion_configuration.dart index 36b18d9..ee19dca 100644 --- a/lib/src/installer/shell_completion_configuration.dart +++ b/lib/src/installer/shell_completion_configuration.dart @@ -16,6 +16,7 @@ typedef SourceStringTemplate = String Function(String scriptPath); /// See: /// - [ShellCompletionConfiguration.fromSystemShell] to retrieve the /// configuration for a [SystemShell]. +/// {@endtemplate} @immutable class ShellCompletionConfiguration { /// {@macro shell_completion_configuration}