Almost every web developer I know at some point or another has forgot to block search engines and had a test site rank in Google. Well here is a quick way to set it up once and it is configured correctly the Robots.txt file in Ruby on Rails forÂ development, testing and production.
1. InÂ a common controller such as Pages Controller or Home Controller create an action called robots with the following content: [crayon-60fd2dd5272c1278877524/] 2. Create yourÂ robots.txt files based on environment. Put each one of these in the config/ [...]