Quick reference for efficient coding
View the Project on GitHub YumaYX/RubyQuickReference
__FILE__ in Ruby is a predefined constant that represents the current file’s name. It returns a string with the name of the file in which it is used.
__FILE__
__FILE__ #=> "file.rb(irb)"
Executed with Ruby 3.3.5
3.3.5