Provides a better Warning Message facility to Ruby.
Ruby
Switch branches/tags
Nothing to show
Permalink
Failed to load latest commit information.
lib Version bump. Jun 25, 2011
spec Fixed specs. Jun 24, 2011
.document Initial commit. Jun 24, 2011
.gitignore Initial commit. Jun 24, 2011
.rspec Initial commit. Jun 24, 2011
.yardopts Initial commit. Jun 24, 2011
ChangeLog.md Updated the ChangeLog for 0.1.1. Jun 25, 2011
LICENSE.txt Initial commit. Jun 24, 2011
README.md Wording. Jun 25, 2011
Rakefile Use rubygems-tasks ~> 0.1. Apr 25, 2012
gemspec.yml Use rubygems-tasks ~> 0.1. Apr 25, 2012
warnings.gemspec Initial commit. Jun 24, 2011

README.md

warnings

Description

Warnings provides a searchable and more readable Warning Message facility for Ruby. With Warnings, one can save all warning messages generated by your code, search through them and print them upon exit.

Features

  • Respects $VERBOSE (ruby -w) and $DEBUG (ruby -d)
  • Search Warning Messages by:
    • Message
    • Source File
    • Source Method
  • Prints unique Warning messages upon exit.
  • ANSI Coloring.

Examples

require 'warnings'

def danger!
  warn "Fire in the disco!"
end

danger!
danger!

Warnings.grep(/fire/)
# => [...]

Warnings.from('foo/bar.rb')
# => [...]

Warnings.from_method('danger!')
# => [...]

exit
#
# Warnings:
#
#   fire in the disco!
#      lib/foo/bar.rb:42

Install

$ gem install warnings

Copyright

Copyright (c) 2011 Hal Brodigan

See {file:LICENSE.txt} for details.