{"action":"reopened","issue":{"url":"https://api.github.com/repos/mercari/tfnotify/issues/5","repository_url":"https://api.github.com/repos/mercari/tfnotify","labels_url":"https://api.github.com/repos/mercari/tfnotify/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/mercari/tfnotify/issues/5/comments","events_url":"https://api.github.com/repos/mercari/tfnotify/issues/5/events","html_url":"https://github.com/mercari/tfnotify/issues/5","id":317949917,"node_id":"MDU6SXNzdWUzMTc5NDk5MTc=","number":5,"title":"terraform plan/apply result in GitHub comment is parsed as Markdown","user":{"login":"dtan4","id":680124,"node_id":"MDQ6VXNlcjY4MDEyNA==","avatar_url":"https://avatars3.githubusercontent.com/u/680124?v=4","gravatar_id":"","url":"https://api.github.com/users/dtan4","html_url":"https://github.com/dtan4","followers_url":"https://api.github.com/users/dtan4/followers","following_url":"https://api.github.com/users/dtan4/following{/other_user}","gists_url":"https://api.github.com/users/dtan4/gists{/gist_id}","starred_url":"https://api.github.com/users/dtan4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dtan4/subscriptions","organizations_url":"https://api.github.com/users/dtan4/orgs","repos_url":"https://api.github.com/users/dtan4/repos","events_url":"https://api.github.com/users/dtan4/events{/privacy}","received_events_url":"https://api.github.com/users/dtan4/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-04-26T09:35:09Z","updated_at":"2018-07-03T02:02:15Z","closed_at":null,"author_association":"COLLABORATOR","body":"## WHAT\r\n\r\nMake `terraform plan|apply` result output print in GitHub comment as it is, not to render as Markdown text.\r\n\r\n## WHY\r\n\r\nCurrently `terraform plan|apply` result notified as GitHub comment is parsed as Markdown text, not as plain text.\r\nThis causes transformation from some formatted text, e.g. plugin list, resources to diff and separator line, to HTML lists or separators.\r\n\r\nPlease look at the below examples.\r\n\r\n### enclose with `<pre><code>` (current state)\r\n\r\n<details><summary>Details (Click me)</summary>\r\n<pre><code>\r\n\r\nInitializing provider plugins...\r\n- Checking for available provider plugins on https://releases.hashicorp.com...\r\n- Downloading plugin for provider &#34;pagerduty&#34; (1.1.0)...\r\n- Downloading plugin for provider &#34;aws&#34; (1.16.0)...\r\n- Downloading plugin for provider &#34;google&#34; (1.10.0)...\r\n\r\nThe following providers do not have any version constraints in configuration,\r\nso the latest version was installed.\r\n\r\nTo prevent automatic upgrades to new major versions that may contain breaking\r\nchanges, it is recommended to add version = &#34;...&#34; constraints to the\r\ncorresponding provider blocks in configuration, with the constraint strings\r\nsuggested below.\r\n\r\n* provider.aws: version = &#34;~&gt; 1.16&#34;\r\n* provider.google: version = &#34;~&gt; 1.10&#34;\r\n* provider.pagerduty: version = &#34;~&gt; 1.1&#34;\r\n\r\nTerraform has been successfully initialized!\r\n\r\n------------------------------------------------------------------------\r\n\r\nAn execution plan has been generated and is shown below.\r\nResource actions are indicated with the following symbols:\r\n  ~ update in-place\r\n\r\nPlan: 0 to add, 2 to change, 0 to destroy.\r\n\r\n------------------------------------------------------------------------\r\n\r\nNote: You didn&#39;t specify an &#34;-out&#34; parameter to save this plan, so Terraform\r\ncan&#39;t guarantee that exactly these actions will be performed if\r\n&#34;terraform apply&#34; is subsequently run.\r\n</code></pre></details>\r\n\r\n### enclose with backquotes\r\n\r\nSince using the same body with above, HTML character entities are appeared as it is.\r\n\r\n<details><summary>Details (Click me)</summary>\r\n\r\n```\r\n\r\nInitializing provider plugins...\r\n- Checking for available provider plugins on https://releases.hashicorp.com...\r\n- Downloading plugin for provider &#34;pagerduty&#34; (1.1.0)...\r\n- Downloading plugin for provider &#34;aws&#34; (1.16.0)...\r\n- Downloading plugin for provider &#34;google&#34; (1.10.0)...\r\n\r\nThe following providers do not have any version constraints in configuration,\r\nso the latest version was installed.\r\n\r\nTo prevent automatic upgrades to new major versions that may contain breaking\r\nchanges, it is recommended to add version = &#34;...&#34; constraints to the\r\ncorresponding provider blocks in configuration, with the constraint strings\r\nsuggested below.\r\n\r\n* provider.aws: version = &#34;~&gt; 1.16&#34;\r\n* provider.google: version = &#34;~&gt; 1.10&#34;\r\n* provider.pagerduty: version = &#34;~&gt; 1.1&#34;\r\n\r\nTerraform has been successfully initialized!\r\n\r\n------------------------------------------------------------------------\r\n\r\nAn execution plan has been generated and is shown below.\r\nResource actions are indicated with the following symbols:\r\n  ~ update in-place\r\n\r\nPlan: 0 to add, 2 to change, 0 to destroy.\r\n\r\n------------------------------------------------------------------------\r\n\r\nNote: You didn&#39;t specify an &#34;-out&#34; parameter to save this plan, so Terraform\r\ncan&#39;t guarantee that exactly these actions will be performed if\r\n&#34;terraform apply&#34; is subsequently run.\r\n```\r\n\r\n</details>\r\n\r\n---\r\n\r\nOne solution is using [triple backquotes](https://help.github.com/articles/creating-and-highlighting-code-blocks/#fenced-code-blocks). I prefer this solution.\r\nAnother solution is replacing all special characters to HTML character entities."}}
{"actor":{"display_login":"dtan4"}}