https://www.thebloxstrap.com.co/post/how-to-use-rails-magic-methods-in-plain-ruby-scripts-bsok6c