GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - gargshilpi22/debugger: port of ruby-debug that works on 1.9.2 and 1.9.3

BranchesTags
Open more actions menu
 
 

Latest commit

 

History

233 Commits
233 Commits

Folders and files

NameName
Last commit message
Last commit date
bin
bin
 
 
doc
doc
 
 
emacs
emacs
 
 
ext/ruby_debug
ext/ruby_debug
 
 
lib
lib
 
 
man
man
 
 
old_scripts
old_scripts
 
 
test
test
 
 
.travis.yml
.travis.yml
 
 
AUTHORS
AUTHORS
 
 
CHANGELOG.md
CHANGELOG.md
 
 
LICENSE
LICENSE
 
 
OLDER_CHANGELOG
OLDER_CHANGELOG
 
 
OLD_CHANGELOG
OLD_CHANGELOG
 
 
OLD_README
OLD_README
 
 
README.md
README.md
 
 
Rakefile
Rakefile
 
 
debugger.gemspec
debugger.gemspec
 
 

Repository files navigation

Description

A fork of ruby-debug(19) that works on 1.9.2 and 1.9.3 and installs easily for rvm/rbenv rubies.

Build Status

Install

$ gem install debugger

# If install fails, try passing headers path
$ gem install debugger -- --with-ruby-include=PATH_TO_HEADERS

For Windows install instructions, see OLD_README.

Supported Rubies

On install, debugger tries to find your ruby's headers. If it's unable to find them and your ruby is a patch release, it will use headers included with debugger-ruby_core_source. For the list of rubies supported by debugger see here. If your ruby is not an official patch release i.e. head, dev or an rc, you are responsible for having headers and setting them with --with-ruby-include.

Usage

Wherever you need a debugger, simply:

require 'debugger'; debugger

To use with bundler, drop in your Gemfile:

gem 'debugger'

Configuration

At initialization time, debugger loads config files, executing their lines as if they were actual commands a user has typed. config files are loaded from two locations:

  • /.rdebugrc (/rdebug.ini for windows)
  • $PWD/.rdebugrc ($PWD/rdebug.ini for windows)

Here's a common configuration (yeah, I should make this the default):

set autolist
set autoeval
set autoreload

To see debugger's current settings, use the set command.

Using Commands

For a list of commands:

(rdb: 1) help

Most commands are described in rdebug's man page

$ gem install gem-man
$ man rdebug

More documentation

Some thorough documentation of debugger is found with this bashdb tutorial. For emacs and debugger usage, see another bashdb tutorial

Reason for Fork

  • ruby-debug19 maintainer isn't maintaining:
    • Despite patches from ruby core, no gem release in 2+ years! - 9/1/09.
    • Requests to release a known working 1.9.3 version have been ignored.
    • Doesn't respond to rubyforge issues and doesn't have github issues open.
  • Current install is painful. Requires either manually downloading gems from rubyforge and installing with compiler flags or recompiling ruby.
  • We need a decent ruby debugger for future rubies!

What's different from ruby-debug19

  • Major
    • Works on 1.9.2 and 1.9.3
      • 1.9.2 points to ruby-debug-base19-0.11.25 headers
      • 1.9.3 points to ruby-debug-base19-0.11.26 headers
    • Install painlessly for rvm and rbenv rubies i.e. no compiler flags needed
    • No downloading ruby source during install - was behavior of old ruby_core_source dependency
    • Fix LocalJumpError caused by using proc in extconf.rb
    • Fix where command failing at top level
    • Passing tests are up on travis-ci
  • Minor
    • The gem name matches the module namespace, Debugger, and main required file, debugger.
    • ruby-debug-base19 and ruby-debug19 are released as one gem
    • Rake tasks have been updated
    • No more $LOAD_PATH manipulation or runtime code outside of lib
    • man page available via gem-man

Issues

Please report them on github.

Known Issues

  • If you place a debugger call at the end of a block, debugging will start at the next step and outside of your block. A simple work-around is to place a meaningless step (i.e. puts "STAY") at the end of your block and before debugger.

Contributing

See here for contribution policies. Let's keep this working for the ruby community!

Related projects

  • debugger-completion - autocompletion for debugger commands and more
  • debugger-pry - using pry within debugger
  • pry-debugger - using debugger within pry
  • ruby-debug-passenger - rake task to restart Passenger with debugger connected
  • jruby-debug
  • rb-trepanning - rewrite of ruby-debug that requires a patched ruby

Credits

  • Thanks to the original authors: Kent Sibilev and Mark Moseley
  • Contributors: ericpromislow, jnimety, adammck, hipe, FooBarWidget
  • Fork started on awesome @relevance fridays!

TODO

  • Fix test/test-*.rb
  • Port some of bashdb's docs
  • Use ~/.debuggerrc and bin/debugger and gracefully deprecate rdebug*
  • Work with others willing to tackle jruby, rubinius or windows support

About

port of ruby-debug that works on 1.9.2 and 1.9.3

Resources

Readme
BSD-2-Clause license
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.