public
Last active

Track requires order

  • Download Gist
require tree
1 2 3 4 5 6 7 8 9
$rlevel = []
alias :orig_require :require
def require(file)
puts "#{$rlevel.join}#{file}"
$rlevel << "-"
req = orig_require(file)
$rlevel.pop
req
end

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.