Created
April 28, 2010 08:09
-
-
Save cpetschnig/381859 to your computer and use it in GitHub Desktop.
My irb customization file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'rubygems' | |
| irb_extensions = [] | |
| begin | |
| # load wirble | |
| require 'wirble' | |
| # start wirble (with color) | |
| Wirble.init | |
| Wirble.colorize | |
| irb_extensions << "Wirble" | |
| rescue LoadError => err | |
| warn "Couldn't load Wirble: #{err}" | |
| end | |
| class Object | |
| def xmethods | |
| (self.methods - Object.new.methods).sort | |
| end | |
| end | |
| irb_extensions << "Object#xmethods" | |
| puts "Custom irb extensions: #{irb_extensions.join(', ')}" unless irb_extensions.empty? | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment