{"action":"created","issue":{"url":"https://api.github.com/repos/phoenixframework/phoenix/issues/673","labels_url":"https://api.github.com/repos/phoenixframework/phoenix/issues/673/labels{/name}","comments_url":"https://api.github.com/repos/phoenixframework/phoenix/issues/673/comments","events_url":"https://api.github.com/repos/phoenixframework/phoenix/issues/673/events","html_url":"https://github.com/phoenixframework/phoenix/issues/673","id":60303177,"number":673,"title":"resource generator puts code in uncompilable state","user":{"login":"ptrckbrwn","id":4147775,"avatar_url":"https://avatars.githubusercontent.com/u/4147775?v=3","gravatar_id":"","url":"https://api.github.com/users/ptrckbrwn","html_url":"https://github.com/ptrckbrwn","followers_url":"https://api.github.com/users/ptrckbrwn/followers","following_url":"https://api.github.com/users/ptrckbrwn/following{/other_user}","gists_url":"https://api.github.com/users/ptrckbrwn/gists{/gist_id}","starred_url":"https://api.github.com/users/ptrckbrwn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ptrckbrwn/subscriptions","organizations_url":"https://api.github.com/users/ptrckbrwn/orgs","repos_url":"https://api.github.com/users/ptrckbrwn/repos","events_url":"https://api.github.com/users/ptrckbrwn/events{/privacy}","received_events_url":"https://api.github.com/users/ptrckbrwn/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-03-09T06:14:44Z","updated_at":"2015-03-09T13:37:09Z","closed_at":null,"body":"Given these series of commands:\r\n```\r\nmix phoenix.new hello_phoenix /Users/ptrckbrwn/src/hello_phoenix\r\ncd ../hello_phoenix\r\nmix do deps.get, compile\r\nmix ecto.create\r\nmix phoenix.gen.resource Tweet tweets text:string\r\nmix ecto.migrate\r\n```\r\nOn the last command the process errors out.\r\n```\r\n== Compilation error on file web/controllers/tweet_controller.ex ==\r\n** (CompileError) web/controllers/tweet_controller.ex:27: function tweet_path/2 undefined\r\n    (stdlib) lists.erl:1336: :lists.foreach/2\r\n    (stdlib) erl_eval.erl:657: :erl_eval.do_apply/6\r\n```"},"comment":{"url":"https://api.github.com/repos/phoenixframework/phoenix/issues/comments/77853968","html_url":"https://github.com/phoenixframework/phoenix/issues/673#issuecomment-77853968","issue_url":"https://api.github.com/repos/phoenixframework/phoenix/issues/673","id":77853968,"user":{"login":"ptrckbrwn","id":4147775,"avatar_url":"https://avatars.githubusercontent.com/u/4147775?v=3","gravatar_id":"","url":"https://api.github.com/users/ptrckbrwn","html_url":"https://github.com/ptrckbrwn","followers_url":"https://api.github.com/users/ptrckbrwn/followers","following_url":"https://api.github.com/users/ptrckbrwn/following{/other_user}","gists_url":"https://api.github.com/users/ptrckbrwn/gists{/gist_id}","starred_url":"https://api.github.com/users/ptrckbrwn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ptrckbrwn/subscriptions","organizations_url":"https://api.github.com/users/ptrckbrwn/orgs","repos_url":"https://api.github.com/users/ptrckbrwn/repos","events_url":"https://api.github.com/users/ptrckbrwn/events{/privacy}","received_events_url":"https://api.github.com/users/ptrckbrwn/received_events","type":"User","site_admin":false},"created_at":"2015-03-09T13:37:09Z","updated_at":"2015-03-09T13:37:09Z","body":"Ah gotcha, I must of missed the message after running the generator. I think asking the user to do it is better: even if the generator could put it in the right place, the routes.ex could get pretty hairy.\r\n\r\nLooking back at my terminal logs the instructions are pretty clear... I think my main issue was that it was 2am :)"}}