Skip to content

Commit d7cdfd5

Browse files
authored
feat: add installation process for zsh (#7)
1 parent 8d401ab commit d7cdfd5

18 files changed

+982
-44
lines changed

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,6 @@
44
.dart_tool/
55
.packages
66
build/
7-
pubspec.lock
7+
pubspec.lock
8+
9+
coverage/

.idea/.gitignore

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/cli_completion.iml

Lines changed: 15 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/misc.xml

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/modules.xml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/vcs.xml

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/cli_completion.dart

Lines changed: 0 additions & 11 deletions
This file was deleted.

lib/install.dart

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
/// Contains the functions related to the installation file
2+
library install;
3+
4+
export 'src/install/install_completion.dart';
5+
export 'src/install/shell_completion_installation.dart';

lib/src/cli_completion.dart

Lines changed: 0 additions & 14 deletions
This file was deleted.

lib/src/exceptions.dart

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
/// {@template completion_installation_exception}
2+
/// Describes an exception during the installation of completion scripts.
3+
/// {@endtemplate}
4+
class CompletionInstallationException implements Exception {
5+
/// {@macro completion_installation_exception}
6+
CompletionInstallationException({
7+
required this.message,
8+
required this.rootCommand,
9+
});
10+
11+
/// The error message for this exception
12+
final String message;
13+
14+
/// The command for which the installation failed.
15+
final String rootCommand;
16+
17+
@override
18+
String toString() => 'Could not install completion scripts for $rootCommand: '
19+
'$message';
20+
}

0 commit comments

Comments
 (0)