Hi, I''m announcing Hirb, a mini view framework which enables script/ console to provide custom views. Out of the box your activerecord objects come back as ascii tables. You can also configure your tree-based models to return as ascii trees: Numeric |-- Float |-- Integer | |-- Bignum | `-- Fixnum |-- Date::Infinity `-- Rational I''ve written two tutorials on it: http://tagaholic.me/2009/03/13/hirb-irb-on-the-good-stuff.html and http://tagaholic.me/2009/03/18/ruby-class-trees-rails-plugin-trees-with-hirb.html It''s also got some decent documentation: http://tagaholic.me/hirb/doc/ To try it out: gem install cldwalker-hirb --source http://gems.github.com Enjoy! Gabriel --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Gabriel, This looks pretty cool! Quick question: is there a way to set this up to be used automatically from script/console and/or irb? Thanks, -Danimal On Mar 27, 2:39 pm, cldwalker <gabriel.hor...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi, > I''m announcingHirb, a mini view framework which enables script/ > console to provide custom views. > Out of the box your activerecord objects come back as ascii tables. > You can also configure your tree-based models to return as ascii > trees: > Numeric > |-- Float > |-- Integer > | |-- Bignum > | `-- Fixnum > |-- Date::Infinity > `-- Rational > > I''ve written two tutorials on it: http://tagaholic.me/2009/03/13/hirb-irb-on-the-good-stuff.html > andhttp://tagaholic.me/2009/03/18/ruby-class-trees-rails-plugin-trees-wi... > It''s also got some decent documentation:http://tagaholic.me/hirb/doc/ > > To try it out: gem install cldwalker-hirb--sourcehttp://gems.github.com > > Enjoy! > Gabriel--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Philip Hallstrom
2009-Mar-31 16:47 UTC
Re: ANNOUNCE: Hirb - A gem enhancing your script/console
> This looks pretty cool! Quick question: is there a way to set this up > to be used automatically from script/console and/or irb?Should be able to just put the following into your ~/.irbrc require ''hirb'' Hirb::View.enable> Thanks, > > -Danimal > > On Mar 27, 2:39 pm, cldwalker <gabriel.hor...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> Hi, >> I''m announcingHirb, a mini view framework which enables script/ >> console to provide custom views. >> Out of the box your activerecord objects come back as ascii tables. >> You can also configure your tree-based models to return as ascii >> trees: >> Numeric >> |-- Float >> |-- Integer >> | |-- Bignum >> | `-- Fixnum >> |-- Date::Infinity >> `-- Rational >> >> I''ve written two tutorials on it: http://tagaholic.me/2009/03/13/hirb-irb-on-the-good-stuff.html >> andhttp://tagaholic.me/2009/03/18/ruby-class-trees-rails-plugin-trees-wi >> ... >> It''s also got some decent documentation:http://tagaholic.me/hirb/doc/ >> >> To try it out: gem install cldwalker-hirb--sourcehttp://gems.github.com >> >> Enjoy! >> Gabriel > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Thanks Phillip. Danimal, if you''re using Hirb just for Rails, you can add it in config/environment.rb and only have it load when using script/console: if $0 == ''irb'' require ''hirb'' Hirb::View.enable end Also, if you''re using Wirble make sure to put Hirb::View.enable after loading Wirble. Gabriel On Mar 31, 12:47 pm, Philip Hallstrom <phi...-LSG90OXdqQE@public.gmane.org> wrote:> > This looks pretty cool! Quick question: is there a way to set this up > > to be used automatically from script/console and/or irb? > > Should be able to just put the following into your ~/.irbrc > > require ''hirb'' > Hirb::View.enable > > > Thanks, > > > -Danimal > > > On Mar 27, 2:39 pm, cldwalker <gabriel.hor...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > >> Hi, > >> I''m announcingHirb, a mini view framework which enables script/ > >> console to provide custom views. > >> Out of the box your activerecord objects come back as ascii tables. > >> You can also configure your tree-based models to return as ascii > >> trees: > >> Numeric > >> |-- Float > >> |-- Integer > >> | |-- Bignum > >> | `-- Fixnum > >> |-- Date::Infinity > >> `-- Rational > > >> I''ve written two tutorials on it: http://tagaholic.me/2009/03/13/hirb-irb-on-the-good-stuff.html > >> andhttp://tagaholic.me/2009/03/18/ruby-class-trees-rails-plugin-trees-wi > >> ... > >> It''s also got some decent documentation:http://tagaholic.me/hirb/doc/ > > >> To try it out: gem install cldwalker-hirb--sourcehttp://gems.github.com > > >> Enjoy! > >> Gabriel--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---