Chromium Code Reviews| Index: sdk/lib/_internal/pub/lib/src/command.dart |
| diff --git a/sdk/lib/_internal/pub/lib/src/command.dart b/sdk/lib/_internal/pub/lib/src/command.dart |
| index 6bc10b0e2fc99d0349bb09569da759bee37b57a4..5f0df64ae1daee3acc16c1d281e46c36e43b54da 100644 |
| --- a/sdk/lib/_internal/pub/lib/src/command.dart |
| +++ b/sdk/lib/_internal/pub/lib/src/command.dart |
| @@ -227,6 +227,11 @@ abstract class PubCommand { |
| } |
| } |
| + /// Fails with a usage error [message] for this command. |
| + void usageError(String message) { |
|
nweiz
2014/07/07 19:57:18
Does this shadow [usageError] in utils? That seems
Bob Nystrom
2014/07/07 21:02:59
Yeah. :(
|
| + throw new UsageException(message)..bindUsage(_getUsage()); |
| + } |
| + |
| /// Generates a string of usage information for this command. |
| String _getUsage() { |
| var buffer = new StringBuffer(); |