<?xml version='1.0' encoding='utf-8' ?>

<rss version='2.0' xmlns:lj='http://www.livejournal.org/rss/lj/1.0/' xmlns:atom10='http://www.w3.org/2005/Atom'>
<channel>
  <title>alexwlchan</title>
  <link>https://alexwlchan.dreamwidth.org/</link>
  <description>alexwlchan - Dreamwidth Studios</description>
  <lastBuildDate>Wed, 27 Feb 2019 20:03:23 GMT</lastBuildDate>
  <generator>LiveJournal / Dreamwidth Studios</generator>
  <lj:journal>alexwlchan</lj:journal>
  <lj:journaltype>personal</lj:journaltype>
  <image>
    <url>https://v2.dreamwidth.org/16166936/1512618</url>
    <title>alexwlchan</title>
    <link>https://alexwlchan.dreamwidth.org/</link>
    <width>100</width>
    <height>100</height>
  </image>

<item>
  <guid isPermaLink='true'>https://alexwlchan.dreamwidth.org/20342.html</guid>
  <pubDate>Wed, 27 Feb 2019 20:03:23 GMT</pubDate>
  <title>$ python post_entry.py</title>
  <link>https://alexwlchan.dreamwidth.org/20342.html</link>
  <description>&lt;p&gt;I continue to post regularly on Dreamwidth, so I&amp;#8217;ve extended &lt;a href=&quot;https://alexwlchan.dreamwidth.org/11682.html&quot;&gt;my previous script&lt;/a&gt; for turning Markdown into Dreamwidth HTML, and written another script that asks me a few questions about filters and title, then posts the entry for me.&lt;/p&gt;&lt;p&gt;Everything I&amp;#8217;ve posted in the last fortnight came through this script.&lt;/p&gt;&lt;p&gt;Code here if you&amp;#8217;re interested:&lt;/p&gt;&lt;p&gt;&lt;a href=&quot;https://github.com/alexwlchan/junkdrawer/blob/a2a5340a08d3c75f4caf31a89c4f9af2133eb6d4/services/dreamwidth/post_entry.py&quot;&gt;https://github.com/alexwlchan/junkdrawer/blob/a2a5340a08d3c75f4caf31a89c4f9af2133eb6d4/services/dreamwidth/post_entry.py&lt;/a&gt;&lt;/p&gt;&lt;p&gt;There are some weirdnesses in how the API handles filters when posting an entry, so if you want to use it I&amp;#8217;d test it on something innocuous first. As usual, code is in the &amp;#8220;junk drawer&amp;#8221; repo because it&amp;#8217;s not especially well-documented, and provided more as a &amp;#8220;here is a useful starting point for your own script&amp;#8221;, not a finished article.&lt;/p&gt;&lt;br /&gt;&lt;br /&gt;&lt;img src=&quot;https://www.dreamwidth.org/tools/commentcount?user=alexwlchan&amp;ditemid=20342&quot; width=&quot;30&quot; height=&quot;12&quot; alt=&quot;comment count unavailable&quot; style=&quot;vertical-align: middle;&quot;/&gt; comments</description>
  <comments>https://alexwlchan.dreamwidth.org/20342.html</comments>
  <category>meta</category>
  <category>non-venomous python</category>
  <lj:security>public</lj:security>
  <lj:reply-count>3</lj:reply-count>
</item>
<item>
  <guid isPermaLink='true'>https://alexwlchan.dreamwidth.org/14531.html</guid>
  <pubDate>Sun, 10 Feb 2019 10:03:30 GMT</pubDate>
  <title>$ python backup_posts.py</title>
  <link>https://alexwlchan.dreamwidth.org/14531.html</link>
  <description>&lt;p&gt;Now I&apos;m posting more on Dreamwidth, I want a way to keep an offline copy of everything I&apos;ve written here. (I am almost hoarder-like in my desire to keep copies of everything I&amp;rsquo;ve written.)&lt;/p&gt;&lt;p&gt;Hooray for sites with sensible APIs! Dreamwidth has an XML-RPC API, so I&apos;ve written a short script that grabs a copy of all my posts. It saves a JSON file with all the data from the API, and an HTML file for convenience (and grep).&lt;/p&gt;&lt;p&gt;If Python is your thing and you&apos;d find it useful (or just want another example of using the Dreamwidth API), code is on GitHub:&lt;/p&gt;&lt;p&gt;&lt;a href=&quot;https://github.com/alexwlchan/junkdrawer/blob/55b32a7896915c4d8a4246279a718e69dc61df8f/services/dreamwidth/backup_posts.py&quot;&gt;https://github.com/alexwlchan/junkdrawer/blob/55b32a7896915c4d8a4246279a718e69dc61df8f/services/dreamwidth/backup_posts.py&lt;/a&gt;&lt;/p&gt;&lt;p&gt;(Usage instructions in the docstring; whole repo is MIT.)&lt;/p&gt;&lt;br /&gt;&lt;br /&gt;&lt;img src=&quot;https://www.dreamwidth.org/tools/commentcount?user=alexwlchan&amp;ditemid=14531&quot; width=&quot;30&quot; height=&quot;12&quot; alt=&quot;comment count unavailable&quot; style=&quot;vertical-align: middle;&quot;/&gt; comments</description>
  <comments>https://alexwlchan.dreamwidth.org/14531.html</comments>
  <category>non-venomous python</category>
  <category>meta</category>
  <lj:security>public</lj:security>
  <lj:reply-count>1</lj:reply-count>
</item>
<item>
  <guid isPermaLink='true'>https://alexwlchan.dreamwidth.org/11682.html</guid>
  <pubDate>Fri, 01 Feb 2019 22:30:13 GMT</pubDate>
  <title>$ python markdownify.py</title>
  <link>https://alexwlchan.dreamwidth.org/11682.html</link>
  <description>&lt;p&gt;I’ve been posting a lot more on Dreamwidth recently (although mostly private/filtered entries).&lt;/p&gt;&lt;p&gt;I&apos;ve written a short script that lets me write posts in Markdown, then just upload the finished HTML to the Dreamwidth post editor. I find Markdown easier to write.&lt;/p&gt;&lt;p&gt;If Python is your thing and you&apos;d find it useful, code available here:&lt;/p&gt;&lt;p&gt;&lt;a href=&quot;https://github.com/alexwlchan/junkdrawer/blob/b25c2d0cdeebab8b0335fc5717081b1154e0cf09/services/dreamwidth/markdownify.py&quot;&gt;https://github.com/alexwlchan/junkdrawer/blob/b25c2d0cdeebab8b0335fc5717081b1154e0cf09/services/dreamwidth/markdownify.py&lt;/a&gt;&lt;/p&gt;&lt;p&gt;(Usage instructions in the docstring; whole repo is MIT.)&lt;/p&gt;&lt;br /&gt;&lt;br /&gt;&lt;img src=&quot;https://www.dreamwidth.org/tools/commentcount?user=alexwlchan&amp;ditemid=11682&quot; width=&quot;30&quot; height=&quot;12&quot; alt=&quot;comment count unavailable&quot; style=&quot;vertical-align: middle;&quot;/&gt; comments</description>
  <comments>https://alexwlchan.dreamwidth.org/11682.html</comments>
  <category>non-venomous python</category>
  <category>meta</category>
  <lj:security>public</lj:security>
  <lj:reply-count>0</lj:reply-count>
</item>
</channel>
</rss>
