1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00
pry--pry/lib/pry/commands.rb
Kyrylo Silin 7c8a849fef Refactor the way commands are required
Fix issue #834 (pry-0.9.11.4 failing on Windows 7 64 bit - cannot load
such file)

The problem was introduced by this commit:
25cbe43137

This bug affects *only* Ruby 1.9.3p327, on Windows.

            Choose your destiny
                    |
    --N00B-----------------------PRO--
    |                                |
  TL;DR:                http://bugs.ruby-lang.org/issues/7374
  File::expand_path
  is bugged on
  Ruby 1.9.3p327

This fix is simply an ugly workaround.
2013-02-02 17:27:34 +02:00

6 lines
160 B
Ruby

# Default commands used by Pry.
Pry::Commands = Pry::CommandSet.new
Dir[File.expand_path('../commands', __FILE__) + '/*.rb'].each do |file|
require file
end