{"action":"created","comment":{"url":"https://api.github.com/repos/inducer/relate/pulls/comments/68611169","id":68611169,"diff_hunk":"@@ -0,0 +1,53 @@\n+# -*- coding: utf-8 -*-\n+\n+from __future__ import division\n+\n+__copyright__ = \"Copyright (C) 2016 Dong Zhuang, Andreas Kloeckner\"\n+\n+__license__ = \"\"\"\n+Permission is hereby granted, free of charge, to any person obtaining a copy\n+of this software and associated documentation files (the \"Software\"), to deal\n+in the Software without restriction, including without limitation the rights\n+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n+copies of the Software, and to permit persons to whom the Software is\n+furnished to do so, subject to the following conditions:\n+\n+The above copyright notice and this permission notice shall be included in\n+all copies or substantial portions of the Software.\n+\n+THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n+THE SOFTWARE.\n+\"\"\"\n+\n+from django.core.checks import register, Tags as DjangoTags\n+from django.conf import settings\n+\n+from course.latex.utils import get_all_indirect_subclasses\n+from course.latex.converter import CommandBase\n+\n+class Tags(DjangoTags):\n+    relate_course_tag = 'relate_course_tag'\n+\n+@register(Tags.relate_course_tag)\n+@register(Tags.relate_course_tag, deploy=True)","path":"course/check.py","position":37,"original_position":37,"commit_id":"6d2d8f5032874af4f1a26017e3c175ce413f45f8","original_commit_id":"6d2d8f5032874af4f1a26017e3c175ce413f45f8","user":{"login":"inducer","id":352067,"avatar_url":"https://avatars.githubusercontent.com/u/352067?v=3","gravatar_id":"","url":"https://api.github.com/users/inducer","html_url":"https://github.com/inducer","followers_url":"https://api.github.com/users/inducer/followers","following_url":"https://api.github.com/users/inducer/following{/other_user}","gists_url":"https://api.github.com/users/inducer/gists{/gist_id}","starred_url":"https://api.github.com/users/inducer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/inducer/subscriptions","organizations_url":"https://api.github.com/users/inducer/orgs","repos_url":"https://api.github.com/users/inducer/repos","events_url":"https://api.github.com/users/inducer/events{/privacy}","received_events_url":"https://api.github.com/users/inducer/received_events","type":"User","site_admin":false},"body":"Does this need to be duplicated?","created_at":"2016-06-27T16:39:14Z","updated_at":"2016-06-27T16:39:14Z","html_url":"https://github.com/inducer/relate/pull/207#discussion_r68611169","pull_request_url":"https://api.github.com/repos/inducer/relate/pulls/207","_links":{"self":{"href":"https://api.github.com/repos/inducer/relate/pulls/comments/68611169"},"html":{"href":"https://github.com/inducer/relate/pull/207#discussion_r68611169"},"pull_request":{"href":"https://api.github.com/repos/inducer/relate/pulls/207"}}},"pull_request":{"url":"https://api.github.com/repos/inducer/relate/pulls/207","id":69018559,"html_url":"https://github.com/inducer/relate/pull/207","diff_url":"https://github.com/inducer/relate/pull/207.diff","patch_url":"https://github.com/inducer/relate/pull/207.patch","issue_url":"https://api.github.com/repos/inducer/relate/issues/207","number":207,"state":"open","locked":false,"title":"add a latex macro to convert Tex code to <img> tag using dataURI.","user":{"login":"dzhuang","id":7379654,"avatar_url":"https://avatars.githubusercontent.com/u/7379654?v=3","gravatar_id":"","url":"https://api.github.com/users/dzhuang","html_url":"https://github.com/dzhuang","followers_url":"https://api.github.com/users/dzhuang/followers","following_url":"https://api.github.com/users/dzhuang/following{/other_user}","gists_url":"https://api.github.com/users/dzhuang/gists{/gist_id}","starred_url":"https://api.github.com/users/dzhuang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dzhuang/subscriptions","organizations_url":"https://api.github.com/users/dzhuang/orgs","repos_url":"https://api.github.com/users/dzhuang/repos","events_url":"https://api.github.com/users/dzhuang/events{/privacy}","received_events_url":"https://api.github.com/users/dzhuang/received_events","type":"User","site_admin":false},"body":"Requirement:\r\n - latex\r\n - dvipng\r\n - dvisvgm\r\n\r\nTexlive-full might contain all.\r\n\r\nUSAGE:\r\n\r\n```\r\n{% call latex() %}\r\nThe latex code\r\n{% endcall %}\r\n```\r\n\r\nOptional args:\r\n\r\n- ``output_dir``: <em>full path</em> or RELATE styled path of the file generated, default a directory named \"latex_image\" under MEDIA_ROOT.\r\n- ``tex_filename``: the based filename of the latex,  and image as well, if not set, use md5 of the full latex code\r\n- ``image_format``: the output format of the image, only png and svg are available, and svg is the default. If set png, code with tikz/pgf will still using svg.\r\n- ``tex_preamble``: the preamble other than what is provided in settings or default value in course.latex_utils. In the yml, it's value might be better to be set by using {% set foo %}{% endset %} block and the use ``tex_premable=foo`` as argument (same for ``tex_preamble_extra``). \r\n- ``tex_preamble_extra``: more packages or settings appended to default preamble.\r\n- ``overwrite``: regenerate image if it exists, default: False(recommended).\r\n- ``html_class_extra``: extra html class for the <img> tag, besides ``img-responsive``\r\n- ``alt``: alt attribute for the <img> tag. default value is the code in the call block.\r\n\r\nA brief example is provided in https://github.com/inducer/relate-sample/pull/4","created_at":"2016-05-05T14:57:04Z","updated_at":"2016-06-27T16:39:14Z","closed_at":null,"merged_at":null,"merge_commit_sha":"99278b20b7e96480bbe4e958aa81ec756f83d668","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/inducer/relate/pulls/207/commits","review_comments_url":"https://api.github.com/repos/inducer/relate/pulls/207/comments","review_comment_url":"https://api.github.com/repos/inducer/relate/pulls/comments{/number}","comments_url":"https://api.github.com/repos/inducer/relate/issues/207/comments","statuses_url":"https://api.github.com/repos/inducer/relate/statuses/6d2d8f5032874af4f1a26017e3c175ce413f45f8","head":{"label":"dzhuang:latex2img","ref":"latex2img","sha":"6d2d8f5032874af4f1a26017e3c175ce413f45f8","user":{"login":"dzhuang","id":7379654,"avatar_url":"https://avatars.githubusercontent.com/u/7379654?v=3","gravatar_id":"","url":"https://api.github.com/users/dzhuang","html_url":"https://github.com/dzhuang","followers_url":"https://api.github.com/users/dzhuang/followers","following_url":"https://api.github.com/users/dzhuang/following{/other_user}","gists_url":"https://api.github.com/users/dzhuang/gists{/gist_id}","starred_url":"https://api.github.com/users/dzhuang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dzhuang/subscriptions","organizations_url":"https://api.github.com/users/dzhuang/orgs","repos_url":"https://api.github.com/users/dzhuang/repos","events_url":"https://api.github.com/users/dzhuang/events{/privacy}","received_events_url":"https://api.github.com/users/dzhuang/received_events","type":"User","site_admin":false},"repo":{"id":39560547,"name":"relate","full_name":"dzhuang/relate","owner":{"login":"dzhuang","id":7379654,"avatar_url":"https://avatars.githubusercontent.com/u/7379654?v=3","gravatar_id":"","url":"https://api.github.com/users/dzhuang","html_url":"https://github.com/dzhuang","followers_url":"https://api.github.com/users/dzhuang/followers","following_url":"https://api.github.com/users/dzhuang/following{/other_user}","gists_url":"https://api.github.com/users/dzhuang/gists{/gist_id}","starred_url":"https://api.github.com/users/dzhuang/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dzhuang/subscriptions","organizations_url":"https://api.github.com/users/dzhuang/orgs","repos_url":"https://api.github.com/users/dzhuang/repos","events_url":"https://api.github.com/users/dzhuang/events{/privacy}","received_events_url":"https://api.github.com/users/dzhuang/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/dzhuang/relate","description":"RELATE is an Environment for Learning And TEaching","fork":true,"url":"https://api.github.com/repos/dzhuang/relate","forks_url":"https://api.github.com/repos/dzhuang/relate/forks","keys_url":"https://api.github.com/repos/dzhuang/relate/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dzhuang/relate/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dzhuang/relate/teams","hooks_url":"https://api.github.com/repos/dzhuang/relate/hooks","issue_events_url":"https://api.github.com/repos/dzhuang/relate/issues/events{/number}","events_url":"https://api.github.com/repos/dzhuang/relate/events","assignees_url":"https://api.github.com/repos/dzhuang/relate/assignees{/user}","branches_url":"https://api.github.com/repos/dzhuang/relate/branches{/branch}","tags_url":"https://api.github.com/repos/dzhuang/relate/tags","blobs_url":"https://api.github.com/repos/dzhuang/relate/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dzhuang/relate/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dzhuang/relate/git/refs{/sha}","trees_url":"https://api.github.com/repos/dzhuang/relate/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dzhuang/relate/statuses/{sha}","languages_url":"https://api.github.com/repos/dzhuang/relate/languages","stargazers_url":"https://api.github.com/repos/dzhuang/relate/stargazers","contributors_url":"https://api.github.com/repos/dzhuang/relate/contributors","subscribers_url":"https://api.github.com/repos/dzhuang/relate/subscribers","subscription_url":"https://api.github.com/repos/dzhuang/relate/subscription","commits_url":"https://api.github.com/repos/dzhuang/relate/commits{/sha}","git_commits_url":"https://api.github.com/repos/dzhuang/relate/git/commits{/sha}","comments_url":"https://api.github.com/repos/dzhuang/relate/comments{/number}","issue_comment_url":"https://api.github.com/repos/dzhuang/relate/issues/comments{/number}","contents_url":"https://api.github.com/repos/dzhuang/relate/contents/{+path}","compare_url":"https://api.github.com/repos/dzhuang/relate/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dzhuang/relate/merges","archive_url":"https://api.github.com/repos/dzhuang/relate/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dzhuang/relate/downloads","issues_url":"https://api.github.com/repos/dzhuang/relate/issues{/number}","pulls_url":"https://api.github.com/repos/dzhuang/relate/pulls{/number}","milestones_url":"https://api.github.com/repos/dzhuang/relate/milestones{/number}","notifications_url":"https://api.github.com/repos/dzhuang/relate/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dzhuang/relate/labels{/name}","releases_url":"https://api.github.com/repos/dzhuang/relate/releases{/id}","deployments_url":"https://api.github.com/repos/dzhuang/relate/deployments","created_at":"2015-07-23T10:16:11Z","updated_at":"2016-01-11T12:41:53Z","pushed_at":"2016-06-21T00:31:54Z","git_url":"git://github.com/dzhuang/relate.git","ssh_url":"git@github.com:dzhuang/relate.git","clone_url":"https://github.com/dzhuang/relate.git","svn_url":"https://github.com/dzhuang/relate","homepage":"http://documen.tician.de/relate","size":4355,"stargazers_count":0,"watchers_count":0,"language":"Python","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":"inducer:master","ref":"master","sha":"787fa6205d14b477f2da4feed372ac7b018935c1","user":{"login":"inducer","id":352067,"avatar_url":"https://avatars.githubusercontent.com/u/352067?v=3","gravatar_id":"","url":"https://api.github.com/users/inducer","html_url":"https://github.com/inducer","followers_url":"https://api.github.com/users/inducer/followers","following_url":"https://api.github.com/users/inducer/following{/other_user}","gists_url":"https://api.github.com/users/inducer/gists{/gist_id}","starred_url":"https://api.github.com/users/inducer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/inducer/subscriptions","organizations_url":"https://api.github.com/users/inducer/orgs","repos_url":"https://api.github.com/users/inducer/repos","events_url":"https://api.github.com/users/inducer/events{/privacy}","received_events_url":"https://api.github.com/users/inducer/received_events","type":"User","site_admin":false},"repo":{"id":20311659,"name":"relate","full_name":"inducer/relate","owner":{"login":"inducer","id":352067,"avatar_url":"https://avatars.githubusercontent.com/u/352067?v=3","gravatar_id":"","url":"https://api.github.com/users/inducer","html_url":"https://github.com/inducer","followers_url":"https://api.github.com/users/inducer/followers","following_url":"https://api.github.com/users/inducer/following{/other_user}","gists_url":"https://api.github.com/users/inducer/gists{/gist_id}","starred_url":"https://api.github.com/users/inducer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/inducer/subscriptions","organizations_url":"https://api.github.com/users/inducer/orgs","repos_url":"https://api.github.com/users/inducer/repos","events_url":"https://api.github.com/users/inducer/events{/privacy}","received_events_url":"https://api.github.com/users/inducer/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/inducer/relate","description":"RELATE is an Environment for Learning And TEaching","fork":false,"url":"https://api.github.com/repos/inducer/relate","forks_url":"https://api.github.com/repos/inducer/relate/forks","keys_url":"https://api.github.com/repos/inducer/relate/keys{/key_id}","collaborators_url":"https://api.github.com/repos/inducer/relate/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/inducer/relate/teams","hooks_url":"https://api.github.com/repos/inducer/relate/hooks","issue_events_url":"https://api.github.com/repos/inducer/relate/issues/events{/number}","events_url":"https://api.github.com/repos/inducer/relate/events","assignees_url":"https://api.github.com/repos/inducer/relate/assignees{/user}","branches_url":"https://api.github.com/repos/inducer/relate/branches{/branch}","tags_url":"https://api.github.com/repos/inducer/relate/tags","blobs_url":"https://api.github.com/repos/inducer/relate/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/inducer/relate/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/inducer/relate/git/refs{/sha}","trees_url":"https://api.github.com/repos/inducer/relate/git/trees{/sha}","statuses_url":"https://api.github.com/repos/inducer/relate/statuses/{sha}","languages_url":"https://api.github.com/repos/inducer/relate/languages","stargazers_url":"https://api.github.com/repos/inducer/relate/stargazers","contributors_url":"https://api.github.com/repos/inducer/relate/contributors","subscribers_url":"https://api.github.com/repos/inducer/relate/subscribers","subscription_url":"https://api.github.com/repos/inducer/relate/subscription","commits_url":"https://api.github.com/repos/inducer/relate/commits{/sha}","git_commits_url":"https://api.github.com/repos/inducer/relate/git/commits{/sha}","comments_url":"https://api.github.com/repos/inducer/relate/comments{/number}","issue_comment_url":"https://api.github.com/repos/inducer/relate/issues/comments{/number}","contents_url":"https://api.github.com/repos/inducer/relate/contents/{+path}","compare_url":"https://api.github.com/repos/inducer/relate/compare/{base}...{head}","merges_url":"https://api.github.com/repos/inducer/relate/merges","archive_url":"https://api.github.com/repos/inducer/relate/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/inducer/relate/downloads","issues_url":"https://api.github.com/repos/inducer/relate/issues{/number}","pulls_url":"https://api.github.com/repos/inducer/relate/pulls{/number}","milestones_url":"https://api.github.com/repos/inducer/relate/milestones{/number}","notifications_url":"https://api.github.com/repos/inducer/relate/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/inducer/relate/labels{/name}","releases_url":"https://api.github.com/repos/inducer/relate/releases{/id}","deployments_url":"https://api.github.com/repos/inducer/relate/deployments","created_at":"2014-05-29T23:39:42Z","updated_at":"2016-06-22T21:55:20Z","pushed_at":"2016-06-27T16:26:57Z","git_url":"git://github.com/inducer/relate.git","ssh_url":"git@github.com:inducer/relate.git","clone_url":"https://github.com/inducer/relate.git","svn_url":"https://github.com/inducer/relate","homepage":"http://documen.tician.de/relate","size":4382,"stargazers_count":72,"watchers_count":72,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":18,"mirror_url":null,"open_issues_count":46,"forks":18,"open_issues":46,"watchers":72,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/inducer/relate/pulls/207"},"html":{"href":"https://github.com/inducer/relate/pull/207"},"issue":{"href":"https://api.github.com/repos/inducer/relate/issues/207"},"comments":{"href":"https://api.github.com/repos/inducer/relate/issues/207/comments"},"review_comments":{"href":"https://api.github.com/repos/inducer/relate/pulls/207/comments"},"review_comment":{"href":"https://api.github.com/repos/inducer/relate/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/inducer/relate/pulls/207/commits"},"statuses":{"href":"https://api.github.com/repos/inducer/relate/statuses/6d2d8f5032874af4f1a26017e3c175ce413f45f8"}}}}
{"actor":{"display_login":"inducer"}}