From 757227bd9faa36660df3d0978dd05cad9da3bf36 Mon Sep 17 00:00:00 2001 From: Mike Dvorkin Date: Fri, 13 May 2011 15:10:06 -0700 Subject: [PATCH] Getting ready for 0.4.0 release --- CHANGELOG | 10 ++++++++++ README.md | 21 ++++++++++----------- 2 files changed, 20 insertions(+), 11 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index d944375..cf56ed7 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,13 @@ +0.4.0 + - 'ap object' now returns the object (Stephan Hagemann) + - Added :html => true option to enable HTML colors rather that ANSI (ex. Sinatra templates) + - Added AwesomePrint.force_colors! to allow color output on demand (Andrew O'Brien) + - Added MongoMapper formatter mixin (Elpizo Choi) + - Fixed formatting of methods array when object#method is overridden + - Fixed potential stack errors by checking whether AwesomePrint is already loaded + - Improved Ruby 1.8.6 and 1.8.7 compatibility + - Improved Windows compatibility (Viktar Basharymau) + 0.3.2 - Make sure Rails mixins get loaded in Rails console when required from .irbrc - Fixed an issue with classes that define their own #send method (ex: Socket) diff --git a/README.md b/README.md index f67ca7f..e63f845 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ objects and usage within Rails templates are supported via included mixins. ### Usage ### - require "ap" + require "awesome_print" ap object, options = {} Default options: @@ -49,7 +49,7 @@ Supported color names: ### Examples ### $ cat > 1.rb - require "ap" + require "awesome_print" data = [ false, 42, %w(forty two), { :now => Time.now, :class => Time.now.class, :distance => 42e42 } ] ap data ^D @@ -69,7 +69,7 @@ Supported color names: ] $ cat > 2.rb - require "ap" + require "awesome_print" data = { :now => Time.now, :class => Time.now.class, :distance => 42e42 } ap data, :indent => -2 # <-- Left align hash keys. ^D @@ -81,7 +81,7 @@ Supported color names: } $ cat > 3.rb - require "ap" + require "awesome_print" data = [ false, 42, %w(forty two) ] data << data # <-- Nested array. ap data, :multiline => false @@ -90,7 +90,7 @@ Supported color names: [ false, 42, [ "forty", "two" ], [...] ] $ cat > 4.rb - require "ap" + require "awesome_print" class Hello def self.world(x, y, z = nil, &blk) end @@ -103,7 +103,7 @@ Supported color names: ] $ cat > 5.rb - require "ap" + require "awesome_print" ap (''.methods - Object.methods).grep(/!/) ^D $ ruby 5.rb @@ -131,7 +131,7 @@ Supported color names: ] $ cat > 6.rb - require "ap" + require "awesome_print" ap 42 == ap(42) ^D $ ruby 6.rb @@ -139,9 +139,8 @@ Supported color names: true ### Example (Rails console) ### - $ ruby script/console - Loading development environment (Rails 2.3.5) - rails> require "ap" + $ rails console + rails> require "awesome_print" rails> ap Account.all(:limit => 2) [ [0] # { @@ -201,7 +200,7 @@ To use awesome_print as default formatter in irb and Rails console add the follo lines into your ~/.irbrc file: require "rubygems" - require "ap" + require "awesome_print" unless IRB.version.include?('DietRB') IRB::Irb.class_eval do