summaryrefslogtreecommitdiff
path: root/src/commands.cc
diff options
context:
space:
mode:
authorMaxime Coste <frrrwww@gmail.com>2013-01-03 18:52:07 +0100
committerMaxime Coste <frrrwww@gmail.com>2013-01-03 18:52:07 +0100
commit08fd946c07e2a45fd2edbb28217d66b3991607ef (patch)
treef371a634425f491ede21298e8922c4f03ab1c2a6 /src/commands.cc
parentf84e46f8058e2e93f6f9377b661327773d3b05fd (diff)
Add a nop command to avoid accidental shell output evaluation
Diffstat (limited to 'src/commands.cc')
-rw-r--r--src/commands.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/commands.cc b/src/commands.cc
index 6f32be9f..98fca3a1 100644
--- a/src/commands.cc
+++ b/src/commands.cc
@@ -674,6 +674,8 @@ void register_commands()
{
CommandManager& cm = CommandManager::instance();
+ cm.register_commands({"nop"}, [](const CommandParameters&, Context&){});
+
PerArgumentCommandCompleter filename_completer({ complete_filename });
cm.register_commands({ "e", "edit" }, edit<false>, filename_completer);
cm.register_commands({ "e!", "edit!" }, edit<true>, filename_completer);