From 6671b847b432aca57cf29979dbce45a69d932322 Mon Sep 17 00:00:00 2001 From: Matias Linares Date: Tue, 31 Mar 2020 20:38:41 -0300 Subject: Initial commit --- lib/Matrix/Bot/DeprecatedOrg.pm6 | 56 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 lib/Matrix/Bot/DeprecatedOrg.pm6 (limited to 'lib/Matrix/Bot/DeprecatedOrg.pm6') diff --git a/lib/Matrix/Bot/DeprecatedOrg.pm6 b/lib/Matrix/Bot/DeprecatedOrg.pm6 new file mode 100644 index 0000000..d7daea8 --- /dev/null +++ b/lib/Matrix/Bot/DeprecatedOrg.pm6 @@ -0,0 +1,56 @@ +use v6.c; +unit class Matrix::Bot::DeprecatedOrg:ver<0.0.1>:auth; + +use Config; +use Matrix::Bot; +use Matrix::Bot::Plugin::Dominating; + + +sub MAIN($config-file where *.IO.f) is export { + my $config = Config.new().read($config-file); + + my %matrix-config = $config; + dd %matrix-config; + dd $config; + + my $bot = Matrix::Bot.new( + home-server => %matrix-config, + username => %matrix-config, + password => %matrix-config, + plugins => [ + Matrix::Bot::Plugin::Dominating.new(:config($config)) + ], + ); + + $bot.run; +} + +=begin pod + +=head1 NAME + +Matrix::Bot::DeprecatedOrg - blah blah blah + +=head1 SYNOPSIS + +=begin code :lang + +use Matrix::Bot::DeprecatedOrg; + +=end code + +=head1 DESCRIPTION + +Matrix::Bot::DeprecatedOrg is ... + +=head1 AUTHOR + +Matias Linares + +=head1 COPYRIGHT AND LICENSE + +Copyright 2020 Matias Linares + +This library is free software; you can redistribute it and/or modify it under the Artistic License 2.0. + +=end pod -- cgit v1.2.3-70-g09d2