Extend IRB main methods
问题 I have a directory structure in my app. For development purposes (and possibly beyond), I currently have a class X which has class methods pwd , cd , and ls . Is there a way to make these methods available when I enter irb whithin my app, for example: 2.1.5 :0 > pwd /current_dir/ Currently I am doing: 2.1.5 :0 > X.pwd /current_dir/ which is simply inconvenient. A solution where I could simply add something to my existing class would be perfect, like: class X < Irb::main def self.pwd #stuff