Coder Social home page Coder Social logo

lib-rubydebug's Introduction

ruby-debug client written in JavaScript

Status: dev

This project includes:

  • An implementation of the ruby-debug-ide Protocol:
    • Can run in the browser and on the server.
  • An intelligent nodejs based ruby-debug-ide proxy server:
    • Expose an async ruby-debug-ide interface to the browser via socket.io.
    • Control ruby-debug from the server, the browser or both at the same time.
  • A ruby-debug-ide client library that connects to ruby-debug-ide directly or to the proxy server.
  • A client UI showing events as they are executed used for development and testing.

NOTE: The ruby-debug-ide protocol specification as documented here is not complete. More commands are available. Missing commands may be implemented here.

Usage

Requirements

Installing ruby-debug-ide from http://github.com/cadorn/ruby-debug-ide:

gem install bundle
gem install test-unit
gem install ruby-debug-base
gem install ruby-debug-base19x  // Ignore for Ruby 1.8
git clone git://github.com/cadorn/ruby-debug-ide.git
cd ruby-debug-ide
bundle update
bundle exec rake build
gem install pkg/ruby-debug-ide-0.4.17.beta8.gem

Install

npm install -g connect socket.io socket.io-client cli q xml2js
git clone git://github.com/ajaxorg/lib-rubydebug.git
cd lib-rubydebug
git checkout dev
git submodule init
git submodule update

Setup

Launch debug proxy server:

node ./example/server --port 9080

Use -v to log major events to console and -d to log debug messages to console.

Test

The following will run a bunch of tests to cover all supported use-cases:

node ./test/all --port 9080 --skip-browser-tests

TIP: If the example client is open at http://localhost:9080/ it will show the progress of the tests if the --skip-browser-tests argument is omitted.

Demo

Open the example client at http://localhost:9080/ (served from the debug proxy server).

You can now use the client to run the test suite using the Run All Tests link.

TODO

High

Medium

  • List breakpoints fix - ruby-debug/ruby-debug-ide#14 (pull-request in place)
  • Test with Ruby 1.9
  • Command flooding support for all command combinations (may need protocol improvements to do this for all commands)

Low

  • Improve rdebug-ide protocol to separate each command response and pass through a command ID to match command requests to command responses.
  • Make ruby-debug-ide commands consistent with rdebug commands
  • End session event - ruby-debug/ruby-debug-ide#8 (workaround in place)
  • Script output - ruby-debug/ruby-debug-ide#9 (workaround in place)
  • Use same test cases on server and client (need test framework that works on server and browser)

Author

The original implementation of this project is by Christoph Dorn.

License

The MIT License

Copyright(c) 2011 Ajax.org B.V.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

lib-rubydebug's People

Contributors

cadorn avatar

Watchers

 avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.