I am doing a project in rails, I would like to know How do I check whether I am running in developer mode or production mode in code ?
Thanks
Rails.env == "production" Rails.env == "development"
As mentioned by @xoebus, this is far better:
Rails.env.production? Rails.env.development?