stefanpenner/ember-cli — pull request #2748 by abuiles (2014-12-15 05:51:56+00:00)
Title: Use AST transforms for adding new routes and resources + path option

This uses the following micro lib
https://github.com/abuiles/ember-router-generator, we still need
support for deletions.

A full list of scenarios can be seen in the following test file
https://github.com/abuiles/ember-router-generator/blob/master/tests/generator-test.js

Instead of using esprima + escodegen I went with https://github.com/benjamn/recast which seems more estable and offers a nicer support for printing code, also works the ES6 features we are using.

I also added the path option so we can now do `ember g route friends/edit --path=:friend_id/edit` or `ember g route account --path=my/account`

The following gif shows the new generator in action:

![](https://s3.amazonaws.com/f.cl.ly/items/2y1u240a0q1T1s3v3a1n/route-generator.gif)