Generate customize routes for my javascript

im try to add a routes to my javascript i have a file routes.coffee and i want to insert there every time i generate something im try this inject_into_file “javascript/routes.coffee” , “test” but nothing happen