aboutsummaryrefslogtreecommitdiff
path: root/Plugin
diff options
context:
space:
mode:
authorDavid Phillips <david@sighup.nz>2018-04-10 15:23:56 +1200
committerDavid Phillips <david@sighup.nz>2018-04-10 15:23:56 +1200
commit5504bcd369b33874c92e49c2383e5f73d1a5a702 (patch)
tree70b61649c80368e7eee0ab3a261a5c2da1d7440e /Plugin
parentcd1fc57841deab0e9b8bcfad49d527c6b263534c (diff)
downloadidalius-5504bcd369b33874c92e49c2383e5f73d1a5a702.tar.xz
Add echo command
Diffstat (limited to 'Plugin')
-rw-r--r--Plugin/Echo.pm26
1 files changed, 26 insertions, 0 deletions
diff --git a/Plugin/Echo.pm b/Plugin/Echo.pm
new file mode 100644
index 0000000..9b23af8
--- /dev/null
+++ b/Plugin/Echo.pm
@@ -0,0 +1,26 @@
+#!/usr/bin/env perl
+
+package Plugin::Echo;
+
+use strict;
+use warnings;
+
+my %config;
+
+sub configure {
+ my $self = shift;
+ my $cmdref = shift;
+ my $cref = shift;
+ %config = %$cref;
+
+ $cmdref->("echo", sub { $self->echo(@_); } );
+
+ return $self;
+}
+
+sub echo {
+ my ($self, $logger, $who, $where, $rest, @arguments) = @_;
+
+ return $rest;
+}
+1;