diff --git a/Admin.md b/Admin.md new file mode 100644 index 0000000..0724ab8 --- /dev/null +++ b/Admin.md @@ -0,0 +1,42 @@ +# ircbot admin bot + +Everything is supposed to be ran inside a remote IEx console: `./bin/lsg remote`. + +## Connection management + +### List Connections + + IRC.Connection.connections() + +### Add Connection + + conn = %{nick: "nick", user: "user", name: "user", network: "netname", host: "irc.netname.org", tls: true, port: 6697} + IRC.Connection.add_connection(conn) + +### Start Connection + + IRC.Connection.start_connection(connection_id) + +### Stop Connection + + IRC.Connection.stop_connection(connection_id) + +### Delete Connection + + IRC.Connection.delete_connection(connection_id) + +## Plugin management + +### Enabled plugins + + IRC.Plugin.enabled() + +### Enable or Disable a plugin + + IRC.Plugin.disable(plugin_module_or_name) + IRC.Plugin.enable(plugin_module_or_name) + IRC.Plugin.switch(plugin_module_or_name) + +### Declare a plugin + + IRC.Plugin.declare(module) diff --git a/README.md b/README.md index 75131f3..b597530 100644 --- a/README.md +++ b/README.md @@ -1,60 +1,47 @@ -# LSG +# ircbot -## What - - * Provides a small API on top of Icecast status page +Some stupid and badly coded IRC bot. Can be spotted as "bavaria" on irc.random.sh, but is multi-connections and also elsewhere (poor channels). ## Development To start your Phoenix server: * Install dependencies with `mix deps.get` * Start Phoenix endpoint with `mix phx.server` Now you can visit [`localhost:4000`](http://localhost:4000) from your browser. Ready to run in production? Please [check our deployment guides](http://www.phoenixframework.org/docs/deployment). ## Production Build a release using `MIX_ENV=prod mix release`. # bot ## ideas +* logger * rate limiting only allow x/messages per x/period ignore user for exponential values notice user "Enhance Your Calm!" -* duck games with mendiant taxe radio +* duck games * markov txt * markov par txt * markov global * log to dets * !seen * !grab * 420 counter * kick roulette * counts ("won" and "lost") * !kickrandom (+ counts) * ? * partyline en pv * partyline! pour join la PL * parler en query <=> broadcast a tout les personnes qui ont "partyline!" * account/admin auth by password? (hosts are not always stable) * reminder * admin: /msg bot bsay message => broadcast message to channels * admin: /msg bot say #channel message => message to #channel - -21:13:35.202 [error] GenServer #PID<0.18734.0> terminating -** (BadMapError) expected a map, got: nil - (elixir) lib/map.ex:424: Map.get(nil, "Content Type:", false) - (lsg) lib/lsg/icecast.ex:66: LSG.Icecast.update_stats/1 - (lsg) lib/lsg/icecast.ex:29: LSG.Icecast.poll/1 - (lsg) lib/lsg/icecast.ex:16: LSG.Icecast.handle_cast/2 - (stdlib) gen_server.erl:616: :gen_server.try_dispatch/4 - (stdlib) gen_server.erl:686: :gen_server.handle_msg/6 - (stdlib) proc_lib.erl:247: :proc_lib.init_p_do_apply/3 -Last message: {:"$gen_cast", :poll} -