{"action":"created","comment":{"url":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/comments/84575645","pull_request_review_id":5348043,"id":84575645,"diff_hunk":"@@ -115,44 +113,47 @@ pub fn build(config: &Config) -> Result<()> {\n     // January 1, 1970 0:00:00 UTC, the beginning of time\n     let default_date = UTC.timestamp(0, 0).with_timezone(&FixedOffset::east(0));\n \n+    let (mut posts, documents): (Vec<Document>, Vec<Document>) = documents.into_iter()\n+        .partition(|x| x.is_post);\n+\n     // sort documents by date, if there's no date (none was provided or it couldn't be read) then\n     // fall back to the default date\n-    documents.sort_by(|a, b| b.date.unwrap_or(default_date).cmp(&a.date.unwrap_or(default_date)));\n+    posts.sort_by(|a, b| b.date.unwrap_or(default_date).cmp(&a.date.unwrap_or(default_date)));\n \n     // check if we should create an RSS file and create it!\n     if let &Some(ref path) = &config.rss {\n-        try!(create_rss(path, dest, &config, &documents));\n+        try!(create_rss(path, dest, &config, &posts));","path":"src/cobalt.rs","position":77,"original_position":75,"commit_id":"edc50729368a60b08358b393760bad9cc6f1a768","original_commit_id":"ac924ba867833db561611fa1fb7be4825a44a7b2","user":{"login":"nott","id":382950,"avatar_url":"https://avatars.githubusercontent.com/u/382950?v=3","gravatar_id":"","url":"https://api.github.com/users/nott","html_url":"https://github.com/nott","followers_url":"https://api.github.com/users/nott/followers","following_url":"https://api.github.com/users/nott/following{/other_user}","gists_url":"https://api.github.com/users/nott/gists{/gist_id}","starred_url":"https://api.github.com/users/nott/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nott/subscriptions","organizations_url":"https://api.github.com/users/nott/orgs","repos_url":"https://api.github.com/users/nott/repos","events_url":"https://api.github.com/users/nott/events{/privacy}","received_events_url":"https://api.github.com/users/nott/received_events","type":"User","site_admin":false},"body":":+1: ","created_at":"2016-10-22T11:49:34Z","updated_at":"2016-10-22T11:49:34Z","html_url":"https://github.com/cobalt-org/cobalt.rs/pull/146#discussion_r84575645","pull_request_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/146","_links":{"self":{"href":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/comments/84575645"},"html":{"href":"https://github.com/cobalt-org/cobalt.rs/pull/146#discussion_r84575645"},"pull_request":{"href":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/146"}}},"pull_request":{"url":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/146","id":90448468,"html_url":"https://github.com/cobalt-org/cobalt.rs/pull/146","diff_url":"https://github.com/cobalt-org/cobalt.rs/pull/146.diff","patch_url":"https://github.com/cobalt-org/cobalt.rs/pull/146.patch","issue_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/issues/146","number":146,"state":"open","locked":false,"title":"Render posts before documents, remove threading","user":{"login":"johannhof","id":2622601,"avatar_url":"https://avatars.githubusercontent.com/u/2622601?v=3","gravatar_id":"","url":"https://api.github.com/users/johannhof","html_url":"https://github.com/johannhof","followers_url":"https://api.github.com/users/johannhof/followers","following_url":"https://api.github.com/users/johannhof/following{/other_user}","gists_url":"https://api.github.com/users/johannhof/gists{/gist_id}","starred_url":"https://api.github.com/users/johannhof/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johannhof/subscriptions","organizations_url":"https://api.github.com/users/johannhof/orgs","repos_url":"https://api.github.com/users/johannhof/repos","events_url":"https://api.github.com/users/johannhof/events{/privacy}","received_events_url":"https://api.github.com/users/johannhof/received_events","type":"User","site_admin":false},"body":"In #138 and #145 I noticed that it might be beneficial to render posts\r\nbefore documents, because documents might want to access post\r\ninformation such as content or excerpt that requires all posts to be\r\nrendered.\r\n\r\nThis also removes the admittedly naive approach of spawning a thread per\r\ndocument which at least by my measurements adds way too much overhead to\r\nbe of any use. I will open a new issue for experimenting with ways to\r\nadd good parallelism.\r\n\r\nFixes #138 by adding a \"content\" attribute to posts.","created_at":"2016-10-21T21:39:20Z","updated_at":"2016-10-22T11:49:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7282f34a4e380edbe0bd97d8b3ea2aaddc92287c","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/146/commits","review_comments_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/146/comments","review_comment_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/issues/146/comments","statuses_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/statuses/edc50729368a60b08358b393760bad9cc6f1a768","head":{"label":"johannhof:master","ref":"master","sha":"edc50729368a60b08358b393760bad9cc6f1a768","user":{"login":"johannhof","id":2622601,"avatar_url":"https://avatars.githubusercontent.com/u/2622601?v=3","gravatar_id":"","url":"https://api.github.com/users/johannhof","html_url":"https://github.com/johannhof","followers_url":"https://api.github.com/users/johannhof/followers","following_url":"https://api.github.com/users/johannhof/following{/other_user}","gists_url":"https://api.github.com/users/johannhof/gists{/gist_id}","starred_url":"https://api.github.com/users/johannhof/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johannhof/subscriptions","organizations_url":"https://api.github.com/users/johannhof/orgs","repos_url":"https://api.github.com/users/johannhof/repos","events_url":"https://api.github.com/users/johannhof/events{/privacy}","received_events_url":"https://api.github.com/users/johannhof/received_events","type":"User","site_admin":false},"repo":{"id":25991623,"name":"cobalt.rs","full_name":"johannhof/cobalt.rs","owner":{"login":"johannhof","id":2622601,"avatar_url":"https://avatars.githubusercontent.com/u/2622601?v=3","gravatar_id":"","url":"https://api.github.com/users/johannhof","html_url":"https://github.com/johannhof","followers_url":"https://api.github.com/users/johannhof/followers","following_url":"https://api.github.com/users/johannhof/following{/other_user}","gists_url":"https://api.github.com/users/johannhof/gists{/gist_id}","starred_url":"https://api.github.com/users/johannhof/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johannhof/subscriptions","organizations_url":"https://api.github.com/users/johannhof/orgs","repos_url":"https://api.github.com/users/johannhof/repos","events_url":"https://api.github.com/users/johannhof/events{/privacy}","received_events_url":"https://api.github.com/users/johannhof/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/johannhof/cobalt.rs","description":"Static Site generator written in rust","fork":true,"url":"https://api.github.com/repos/johannhof/cobalt.rs","forks_url":"https://api.github.com/repos/johannhof/cobalt.rs/forks","keys_url":"https://api.github.com/repos/johannhof/cobalt.rs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/johannhof/cobalt.rs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/johannhof/cobalt.rs/teams","hooks_url":"https://api.github.com/repos/johannhof/cobalt.rs/hooks","issue_events_url":"https://api.github.com/repos/johannhof/cobalt.rs/issues/events{/number}","events_url":"https://api.github.com/repos/johannhof/cobalt.rs/events","assignees_url":"https://api.github.com/repos/johannhof/cobalt.rs/assignees{/user}","branches_url":"https://api.github.com/repos/johannhof/cobalt.rs/branches{/branch}","tags_url":"https://api.github.com/repos/johannhof/cobalt.rs/tags","blobs_url":"https://api.github.com/repos/johannhof/cobalt.rs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/johannhof/cobalt.rs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/johannhof/cobalt.rs/git/refs{/sha}","trees_url":"https://api.github.com/repos/johannhof/cobalt.rs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/johannhof/cobalt.rs/statuses/{sha}","languages_url":"https://api.github.com/repos/johannhof/cobalt.rs/languages","stargazers_url":"https://api.github.com/repos/johannhof/cobalt.rs/stargazers","contributors_url":"https://api.github.com/repos/johannhof/cobalt.rs/contributors","subscribers_url":"https://api.github.com/repos/johannhof/cobalt.rs/subscribers","subscription_url":"https://api.github.com/repos/johannhof/cobalt.rs/subscription","commits_url":"https://api.github.com/repos/johannhof/cobalt.rs/commits{/sha}","git_commits_url":"https://api.github.com/repos/johannhof/cobalt.rs/git/commits{/sha}","comments_url":"https://api.github.com/repos/johannhof/cobalt.rs/comments{/number}","issue_comment_url":"https://api.github.com/repos/johannhof/cobalt.rs/issues/comments{/number}","contents_url":"https://api.github.com/repos/johannhof/cobalt.rs/contents/{+path}","compare_url":"https://api.github.com/repos/johannhof/cobalt.rs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/johannhof/cobalt.rs/merges","archive_url":"https://api.github.com/repos/johannhof/cobalt.rs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/johannhof/cobalt.rs/downloads","issues_url":"https://api.github.com/repos/johannhof/cobalt.rs/issues{/number}","pulls_url":"https://api.github.com/repos/johannhof/cobalt.rs/pulls{/number}","milestones_url":"https://api.github.com/repos/johannhof/cobalt.rs/milestones{/number}","notifications_url":"https://api.github.com/repos/johannhof/cobalt.rs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/johannhof/cobalt.rs/labels{/name}","releases_url":"https://api.github.com/repos/johannhof/cobalt.rs/releases{/id}","deployments_url":"https://api.github.com/repos/johannhof/cobalt.rs/deployments","created_at":"2014-10-30T22:03:40Z","updated_at":"2016-10-22T10:34:52Z","pushed_at":"2016-10-22T10:34:51Z","git_url":"git://github.com/johannhof/cobalt.rs.git","ssh_url":"git@github.com:johannhof/cobalt.rs.git","clone_url":"https://github.com/johannhof/cobalt.rs.git","svn_url":"https://github.com/johannhof/cobalt.rs","homepage":null,"size":271,"stargazers_count":0,"watchers_count":0,"language":"Rust","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":"cobalt-org:master","ref":"master","sha":"d9b1eb88af6d1e6b688918be206b20e6c07579e3","user":{"login":"cobalt-org","id":9417410,"avatar_url":"https://avatars.githubusercontent.com/u/9417410?v=3","gravatar_id":"","url":"https://api.github.com/users/cobalt-org","html_url":"https://github.com/cobalt-org","followers_url":"https://api.github.com/users/cobalt-org/followers","following_url":"https://api.github.com/users/cobalt-org/following{/other_user}","gists_url":"https://api.github.com/users/cobalt-org/gists{/gist_id}","starred_url":"https://api.github.com/users/cobalt-org/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cobalt-org/subscriptions","organizations_url":"https://api.github.com/users/cobalt-org/orgs","repos_url":"https://api.github.com/users/cobalt-org/repos","events_url":"https://api.github.com/users/cobalt-org/events{/privacy}","received_events_url":"https://api.github.com/users/cobalt-org/received_events","type":"Organization","site_admin":false},"repo":{"id":25877885,"name":"cobalt.rs","full_name":"cobalt-org/cobalt.rs","owner":{"login":"cobalt-org","id":9417410,"avatar_url":"https://avatars.githubusercontent.com/u/9417410?v=3","gravatar_id":"","url":"https://api.github.com/users/cobalt-org","html_url":"https://github.com/cobalt-org","followers_url":"https://api.github.com/users/cobalt-org/followers","following_url":"https://api.github.com/users/cobalt-org/following{/other_user}","gists_url":"https://api.github.com/users/cobalt-org/gists{/gist_id}","starred_url":"https://api.github.com/users/cobalt-org/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cobalt-org/subscriptions","organizations_url":"https://api.github.com/users/cobalt-org/orgs","repos_url":"https://api.github.com/users/cobalt-org/repos","events_url":"https://api.github.com/users/cobalt-org/events{/privacy}","received_events_url":"https://api.github.com/users/cobalt-org/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/cobalt-org/cobalt.rs","description":"Static site generator written in Rust","fork":false,"url":"https://api.github.com/repos/cobalt-org/cobalt.rs","forks_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/forks","keys_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/teams","hooks_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/hooks","issue_events_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/issues/events{/number}","events_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/events","assignees_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/assignees{/user}","branches_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/branches{/branch}","tags_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/tags","blobs_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/git/refs{/sha}","trees_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/statuses/{sha}","languages_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/languages","stargazers_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/stargazers","contributors_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/contributors","subscribers_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/subscribers","subscription_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/subscription","commits_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/commits{/sha}","git_commits_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/git/commits{/sha}","comments_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/comments{/number}","issue_comment_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/issues/comments{/number}","contents_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/contents/{+path}","compare_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/merges","archive_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/downloads","issues_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/issues{/number}","pulls_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls{/number}","milestones_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/milestones{/number}","notifications_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/labels{/name}","releases_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/releases{/id}","deployments_url":"https://api.github.com/repos/cobalt-org/cobalt.rs/deployments","created_at":"2014-10-28T16:04:40Z","updated_at":"2016-10-16T19:15:06Z","pushed_at":"2016-10-22T10:34:52Z","git_url":"git://github.com/cobalt-org/cobalt.rs.git","ssh_url":"git@github.com:cobalt-org/cobalt.rs.git","clone_url":"https://github.com/cobalt-org/cobalt.rs.git","svn_url":"https://github.com/cobalt-org/cobalt.rs","homepage":"","size":319,"stargazers_count":168,"watchers_count":168,"language":"Rust","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":28,"mirror_url":null,"open_issues_count":30,"forks":28,"open_issues":30,"watchers":168,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/146"},"html":{"href":"https://github.com/cobalt-org/cobalt.rs/pull/146"},"issue":{"href":"https://api.github.com/repos/cobalt-org/cobalt.rs/issues/146"},"comments":{"href":"https://api.github.com/repos/cobalt-org/cobalt.rs/issues/146/comments"},"review_comments":{"href":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/146/comments"},"review_comment":{"href":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cobalt-org/cobalt.rs/pulls/146/commits"},"statuses":{"href":"https://api.github.com/repos/cobalt-org/cobalt.rs/statuses/edc50729368a60b08358b393760bad9cc6f1a768"}}}}
{"actor":{"display_login":"nott"}}