Require command not working within bash irb on Snow Leopard

后端 未结 2 666
北恋
北恋 2021-01-12 08:00

I am working on Zed Shaw\'s Learn Ruby the Hard Way Exercise 25

http://ruby.learncodethehardway.org/ex25.html

When I navigate to the directory that holds the

2条回答
  •  时光说笑
    2021-01-12 08:51

    This is because the working directory is no longer in the Ruby path in Ruby 1.9.2. This does work:

    require './ex25'
    

提交回复
热议问题