{"action":"created","comment":{"url":"https://api.github.com/repos/rebar/rebar3/pulls/comments/37697858","id":37697858,"diff_hunk":"@@ -265,10 +260,29 @@ init_erlcinfo(InclDirs, Erls, Dir) ->\n             file:delete(erlcinfo_file(Dir))\n     end,\n     Dirs = source_and_include_dirs(InclDirs, Erls),\n-    Modified = lists:foldl(update_erlcinfo_fun(G, Dirs), false, Erls),\n-    if Modified -> store_erlcinfo(G, InclDirs, Dir); not Modified -> ok end,\n+    %% A source file may have been renamed or deleted. Remove it from the graph\n+    %% and remove any beam file for that source if it exists.\n+    Modified = maybe_rm_beams_and_edges(G, OutDir, Erls),\n+    Modified1 = lists:foldl(update_erlcinfo_fun(G, Dirs), false, Erls) orelse Modified,","path":"src/rebar_erlc_compiler.erl","position":49,"original_position":49,"commit_id":"d93a485459f6354fe182bf424f9b614de6d8beef","original_commit_id":"d93a485459f6354fe182bf424f9b614de6d8beef","user":{"login":"ferd","id":111141,"avatar_url":"https://avatars.githubusercontent.com/u/111141?v=3","gravatar_id":"","url":"https://api.github.com/users/ferd","html_url":"https://github.com/ferd","followers_url":"https://api.github.com/users/ferd/followers","following_url":"https://api.github.com/users/ferd/following{/other_user}","gists_url":"https://api.github.com/users/ferd/gists{/gist_id}","starred_url":"https://api.github.com/users/ferd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ferd/subscriptions","organizations_url":"https://api.github.com/users/ferd/orgs","repos_url":"https://api.github.com/users/ferd/repos","events_url":"https://api.github.com/users/ferd/events{/privacy}","received_events_url":"https://api.github.com/users/ferd/received_events","type":"User","site_admin":false},"body":"`Modified1 = lists:foldl(update_erlcinfo_fun(G, Dirs), Modified, Erls)`","created_at":"2015-08-22T17:46:23Z","updated_at":"2015-08-22T17:46:23Z","html_url":"https://github.com/rebar/rebar3/pull/736#discussion_r37697858","pull_request_url":"https://api.github.com/repos/rebar/rebar3/pulls/736","_links":{"self":{"href":"https://api.github.com/repos/rebar/rebar3/pulls/comments/37697858"},"html":{"href":"https://github.com/rebar/rebar3/pull/736#discussion_r37697858"},"pull_request":{"href":"https://api.github.com/repos/rebar/rebar3/pulls/736"}}},"pull_request":{"url":"https://api.github.com/repos/rebar/rebar3/pulls/736","id":43106124,"html_url":"https://github.com/rebar/rebar3/pull/736","diff_url":"https://github.com/rebar/rebar3/pull/736.diff","patch_url":"https://github.com/rebar/rebar3/pull/736.patch","issue_url":"https://api.github.com/repos/rebar/rebar3/issues/736","number":736,"state":"open","locked":false,"title":"update erlcinfo on disk if source file removed","user":{"login":"tsloughter","id":36227,"avatar_url":"https://avatars.githubusercontent.com/u/36227?v=3","gravatar_id":"","url":"https://api.github.com/users/tsloughter","html_url":"https://github.com/tsloughter","followers_url":"https://api.github.com/users/tsloughter/followers","following_url":"https://api.github.com/users/tsloughter/following{/other_user}","gists_url":"https://api.github.com/users/tsloughter/gists{/gist_id}","starred_url":"https://api.github.com/users/tsloughter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tsloughter/subscriptions","organizations_url":"https://api.github.com/users/tsloughter/orgs","repos_url":"https://api.github.com/users/tsloughter/repos","events_url":"https://api.github.com/users/tsloughter/events{/privacy}","received_events_url":"https://api.github.com/users/tsloughter/received_events","type":"User","site_admin":false},"body":"This fixes an issue where while during the run the digraph would have an edge removed for a removed source file this update what not written to disk.\r\n\r\nFixes https://github.com/rebar/rebar3/issues/714","created_at":"2015-08-22T16:37:35Z","updated_at":"2015-08-22T17:46:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"20687fd0bcc60001fadd14e8f276fbe0aed24089","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/rebar/rebar3/pulls/736/commits","review_comments_url":"https://api.github.com/repos/rebar/rebar3/pulls/736/comments","review_comment_url":"https://api.github.com/repos/rebar/rebar3/pulls/comments{/number}","comments_url":"https://api.github.com/repos/rebar/rebar3/issues/736/comments","statuses_url":"https://api.github.com/repos/rebar/rebar3/statuses/d93a485459f6354fe182bf424f9b614de6d8beef","head":{"label":"tsloughter:update_erlcinfo","ref":"update_erlcinfo","sha":"d93a485459f6354fe182bf424f9b614de6d8beef","user":{"login":"tsloughter","id":36227,"avatar_url":"https://avatars.githubusercontent.com/u/36227?v=3","gravatar_id":"","url":"https://api.github.com/users/tsloughter","html_url":"https://github.com/tsloughter","followers_url":"https://api.github.com/users/tsloughter/followers","following_url":"https://api.github.com/users/tsloughter/following{/other_user}","gists_url":"https://api.github.com/users/tsloughter/gists{/gist_id}","starred_url":"https://api.github.com/users/tsloughter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tsloughter/subscriptions","organizations_url":"https://api.github.com/users/tsloughter/orgs","repos_url":"https://api.github.com/users/tsloughter/repos","events_url":"https://api.github.com/users/tsloughter/events{/privacy}","received_events_url":"https://api.github.com/users/tsloughter/received_events","type":"User","site_admin":false},"repo":{"id":26615042,"name":"rebar3","full_name":"tsloughter/rebar3","owner":{"login":"tsloughter","id":36227,"avatar_url":"https://avatars.githubusercontent.com/u/36227?v=3","gravatar_id":"","url":"https://api.github.com/users/tsloughter","html_url":"https://github.com/tsloughter","followers_url":"https://api.github.com/users/tsloughter/followers","following_url":"https://api.github.com/users/tsloughter/following{/other_user}","gists_url":"https://api.github.com/users/tsloughter/gists{/gist_id}","starred_url":"https://api.github.com/users/tsloughter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tsloughter/subscriptions","organizations_url":"https://api.github.com/users/tsloughter/orgs","repos_url":"https://api.github.com/users/tsloughter/repos","events_url":"https://api.github.com/users/tsloughter/events{/privacy}","received_events_url":"https://api.github.com/users/tsloughter/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tsloughter/rebar3","description":"Erlang build tool that makes it easy to compile and test Erlang applications, port drivers and releases.","fork":true,"url":"https://api.github.com/repos/tsloughter/rebar3","forks_url":"https://api.github.com/repos/tsloughter/rebar3/forks","keys_url":"https://api.github.com/repos/tsloughter/rebar3/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tsloughter/rebar3/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tsloughter/rebar3/teams","hooks_url":"https://api.github.com/repos/tsloughter/rebar3/hooks","issue_events_url":"https://api.github.com/repos/tsloughter/rebar3/issues/events{/number}","events_url":"https://api.github.com/repos/tsloughter/rebar3/events","assignees_url":"https://api.github.com/repos/tsloughter/rebar3/assignees{/user}","branches_url":"https://api.github.com/repos/tsloughter/rebar3/branches{/branch}","tags_url":"https://api.github.com/repos/tsloughter/rebar3/tags","blobs_url":"https://api.github.com/repos/tsloughter/rebar3/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tsloughter/rebar3/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tsloughter/rebar3/git/refs{/sha}","trees_url":"https://api.github.com/repos/tsloughter/rebar3/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tsloughter/rebar3/statuses/{sha}","languages_url":"https://api.github.com/repos/tsloughter/rebar3/languages","stargazers_url":"https://api.github.com/repos/tsloughter/rebar3/stargazers","contributors_url":"https://api.github.com/repos/tsloughter/rebar3/contributors","subscribers_url":"https://api.github.com/repos/tsloughter/rebar3/subscribers","subscription_url":"https://api.github.com/repos/tsloughter/rebar3/subscription","commits_url":"https://api.github.com/repos/tsloughter/rebar3/commits{/sha}","git_commits_url":"https://api.github.com/repos/tsloughter/rebar3/git/commits{/sha}","comments_url":"https://api.github.com/repos/tsloughter/rebar3/comments{/number}","issue_comment_url":"https://api.github.com/repos/tsloughter/rebar3/issues/comments{/number}","contents_url":"https://api.github.com/repos/tsloughter/rebar3/contents/{+path}","compare_url":"https://api.github.com/repos/tsloughter/rebar3/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tsloughter/rebar3/merges","archive_url":"https://api.github.com/repos/tsloughter/rebar3/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tsloughter/rebar3/downloads","issues_url":"https://api.github.com/repos/tsloughter/rebar3/issues{/number}","pulls_url":"https://api.github.com/repos/tsloughter/rebar3/pulls{/number}","milestones_url":"https://api.github.com/repos/tsloughter/rebar3/milestones{/number}","notifications_url":"https://api.github.com/repos/tsloughter/rebar3/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tsloughter/rebar3/labels{/name}","releases_url":"https://api.github.com/repos/tsloughter/rebar3/releases{/id}","created_at":"2014-11-14T00:42:34Z","updated_at":"2015-05-08T13:53:41Z","pushed_at":"2015-08-22T16:36:18Z","git_url":"git://github.com/tsloughter/rebar3.git","ssh_url":"git@github.com:tsloughter/rebar3.git","clone_url":"https://github.com/tsloughter/rebar3.git","svn_url":"https://github.com/tsloughter/rebar3","homepage":"  http://www.rebar3.org","size":5515,"stargazers_count":0,"watchers_count":0,"language":"Erlang","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"rebar:master","ref":"master","sha":"1f6516b231260a1b2e48f9b86e37a5d317d4983c","user":{"login":"rebar","id":2651508,"avatar_url":"https://avatars.githubusercontent.com/u/2651508?v=3","gravatar_id":"","url":"https://api.github.com/users/rebar","html_url":"https://github.com/rebar","followers_url":"https://api.github.com/users/rebar/followers","following_url":"https://api.github.com/users/rebar/following{/other_user}","gists_url":"https://api.github.com/users/rebar/gists{/gist_id}","starred_url":"https://api.github.com/users/rebar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rebar/subscriptions","organizations_url":"https://api.github.com/users/rebar/orgs","repos_url":"https://api.github.com/users/rebar/repos","events_url":"https://api.github.com/users/rebar/events{/privacy}","received_events_url":"https://api.github.com/users/rebar/received_events","type":"Organization","site_admin":false},"repo":{"id":26610130,"name":"rebar3","full_name":"rebar/rebar3","owner":{"login":"rebar","id":2651508,"avatar_url":"https://avatars.githubusercontent.com/u/2651508?v=3","gravatar_id":"","url":"https://api.github.com/users/rebar","html_url":"https://github.com/rebar","followers_url":"https://api.github.com/users/rebar/followers","following_url":"https://api.github.com/users/rebar/following{/other_user}","gists_url":"https://api.github.com/users/rebar/gists{/gist_id}","starred_url":"https://api.github.com/users/rebar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rebar/subscriptions","organizations_url":"https://api.github.com/users/rebar/orgs","repos_url":"https://api.github.com/users/rebar/repos","events_url":"https://api.github.com/users/rebar/events{/privacy}","received_events_url":"https://api.github.com/users/rebar/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/rebar/rebar3","description":"Erlang build tool that makes it easy to compile and test Erlang applications, port drivers and releases.","fork":false,"url":"https://api.github.com/repos/rebar/rebar3","forks_url":"https://api.github.com/repos/rebar/rebar3/forks","keys_url":"https://api.github.com/repos/rebar/rebar3/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rebar/rebar3/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rebar/rebar3/teams","hooks_url":"https://api.github.com/repos/rebar/rebar3/hooks","issue_events_url":"https://api.github.com/repos/rebar/rebar3/issues/events{/number}","events_url":"https://api.github.com/repos/rebar/rebar3/events","assignees_url":"https://api.github.com/repos/rebar/rebar3/assignees{/user}","branches_url":"https://api.github.com/repos/rebar/rebar3/branches{/branch}","tags_url":"https://api.github.com/repos/rebar/rebar3/tags","blobs_url":"https://api.github.com/repos/rebar/rebar3/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rebar/rebar3/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rebar/rebar3/git/refs{/sha}","trees_url":"https://api.github.com/repos/rebar/rebar3/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rebar/rebar3/statuses/{sha}","languages_url":"https://api.github.com/repos/rebar/rebar3/languages","stargazers_url":"https://api.github.com/repos/rebar/rebar3/stargazers","contributors_url":"https://api.github.com/repos/rebar/rebar3/contributors","subscribers_url":"https://api.github.com/repos/rebar/rebar3/subscribers","subscription_url":"https://api.github.com/repos/rebar/rebar3/subscription","commits_url":"https://api.github.com/repos/rebar/rebar3/commits{/sha}","git_commits_url":"https://api.github.com/repos/rebar/rebar3/git/commits{/sha}","comments_url":"https://api.github.com/repos/rebar/rebar3/comments{/number}","issue_comment_url":"https://api.github.com/repos/rebar/rebar3/issues/comments{/number}","contents_url":"https://api.github.com/repos/rebar/rebar3/contents/{+path}","compare_url":"https://api.github.com/repos/rebar/rebar3/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rebar/rebar3/merges","archive_url":"https://api.github.com/repos/rebar/rebar3/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rebar/rebar3/downloads","issues_url":"https://api.github.com/repos/rebar/rebar3/issues{/number}","pulls_url":"https://api.github.com/repos/rebar/rebar3/pulls{/number}","milestones_url":"https://api.github.com/repos/rebar/rebar3/milestones{/number}","notifications_url":"https://api.github.com/repos/rebar/rebar3/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rebar/rebar3/labels{/name}","releases_url":"https://api.github.com/repos/rebar/rebar3/releases{/id}","created_at":"2014-11-13T22:02:03Z","updated_at":"2015-08-21T19:22:29Z","pushed_at":"2015-08-22T16:37:35Z","git_url":"git://github.com/rebar/rebar3.git","ssh_url":"git@github.com:rebar/rebar3.git","clone_url":"https://github.com/rebar/rebar3.git","svn_url":"https://github.com/rebar/rebar3","homepage":"  http://www.rebar3.org","size":9825,"stargazers_count":171,"watchers_count":171,"language":"Erlang","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":60,"mirror_url":null,"open_issues_count":39,"forks":60,"open_issues":39,"watchers":171,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/rebar/rebar3/pulls/736"},"html":{"href":"https://github.com/rebar/rebar3/pull/736"},"issue":{"href":"https://api.github.com/repos/rebar/rebar3/issues/736"},"comments":{"href":"https://api.github.com/repos/rebar/rebar3/issues/736/comments"},"review_comments":{"href":"https://api.github.com/repos/rebar/rebar3/pulls/736/comments"},"review_comment":{"href":"https://api.github.com/repos/rebar/rebar3/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/rebar/rebar3/pulls/736/commits"},"statuses":{"href":"https://api.github.com/repos/rebar/rebar3/statuses/d93a485459f6354fe182bf424f9b614de6d8beef"}}}}