diff options
author | Shin'ya Ueoka <ueokande@i-beam.org> | 2020-03-25 07:19:44 +0900 |
---|---|---|
committer | Shin'ya Ueoka <ueokande@i-beam.org> | 2020-03-25 07:19:44 +0900 |
commit | 7d51364584e9081f71f4691a713bb737f7573a74 (patch) | |
tree | 9140b88490cf6cb778a96b9ddacc17bb8f296cf1 /src/console/commandline/CommandParser.ts | |
parent | f7479c36ad0883455e511a86adf86e147ff4460a (diff) |
Revert "Remove ! from commands"
This reverts commit f7479c36ad0883455e511a86adf86e147ff4460a.
Diffstat (limited to 'src/console/commandline/CommandParser.ts')
-rw-r--r-- | src/console/commandline/CommandParser.ts | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/console/commandline/CommandParser.ts b/src/console/commandline/CommandParser.ts index 79ae8c8..5228c77 100644 --- a/src/console/commandline/CommandParser.ts +++ b/src/console/commandline/CommandParser.ts @@ -8,8 +8,6 @@ export class UnknownCommandError extends Error { export default class CommandParser { parse(value: string): Command { - value = value.replace(/!$/, ""); - switch (value) { case 'o': case 'open': @@ -27,8 +25,14 @@ export default class CommandParser { case 'bdel': case 'bdelete': return Command.BufferDelete; + case 'bd!': + case 'bdel!': + case 'bdelete!': + return Command.BufferDeleteForce; case 'bdeletes': return Command.BuffersDelete; + case 'bdeletes!': + return Command.BuffersDeleteForce; case 'addbookmark': return Command.AddBookmark; case 'q': |