{"id":1013,"date":"2016-01-17T12:14:39","date_gmt":"2016-01-17T01:14:39","guid":{"rendered":"https:\/\/www.gedda.info\/?p=1013"},"modified":"2016-01-17T12:14:39","modified_gmt":"2016-01-17T01:14:39","slug":"messing-with-markdown","status":"publish","type":"post","link":"https:\/\/www.gedda.info\/?p=1013","title":{"rendered":"Messing with Markdown"},"content":{"rendered":"<p>A few forums I&#8217;m on &#8211; most notably Github &#8211; support <a href=\"http:\/\/daringfireball.net\/projects\/markdown\/\" target=\"_blank\">Markdown<\/a> so I thought I&#8217;d take a look at how i can work with it.<\/p>\n<p>There&#8217;s a great little how to on <a href=\"https:\/\/www.maketecheasier.com\/convert-markdown-to-html-in-kate-text-editor\/\" target=\"_blank\">maketecheasier.com<\/a> that shows how to generate the HTML output right from the Kate text editor. Kate supports build profiles (which can just be a shell command) to make the code-to-build process seamless.<\/p>\n<p>First, install <a href=\"http:\/\/pandoc.org\/\" target=\"_blank\">Pandoc<\/a> to convert the Markdown markup to HTML and create a build profile to run a command to convert the working text file into a HTML one.<\/p>\n<pre>pandoc -r markdown -w html -o %f.html %f<\/pre>\n<p>Then hit your keybinding (in my case Ctrl+Alt+B) and voil\u00e0 the html file will be generated. You can also go a step further and spawn Firefox (or any other browser) to open the file so you can check the HTML output immediately.<\/p>\n<pre>pandoc -r markdown -w html -o %f.html %f &amp;&amp; \/usr\/bin\/firefox -new-window %f.html<\/pre>\n<p>Oh, and it&#8217;s worth mentioning that Kate supports Markdown syntax highlighting too.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-1014\" src=\"https:\/\/www.gedda.info\/wp-content\/uploads\/2016\/01\/kate_markdown_highlighting.png\" alt=\"kate_markdown_highlighting\" width=\"550\" height=\"415\" srcset=\"https:\/\/www.gedda.info\/wp-content\/uploads\/2016\/01\/kate_markdown_highlighting.png 550w, https:\/\/www.gedda.info\/wp-content\/uploads\/2016\/01\/kate_markdown_highlighting-300x226.png 300w\" sizes=\"auto, (max-width: 550px) 100vw, 550px\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>A few forums I&#8217;m on &#8211; most notably Github &#8211; support Markdown so I thought I&#8217;d take a look at how i can work&#8230;<\/p>\n","protected":false},"author":6,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[33,35],"tags":[163,162,161,144],"class_list":["post-1013","post","type-post","status-publish","format-standard","hentry","category-the-internet","category-tips-tricks","tag-html","tag-kate","tag-markdown","tag-webdesign"],"_links":{"self":[{"href":"https:\/\/www.gedda.info\/index.php?rest_route=\/wp\/v2\/posts\/1013","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.gedda.info\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.gedda.info\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.gedda.info\/index.php?rest_route=\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/www.gedda.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1013"}],"version-history":[{"count":1,"href":"https:\/\/www.gedda.info\/index.php?rest_route=\/wp\/v2\/posts\/1013\/revisions"}],"predecessor-version":[{"id":1015,"href":"https:\/\/www.gedda.info\/index.php?rest_route=\/wp\/v2\/posts\/1013\/revisions\/1015"}],"wp:attachment":[{"href":"https:\/\/www.gedda.info\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1013"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.gedda.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1013"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.gedda.info\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1013"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}