Working with Ruby
Hi, I am Jan. This is my old Ruby blog. I still post about Ruby, but I now do it on idiosyncratic-ruby.com. You should also install Irbtools to improve your IRB.

Idiosyncratic Ruby

May 2015, one-liners · regex · golf · fun · docs · irb · thoughts · tutorial · hints · stdlib · ruby

For the whole of May, I will blog about weird things in Ruby over at Idiosyncratic Ruby – Don’t miss it!

Building yet another terminal colors gem: term-ansicolor meets rainbow

There are plenty terminal color gems out there. Now, there is one more. Why?

…read

eurucamp: Tweak your Ruby consoles - 2011 edition

♥ .railsrc / rails console snippets

13 Rails-specific hints for your rails 3 console.

…read

Small Ruby CLI Improvements (Part 4): Edit Ruby Objects Using yaml

Somehow, I stumbled upon this useful little script by _why: Update

…read

Small Ruby CLI Improvements (Part 3): Hirb vs. Unicode

Hirb: “A mini view framework for console/irb that’s easy to use, even while under its influence. Console goodies include a no-wrap table, auto-pager, tree and menu.” now supports unicode in two ways:

┌───────────────────────────────────────────┬───────────────────────────────────────────────┐ │ Support for unicode full-width characters │ Unicode table characters instead of +/- chars │ └───────────────────────────────────────────┴───────────────────────────────────────────────┘

…read

Small Ruby CLI Improvements (Part 2): Wirb!

Many people use irb with wirble. I also did.

I’ve been quite happy with it, but sometimes I noted that some symbols were displayed as : without the symbol name (e.g. in method name arrays) and that the representation of regexes looked quite strange.

This is why I’ve looked at the wirble tokenizer, fixed some bugs, liked it, extended it and created Wirb. These are the improvements:

…read

Small Ruby CLI Improvements (Part 1): Command-line Regex Debugging

This little method (now also available in zucker/debug) is useful for understanding and creating regexes:

…read

ripl: Why should you use an irb alternative?

What does it mean when the guy who blogged about irb’s details and wrote most of the successful irb gems (hirb, bond, boson) decides to implement his own irb alternative? There must be something wrong with irb!

…read

Use fresh Ruby as your shell!

We love Ruby. And we love the command line. So… the shell needs to be rubyfied ;).

Fresh is a new gem, trying to achieve this.

Updated for fresh version 0.2.0.

…read

IRB rockets and colors

Introducing the fancy_irb gem:

  • Use fancy colors! You can colorize the prompts, irb errors, stderr and stdout
  • Output results as Ruby comments
  • Enhance your output value using procs

irbtools / Release the power of irb!

Equipped with some tools discussed at the germany.rb 2010 user group meetup, I’ve played around with my ~/.irbrc and put together a little meta gem for some useful irb tools (github)

…read

Little heplers for Ruby print debugging

Not everyone likes debuggers. I rather print the debug values myself – it works and I do not need to learn a debugger :P

…read

New features of Ruby Zucker version 2 and 3

The Zucker gem has gotten some new features. Installation is as easy as
 gem install zucker
and
 require 'zucker/all'

…read

The multi mega method list

One of my favourite ways of learning something about existing code is to load it into irb and play around with it. You are able to ask every object in irb what it can do. It is as easy as you just asking for methods or public_methods and the object will show its abilities. But often you get spammed by Object or irb methods that you rarely want to use.

…read

RubyBuntu -3- Be one with your command line!

Most Ruby programmers know: Many things can be done in much less time on the command line. To become more productive, you should take the 10 minutes to configure some basic settings.

…read