Rewrite requests for robots.txt to a dynamic file in the language of your choice. Can be useful when robots.txt directives are updated frequently.
Refer also to: Virtual Host Config or .htaccess?
To use a dynamic language to handle processing of robots.txt requests, simply use the following rule:
RewriteRule ^/robots\.txt /robots.php
Replace robots.php with the filename of your choise and extension relevant to your server-side language.