{"action":"created","comment":{"url":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/comments/152841764","pull_request_review_id":78766326,"id":152841764,"diff_hunk":"@@ -132,3 +134,14 @@ def _build_gdef(ufo):\n                      (glyph, ' '.join(unicode(p) for p in sorted(caretPos))))\n     lines.append('} GDEF;')\n     return '\\n'.join(lines)\n+\n+\n+def replace_feature(tag, repl, features):\n+    if not repl.endswith(\"\\n\"):\n+        repl += \"\\n\"\n+    return re.sub(\n+        r\"(?<=^feature %(tag)s {\\n)(.*)(?=^} %(tag)s;$)\" % {\"tag\": tag},","path":"Lib/glyphsLib/builder/features.py","position":19,"original_position":19,"commit_id":"71195cb4165a314187a49fe25b1b662db0fb14ce","original_commit_id":"71195cb4165a314187a49fe25b1b662db0fb14ce","user":{"login":"belluzj","id":3616772,"avatar_url":"https://avatars3.githubusercontent.com/u/3616772?v=4","gravatar_id":"","url":"https://api.github.com/users/belluzj","html_url":"https://github.com/belluzj","followers_url":"https://api.github.com/users/belluzj/followers","following_url":"https://api.github.com/users/belluzj/following{/other_user}","gists_url":"https://api.github.com/users/belluzj/gists{/gist_id}","starred_url":"https://api.github.com/users/belluzj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/belluzj/subscriptions","organizations_url":"https://api.github.com/users/belluzj/orgs","repos_url":"https://api.github.com/users/belluzj/repos","events_url":"https://api.github.com/users/belluzj/events{/privacy}","received_events_url":"https://api.github.com/users/belluzj/received_events","type":"User","site_admin":false},"body":"I think the middle `(.*)` should be made non-greedy to avoid consuming an unrelated feature, e.g. if the following is possible:\r\n\r\n```\r\nfeature liga {\r\n} liga;\r\n\r\nfeature calt {\r\n} calt;\r\n\r\nfeature liga {\r\n} liga;\r\n```\r\n\r\n(I don't know if it is possible)","created_at":"2017-11-23T16:34:55Z","updated_at":"2017-11-23T16:34:55Z","html_url":"https://github.com/googlei18n/glyphsLib/pull/289#discussion_r152841764","pull_request_url":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/289","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/comments/152841764"},"html":{"href":"https://github.com/googlei18n/glyphsLib/pull/289#discussion_r152841764"},"pull_request":{"href":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/289"}}},"pull_request":{"url":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/289","id":154413690,"html_url":"https://github.com/googlei18n/glyphsLib/pull/289","diff_url":"https://github.com/googlei18n/glyphsLib/pull/289.diff","patch_url":"https://github.com/googlei18n/glyphsLib/pull/289.patch","issue_url":"https://api.github.com/repos/googlei18n/glyphsLib/issues/289","number":289,"state":"open","locked":false,"title":"[builder] add support for \"Replace Feature\" custom parameter","user":{"login":"anthrotype","id":6939968,"avatar_url":"https://avatars3.githubusercontent.com/u/6939968?v=4","gravatar_id":"","url":"https://api.github.com/users/anthrotype","html_url":"https://github.com/anthrotype","followers_url":"https://api.github.com/users/anthrotype/followers","following_url":"https://api.github.com/users/anthrotype/following{/other_user}","gists_url":"https://api.github.com/users/anthrotype/gists{/gist_id}","starred_url":"https://api.github.com/users/anthrotype/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anthrotype/subscriptions","organizations_url":"https://api.github.com/users/anthrotype/orgs","repos_url":"https://api.github.com/users/anthrotype/repos","events_url":"https://api.github.com/users/anthrotype/events{/privacy}","received_events_url":"https://api.github.com/users/anthrotype/received_events","type":"User","site_admin":false},"body":"Second take\r\nhttps://github.com/googlei18n/glyphsLib/pull/222\r\n\r\n/cc @punchcutter","created_at":"2017-11-23T16:17:15Z","updated_at":"2017-11-23T16:34:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":"72c707c82f5fda4951f90792f74aa6bb11b90781","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/289/commits","review_comments_url":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/289/comments","review_comment_url":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/comments{/number}","comments_url":"https://api.github.com/repos/googlei18n/glyphsLib/issues/289/comments","statuses_url":"https://api.github.com/repos/googlei18n/glyphsLib/statuses/71195cb4165a314187a49fe25b1b662db0fb14ce","head":{"label":"anthrotype:replace-feature","ref":"replace-feature","sha":"71195cb4165a314187a49fe25b1b662db0fb14ce","user":{"login":"anthrotype","id":6939968,"avatar_url":"https://avatars3.githubusercontent.com/u/6939968?v=4","gravatar_id":"","url":"https://api.github.com/users/anthrotype","html_url":"https://github.com/anthrotype","followers_url":"https://api.github.com/users/anthrotype/followers","following_url":"https://api.github.com/users/anthrotype/following{/other_user}","gists_url":"https://api.github.com/users/anthrotype/gists{/gist_id}","starred_url":"https://api.github.com/users/anthrotype/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anthrotype/subscriptions","organizations_url":"https://api.github.com/users/anthrotype/orgs","repos_url":"https://api.github.com/users/anthrotype/repos","events_url":"https://api.github.com/users/anthrotype/events{/privacy}","received_events_url":"https://api.github.com/users/anthrotype/received_events","type":"User","site_admin":false},"repo":{"id":44917748,"name":"glyphsLib","full_name":"anthrotype/glyphsLib","owner":{"login":"anthrotype","id":6939968,"avatar_url":"https://avatars3.githubusercontent.com/u/6939968?v=4","gravatar_id":"","url":"https://api.github.com/users/anthrotype","html_url":"https://github.com/anthrotype","followers_url":"https://api.github.com/users/anthrotype/followers","following_url":"https://api.github.com/users/anthrotype/following{/other_user}","gists_url":"https://api.github.com/users/anthrotype/gists{/gist_id}","starred_url":"https://api.github.com/users/anthrotype/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anthrotype/subscriptions","organizations_url":"https://api.github.com/users/anthrotype/orgs","repos_url":"https://api.github.com/users/anthrotype/repos","events_url":"https://api.github.com/users/anthrotype/events{/privacy}","received_events_url":"https://api.github.com/users/anthrotype/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/anthrotype/glyphsLib","description":null,"fork":true,"url":"https://api.github.com/repos/anthrotype/glyphsLib","forks_url":"https://api.github.com/repos/anthrotype/glyphsLib/forks","keys_url":"https://api.github.com/repos/anthrotype/glyphsLib/keys{/key_id}","collaborators_url":"https://api.github.com/repos/anthrotype/glyphsLib/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/anthrotype/glyphsLib/teams","hooks_url":"https://api.github.com/repos/anthrotype/glyphsLib/hooks","issue_events_url":"https://api.github.com/repos/anthrotype/glyphsLib/issues/events{/number}","events_url":"https://api.github.com/repos/anthrotype/glyphsLib/events","assignees_url":"https://api.github.com/repos/anthrotype/glyphsLib/assignees{/user}","branches_url":"https://api.github.com/repos/anthrotype/glyphsLib/branches{/branch}","tags_url":"https://api.github.com/repos/anthrotype/glyphsLib/tags","blobs_url":"https://api.github.com/repos/anthrotype/glyphsLib/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/anthrotype/glyphsLib/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/anthrotype/glyphsLib/git/refs{/sha}","trees_url":"https://api.github.com/repos/anthrotype/glyphsLib/git/trees{/sha}","statuses_url":"https://api.github.com/repos/anthrotype/glyphsLib/statuses/{sha}","languages_url":"https://api.github.com/repos/anthrotype/glyphsLib/languages","stargazers_url":"https://api.github.com/repos/anthrotype/glyphsLib/stargazers","contributors_url":"https://api.github.com/repos/anthrotype/glyphsLib/contributors","subscribers_url":"https://api.github.com/repos/anthrotype/glyphsLib/subscribers","subscription_url":"https://api.github.com/repos/anthrotype/glyphsLib/subscription","commits_url":"https://api.github.com/repos/anthrotype/glyphsLib/commits{/sha}","git_commits_url":"https://api.github.com/repos/anthrotype/glyphsLib/git/commits{/sha}","comments_url":"https://api.github.com/repos/anthrotype/glyphsLib/comments{/number}","issue_comment_url":"https://api.github.com/repos/anthrotype/glyphsLib/issues/comments{/number}","contents_url":"https://api.github.com/repos/anthrotype/glyphsLib/contents/{+path}","compare_url":"https://api.github.com/repos/anthrotype/glyphsLib/compare/{base}...{head}","merges_url":"https://api.github.com/repos/anthrotype/glyphsLib/merges","archive_url":"https://api.github.com/repos/anthrotype/glyphsLib/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/anthrotype/glyphsLib/downloads","issues_url":"https://api.github.com/repos/anthrotype/glyphsLib/issues{/number}","pulls_url":"https://api.github.com/repos/anthrotype/glyphsLib/pulls{/number}","milestones_url":"https://api.github.com/repos/anthrotype/glyphsLib/milestones{/number}","notifications_url":"https://api.github.com/repos/anthrotype/glyphsLib/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/anthrotype/glyphsLib/labels{/name}","releases_url":"https://api.github.com/repos/anthrotype/glyphsLib/releases{/id}","deployments_url":"https://api.github.com/repos/anthrotype/glyphsLib/deployments","created_at":"2015-10-25T16:13:16Z","updated_at":"2016-11-30T16:20:17Z","pushed_at":"2017-11-23T16:15:29Z","git_url":"git://github.com/anthrotype/glyphsLib.git","ssh_url":"git@github.com:anthrotype/glyphsLib.git","clone_url":"https://github.com/anthrotype/glyphsLib.git","svn_url":"https://github.com/anthrotype/glyphsLib","homepage":null,"size":2677,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"googlei18n:master","ref":"master","sha":"9af7a1aa4d8ec07c66e412792540949b2cc9ec96","user":{"login":"googlei18n","id":5503833,"avatar_url":"https://avatars3.githubusercontent.com/u/5503833?v=4","gravatar_id":"","url":"https://api.github.com/users/googlei18n","html_url":"https://github.com/googlei18n","followers_url":"https://api.github.com/users/googlei18n/followers","following_url":"https://api.github.com/users/googlei18n/following{/other_user}","gists_url":"https://api.github.com/users/googlei18n/gists{/gist_id}","starred_url":"https://api.github.com/users/googlei18n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/googlei18n/subscriptions","organizations_url":"https://api.github.com/users/googlei18n/orgs","repos_url":"https://api.github.com/users/googlei18n/repos","events_url":"https://api.github.com/users/googlei18n/events{/privacy}","received_events_url":"https://api.github.com/users/googlei18n/received_events","type":"Organization","site_admin":false},"repo":{"id":44563779,"name":"glyphsLib","full_name":"googlei18n/glyphsLib","owner":{"login":"googlei18n","id":5503833,"avatar_url":"https://avatars3.githubusercontent.com/u/5503833?v=4","gravatar_id":"","url":"https://api.github.com/users/googlei18n","html_url":"https://github.com/googlei18n","followers_url":"https://api.github.com/users/googlei18n/followers","following_url":"https://api.github.com/users/googlei18n/following{/other_user}","gists_url":"https://api.github.com/users/googlei18n/gists{/gist_id}","starred_url":"https://api.github.com/users/googlei18n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/googlei18n/subscriptions","organizations_url":"https://api.github.com/users/googlei18n/orgs","repos_url":"https://api.github.com/users/googlei18n/repos","events_url":"https://api.github.com/users/googlei18n/events{/privacy}","received_events_url":"https://api.github.com/users/googlei18n/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/googlei18n/glyphsLib","description":"A bridge from Glyphs source files (.glyphs) to UFOs","fork":false,"url":"https://api.github.com/repos/googlei18n/glyphsLib","forks_url":"https://api.github.com/repos/googlei18n/glyphsLib/forks","keys_url":"https://api.github.com/repos/googlei18n/glyphsLib/keys{/key_id}","collaborators_url":"https://api.github.com/repos/googlei18n/glyphsLib/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/googlei18n/glyphsLib/teams","hooks_url":"https://api.github.com/repos/googlei18n/glyphsLib/hooks","issue_events_url":"https://api.github.com/repos/googlei18n/glyphsLib/issues/events{/number}","events_url":"https://api.github.com/repos/googlei18n/glyphsLib/events","assignees_url":"https://api.github.com/repos/googlei18n/glyphsLib/assignees{/user}","branches_url":"https://api.github.com/repos/googlei18n/glyphsLib/branches{/branch}","tags_url":"https://api.github.com/repos/googlei18n/glyphsLib/tags","blobs_url":"https://api.github.com/repos/googlei18n/glyphsLib/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/googlei18n/glyphsLib/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/googlei18n/glyphsLib/git/refs{/sha}","trees_url":"https://api.github.com/repos/googlei18n/glyphsLib/git/trees{/sha}","statuses_url":"https://api.github.com/repos/googlei18n/glyphsLib/statuses/{sha}","languages_url":"https://api.github.com/repos/googlei18n/glyphsLib/languages","stargazers_url":"https://api.github.com/repos/googlei18n/glyphsLib/stargazers","contributors_url":"https://api.github.com/repos/googlei18n/glyphsLib/contributors","subscribers_url":"https://api.github.com/repos/googlei18n/glyphsLib/subscribers","subscription_url":"https://api.github.com/repos/googlei18n/glyphsLib/subscription","commits_url":"https://api.github.com/repos/googlei18n/glyphsLib/commits{/sha}","git_commits_url":"https://api.github.com/repos/googlei18n/glyphsLib/git/commits{/sha}","comments_url":"https://api.github.com/repos/googlei18n/glyphsLib/comments{/number}","issue_comment_url":"https://api.github.com/repos/googlei18n/glyphsLib/issues/comments{/number}","contents_url":"https://api.github.com/repos/googlei18n/glyphsLib/contents/{+path}","compare_url":"https://api.github.com/repos/googlei18n/glyphsLib/compare/{base}...{head}","merges_url":"https://api.github.com/repos/googlei18n/glyphsLib/merges","archive_url":"https://api.github.com/repos/googlei18n/glyphsLib/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/googlei18n/glyphsLib/downloads","issues_url":"https://api.github.com/repos/googlei18n/glyphsLib/issues{/number}","pulls_url":"https://api.github.com/repos/googlei18n/glyphsLib/pulls{/number}","milestones_url":"https://api.github.com/repos/googlei18n/glyphsLib/milestones{/number}","notifications_url":"https://api.github.com/repos/googlei18n/glyphsLib/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/googlei18n/glyphsLib/labels{/name}","releases_url":"https://api.github.com/repos/googlei18n/glyphsLib/releases{/id}","deployments_url":"https://api.github.com/repos/googlei18n/glyphsLib/deployments","created_at":"2015-10-19T21:00:22Z","updated_at":"2017-11-12T11:09:37Z","pushed_at":"2017-11-23T16:17:15Z","git_url":"git://github.com/googlei18n/glyphsLib.git","ssh_url":"git@github.com:googlei18n/glyphsLib.git","clone_url":"https://github.com/googlei18n/glyphsLib.git","svn_url":"https://github.com/googlei18n/glyphsLib","homepage":"","size":2718,"stargazers_count":36,"watchers_count":36,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":25,"mirror_url":null,"archived":false,"open_issues_count":40,"forks":25,"open_issues":40,"watchers":36,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/289"},"html":{"href":"https://github.com/googlei18n/glyphsLib/pull/289"},"issue":{"href":"https://api.github.com/repos/googlei18n/glyphsLib/issues/289"},"comments":{"href":"https://api.github.com/repos/googlei18n/glyphsLib/issues/289/comments"},"review_comments":{"href":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/289/comments"},"review_comment":{"href":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/googlei18n/glyphsLib/pulls/289/commits"},"statuses":{"href":"https://api.github.com/repos/googlei18n/glyphsLib/statuses/71195cb4165a314187a49fe25b1b662db0fb14ce"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"belluzj"}}