Plugin for debugging Lita chatbot
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib
spec
.gitignore
.travis.yml
Gemfile
README.md
Rakefile
lita-debug.gemspec

README.md

lita-debug

Build Status Coverage Status

A plugin for debugging Lita interactively, in production.

Installation

Add lita-debug to your Lita instance's Gemfile:

gem "lita-debug"

Configuration

# lita_config.rb

Lita.configure do |config|
  config.handlers.debug.enable_eval = true
  config.handlers.debug.restrict_eval_to = [:admins]
  config.handlers.debug.restrict_debug_to = [:admins, :developers]
end

Usage

Lita > lita debug
---
:server:
  :hostname: minion.local
:room: !ruby/object:Lita::Room
  id: shell
  metadata: {}
  name: shell
:user: !ruby/object:Lita::User
  id: '1'
  metadata:
    name: Shell User
  name: Shell User

Lita > lita eval response.room.name
"shell"
Lita > lita eval robot.name
"Lita"
Lita > lita eval 1+2
3