From 6afd74fb5199c946c3e56e21433df12cc13445c0 Mon Sep 17 00:00:00 2001 From: Teddy Wing Date: Thu, 15 Feb 2018 00:50:39 +0100 Subject: Add `help` command Provide a command to print the documentation via Irssi's built-in `help` command. Uses the mechanism I used in Vimput to get autocompletion of "dimpid" even though it isn't a command. --- dimpid.pl | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/dimpid.pl b/dimpid.pl index b809dab..2bcf180 100644 --- a/dimpid.pl +++ b/dimpid.pl @@ -42,6 +42,38 @@ our %IRSSI = { use constant ESCAPE => "\x{03}"; use constant GREY => '14'; + +Irssi::command_bind('help dimpid', sub { + my $help = <