Thomas Dy 7 rokov pred
rodič
commit
89e15caa1a
35 zmenil súbory, kde vykonal 1179 pridanie a 2103 odobranie
  1. 9 1
      output/assets/css/theme.css
  2. 25 119
      output/index.html
  3. 1 1
      output/page/1.html
  4. 115 52
      output/page/2.html
  5. 54 93
      output/page/3.html
  6. 107 40
      output/page/4.html
  7. 113 0
      output/page/5.html
  8. 83 0
      output/pages.html
  9. 115 0
      output/pages/projects.html
  10. 25 0
      output/pages/rss.xml
  11. 3 2
      output/posts.html
  12. 9 16
      output/posts/audventure.html
  13. 11 18
      output/posts/cloudflare-shenanigans.html
  14. 15 22
      output/posts/console-keymap-switching.html
  15. 11 18
      output/posts/elevation-data-in-otp.html
  16. 13 20
      output/posts/fare-data.html
  17. 9 16
      output/posts/geocoding-services.html
  18. 9 16
      output/posts/graphserver.html
  19. 19 26
      output/posts/gtfs-editor.html
  20. 11 18
      output/posts/haproxy-charset.html
  21. 11 18
      output/posts/highways-in-otp.html
  22. 9 16
      output/posts/is-my-terminal-window-active.html
  23. 13 20
      output/posts/jeep-and-bus-schedules.html
  24. 9 16
      output/posts/jeepney-and-bus-routes.html
  25. 9 16
      output/posts/one-bus-or-maybe-jeep-away.html
  26. 9 16
      output/posts/open-trip-planner.html
  27. 19 26
      output/posts/openpreppad.html
  28. 9 16
      output/posts/philippine-transit-app-challenge.html
  29. 9 16
      output/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html
  30. 116 691
      output/posts/rss.xml
  31. 21 28
      output/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html
  32. 9 16
      output/posts/transit-wand.html
  33. 127 692
      output/rss.xml
  34. 49 36
      output/sitemap.xml
  35. 3 2
      output/tags.html

+ 9 - 1
output/assets/css/theme.css

@@ -46,7 +46,7 @@ a {
 
 code, pre {
 	font-family: Monaco, Menlo, Consolas, monospace;
-	font-size: 75%;
+	font-size: 90%;
 	hyphens: none;
 	-moz-hyphens: none;
 }
@@ -57,6 +57,10 @@ code {
 	border-radius: 0.25em;
 }
 
+.highlight code {
+	background: none;
+}
+
 .highlight, .code {
 	padding: 0em 0.5em;
 	border-radius: 0.25em;
@@ -336,3 +340,7 @@ h1 small {
   display: block;
   margin-top: 8px;
 }
+
+#isso-thread {
+  font-size: 80%;
+}

+ 25 - 119
output/index.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -139,7 +140,7 @@ want to contribute music or sound effects, I&rsquo;d gladly appreciate it.</p>
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2017-11-19">2017-11-19</time></small>
-		| <small class="commentline"><a href="/posts/audventure.html#disqus_thread" data-disqus-identifier="cache/posts/audventure.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/audventure.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -186,7 +187,7 @@ to get my bluetooth mouse connected on Linux. The main thing I used then was
 started there.</p>
 
 <p>I started up <code>bluetoothctl</code> and turned on the Prep Pad. And it showed up!</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[bluetooth]# power on
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[bluetooth]# power on
 [CHG] Controller ... Class: 0x00010c
 Changing power on succeeded
 [CHG] Controller ... Powered: yes
@@ -195,15 +196,15 @@ Discovery started
 [CHG] Device 1C:BA:8C:21:7C:BB RSSI: -51
 [CHG] Device 1C:BA:8C:21:7C:BB Name: CHSLEEV_00
 [CHG] Device 1C:BA:8C:21:7C:BB Alias: CHSLEEV_00
-</pre></div>
+</code></pre></div>
 
 <p>I then connected to it, which was surprisingly easy.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[bluetooth]# connect 1C:BA:8C:21:7C:BB
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[bluetooth]# connect 1C:BA:8C:21:7C:BB
 Attempting to connect to 1C:BA:8C:21:7C:BB
 [CHG] Device 1C:BA:8C:21:7C:BB Connected: yes
 [CHG] Device 1C:BA:8C:21:7C:BB Name: CH BTScale_00
 [CHG] Device 1C:BA:8C:21:7C:BB Alias: CH BTScale_00
-</pre></div>
+</code></pre></div>
 
 <p>Now normally, when you turn the device on, the green light flashes occasionally.
 Once I connected to it, the green light stayed on permanently. Clearly, I was
@@ -213,7 +214,7 @@ those things were at that point.</p>
 <p>After a lot of poking around, I could check the general device information. You
 could get the hardware, software and firmware version. There&rsquo;s also the device
 serial number which was nowhere on the actual physical device.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
 [CH BTScale_00:/service0010/char0017]# attribute-info
 Characteristic - Firmware Revision String
 	UUID: 00002a26-0000-1000-8000-00805f9b34fb
@@ -235,12 +236,12 @@ Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x00
   31 2e 31 33 41 00                                1.13A.
 [CH BTScale_00:/service0010/char0017]#
-</pre></div>
+</code></pre></div>
 
 <p>There was also a service which contained Accel Enable, Accel Range, Accel
 X-Coordinate, Accel Y-Coordinate, and Accel Z-Coordinate. I guess it stands for
 accelerometer, which is probably what it uses to weigh things.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
 [CH BTScale_00:/service0023/char0024/desc0026]# read
 Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x41
@@ -256,14 +257,14 @@ Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/de
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x6c
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x65
   41 63 63 65 6c 20 45 6e 61 62 6c 65              Accel Enable
-</pre></div>
+</code></pre></div>
 
 <p>I couldn&rsquo;t read from any of the Accel Coordinates. It kept saying permission
 denied. I could however, notify on them. But that didn&rsquo;t yield anything as well.
 What I <em>could</em> read was Accel Enable, which was set to 00. I guess that means it
 was off. After writing 01 to Accel Enable, I found I could get values out of
 Accel X-Coordinate! Also, the green LED which was permanently on turned off.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
 [CH BTScale_00:/service0023/char0024]# write 01
 Attempting to write /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
 [CH BTScale_00:/service0023/char0024]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a
@@ -282,7 +283,7 @@ Notify started
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0xa3
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x02
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x00
-</pre></div>
+</code></pre></div>
 
 <p>I tried pressing the scale down a few times, and the values changed accordingly.
 Now, I just had to figure out how to convert the values into grams. It looked
@@ -312,7 +313,7 @@ are good, I might not even need to finish it.</p>
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2017-01-15">2017-01-15</time></small>
-		| <small class="commentline"><a href="/posts/openpreppad.html#disqus_thread" data-disqus-identifier="cache/posts/.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/openpreppad.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -330,16 +331,16 @@ are good, I might not even need to finish it.</p>
 <p>Being lazy, we usually just correct this at the reverse proxy side. It&rsquo;s trivial to do in nginx. You just need to add <code>charset utf-8;</code> to your configuration and you&rsquo;re good. For haproxy though, I couldn&rsquo;t readily find a solution for it and had to go through the docs to see what I could do.</p>
 
 <p>After a bit of experimenting, I had success with this:</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span># set content-type to utf-8 if not already
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span># set content-type to utf-8 if not already
 acl has_charset hdr_sub(content-type) -i charset=
 rspirep (Content-Type.*) \1;\ charset=utf-8 unless has_charset
-</pre></div>
+</code></pre></div>
 
 <p>This is probably not the best way to do it. Arguably, we should just fix our services to have the correct <code>Content-Type</code> in the first place, but I can do that some other time.</p>
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2016-06-24">2016-06-24</time></small>
-		| <small class="commentline"><a href="/posts/haproxy-charset.html#disqus_thread" data-disqus-identifier="cache/posts/haproxy-charset.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/haproxy-charset.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -361,7 +362,7 @@ rspirep (Content-Type.*) \1;\ charset=utf-8 unless has_charset
 <p>Since Cloudflare was essentially just a giant reverse proxy, theoretically there should be no distinction between one IP address from another. The specific IP we get is probably just for load balancing. So we tried accessing the IPs in the range directly and just setting the Host header and it worked! But we get SSL errors because the IP itself doesn&rsquo;t have its own certificate.</p>
 
 <p>After more testing, we figured out that you could actually use any Cloudflare backed domain so long as we properly set the Host header. We just needed to find one still in the old range. Coincidentally, 4chan.org was. Which led to this wonderful commit</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>commit 123456789abcdef
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-diff" data-lang="diff"><span></span>commit 123456789abcdef
 Author: ~~~~~~
 Date:   ~~~~~~
 
@@ -390,7 +391,7 @@ Date:   ~~~~~~
 
                 if(data == null) {
                         data = new ArrayList&lt;NameValuePair&gt;();
-</pre></div>
+</code></pre></div>
 
 <p>Eventually, we did decide to just abandon Cloudflare for the server. We probably weren&rsquo;t going to be the target of a DDOS or anything. This also allowed us to do more secure things like pinning the server certificate in the application itself. Clearly, this is what we should have just done in the first place, but at the time we just wanted a stopgap solution.</p>
 
@@ -398,105 +399,7 @@ Date:   ~~~~~~
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2015-12-25">2015-12-25</time></small>
-		| <small class="commentline"><a href="/posts/cloudflare-shenanigans.html#disqus_thread" data-disqus-identifier="cache/posts/cloudflare-shenanigans.html">Comments</a></small>
-	</article>
-	</article>
-	
-	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
-		<header>
-			<h1 class="p-name entry-title" itemprop="headline">
-				<a href="/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html" class="u-url">TiddlyWiki in the Sky (or TiddlyWeb for TW5)</a>
-			</h1>
-		</header>
-		<div class="e-content entry-content">
-			
-
-<p>I&rsquo;ve always liked <a href="http://tiddlywiki.com">TiddlyWiki</a>. Back when it first came out, it was really amazing. A wiki all in one file, that worked in the browser. It didn&rsquo;t need a backend, it would just save itself as an all new HTML file with all your posts inside. I&rsquo;ve used it a lot over the years, as a personal wiki/journal and a class notebook. I even had a blog with it at one point using one of the server-side forks.</p>
-
-<p>Now, there&rsquo;s TiddlyWiki5 which is a rewrite of the original TiddlyWiki that looks a whole lot snazzier, and I assume has better architecture overall. It also has experimental support for all the server-side platforms (particularly TiddlyWeb) that have cropped up.</p>
-
-<p>If you&rsquo;re just looking for a simple server setup for TiddlyWiki5, it has native support for that on its own. There&rsquo;s plenty of documentation on the site. But if you&rsquo;re looking for more advanced features (like storing your posts in git or a database), then you&rsquo;ll need to use it with TiddlyWeb. The problem is that most of the documentation for TiddlyWeb still refers to the old TiddlyWiki.</p>
-
-<p>To support TiddlyWiki5, we&rsquo;ll need a version of the wiki which has the TiddlyWeb plugin already installed and configured. After that, some tweaking is necessary to get TiddlyWeb to provide what the wiki requires.</p>
-
-<h2 id="setting-up-tiddlywiki">Setting Up TiddlyWiki</h2>
-
-<p>TiddlyWiki5 provides a command line tool via <code>npm</code> that allows building custom versions of the wiki. In fact, it comes with templates, called &ldquo;editions&rdquo;, that we can use for our setup. Assuming you already have it installed, create the wiki using</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>tiddlywiki mywiki --init tw5tank          <span style="color: #408080; font-style: italic"># create wiki from template</span>
-</pre></div>
-
-<p>This creates a wiki intended for use with <a href="https://tank.peermore.com/">Tank</a>, which is built on top of TiddlyWeb. From here, you should look in <code>mywiki/tiddlers/system</code> which contain the entries for <code>SiteTitle</code>, <code>SiteSubtitle</code>, <code>DefaultTiddlers</code>, and <code>tiddlyweb-host</code>. The first 3 should be configured however you want. These are necessary because they&rsquo;re needed before the wiki can load them from the server. <code>tiddlyweb-host</code> contains the location of the TiddlyWeb server, this should be <code>http://localhost:8080/</code> if you&rsquo;re just testing locally. With everything configured, you can build the new wiki by running</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>tiddlywiki mywiki --build
-</pre></div>
-
-<p>This will output the wiki to <code>mywiki/output/tw5tank.html</code>. You can now serve it using your favorite local webserver, like <code>python -m http.server</code>.</p>
-
-<h2 id="setting-up-tiddlyweb">Setting Up TiddlyWeb</h2>
-
-<p>The TiddlyWeb tutorial recommends using <code>tiddlywebwiki</code> which has all the plugins setup for a nice wiki instance for the old TiddlyWiki. It has a lot of features that aren&rsquo;t really needed, so we won&rsquo;t go with that. So first, we&rsquo;ll need to install TiddlyWeb and any plugins we might want to use.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>pip install tiddlyweb tiddlywebplugins.status tiddlywebplugins.cherrypy tiddlywebplugins.cors
-</pre></div>
-
-<p>Next, we&rsquo;ll need the tiddlyweb configuration in <code>tiddlywebconfig.py</code></p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #408080; font-style: italic"># A basic configuration.</span>
-<span style="color: #408080; font-style: italic"># `pydoc tiddlyweb.config` for details on configuration items.</span>
-
-<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">tiddlywebplugins.status</span>
-
-config <span style="color: #666666">=</span> {
-    <span style="color: #BA2121">&#39;system_plugins&#39;</span>: [<span style="color: #BA2121">&#39;tiddlywebplugins.status&#39;</span>, <span style="color: #BA2121">&#39;tiddlywebplugins.cors&#39;</span>],
-    <span style="color: #BA2121">&#39;secret&#39;</span>: <span style="color: #BA2121">&#39;36c98d6d14618c79f0ed2d49cd1b9e272d8d4bd0&#39;</span>,
-    <span style="color: #BA2121">&#39;wsgi_server&#39;</span>: <span style="color: #BA2121">&#39;tiddlywebplugins.cherrypy&#39;</span>,
-    <span style="color: #BA2121">&#39;cors.enable_non_simple&#39;</span>: <span style="color: #008000">True</span>
-}
-
-original_gather_data <span style="color: #666666">=</span> tiddlywebplugins<span style="color: #666666">.</span>status<span style="color: #666666">.</span>_gather_data
-
-<span style="color: #008000; font-weight: bold">def</span> <span style="color: #0000FF">_status_gather_data</span>(environ):
-    data <span style="color: #666666">=</span> original_gather_data(environ)
-    data[<span style="color: #BA2121">&#39;space&#39;</span>] <span style="color: #666666">=</span> {<span style="color: #BA2121">&#39;recipe&#39;</span>: <span style="color: #BA2121">&#39;default&#39;</span>}
-    <span style="color: #008000; font-weight: bold">return</span> data
-
-tiddlywebplugins<span style="color: #666666">.</span>status<span style="color: #666666">.</span>_gather_data <span style="color: #666666">=</span> _status_gather_data
-</pre></div>
-
-<p>The tweaks involved are:</p>
-
-<ul>
-<li>using the status plugin which the wiki requires</li>
-<li>monkeypatching the status plugin for the wiki to use the correct &ldquo;recipe&rdquo;</li>
-<li>using cherrypy server instead of the buggy default one</li>
-<li>using cors since we&rsquo;re not hosting the wiki itself on the same server</li>
-</ul>
-
-<p>With that, we just need to create the store that will hold our data</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>twanager recipe default <span style="color: #BA2121">&lt;&lt;EOF</span>
-<span style="color: #BA2121">desc: standard TiddlyWebWiki environment</span>
-<span style="color: #BA2121">policy: {&quot;read&quot;: [], &quot;create&quot;: [], &quot;manage&quot;: [&quot;R:ADMIN&quot;], &quot;accept&quot;: [], &quot;write&quot;: [&quot;R:ADMIN&quot;], &quot;owner&quot;: &quot;administrator&quot;, &quot;delete&quot;: [&quot;R:ADMIN&quot;]}</span>
-
-<span style="color: #BA2121">/bags/default/tiddlers</span>
-<span style="color: #BA2121">EOF</span>
-
-twanager bag default <span style="color: #BA2121">&lt;&lt;EOF</span>
-<span style="color: #BA2121">{&quot;policy&quot;: {&quot;read&quot;: [], &quot;create&quot;: [], &quot;manage&quot;: [&quot;R:ADMIN&quot;], &quot;accept&quot;: [], &quot;write&quot;: [], &quot;owner&quot;: &quot;administrator&quot;, &quot;delete&quot;: []}}</span>
-<span style="color: #BA2121">EOF</span>
-</pre></div>
-
-<p>Finally, we can start the TiddlyWeb server</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>twanager server
-</pre></div>
-
-<h2 id="putting-it-all-together">Putting it all together</h2>
-
-<p>Once you have the TiddlyWeb server running, you can just go to wherever you&rsquo;re hosting the wiki html and it should work. You can try creating some posts, and the check mark on the sidebar should be red for a while and then turn black. Once that&rsquo;s done it&rsquo;s saved. You can refresh your browser and your posts should still be there.</p>
-
-<p>At this point, you can start customizing your TiddlyWeb instance, by changing your store to something like a database, or adding authorization. You can also tweak the server setup so you won&rsquo;t need CORS anymore.</p>
-
-<p>TiddlyWiki5 is still relatively new. I hope that eventually, support for server-side and the plugin ecosystem grows to be as great as the old TiddlyWiki.</p>
-
-		</div>
-		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2015-12-24">2015-12-24</time></small>
-		| <small class="commentline"><a href="/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html#disqus_thread" data-disqus-identifier="cache/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/cloudflare-shenanigans.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -519,7 +422,7 @@ twanager bag default <span style="color: #BA2121">&lt;&lt;EOF</span>
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 
@@ -543,7 +446,10 @@ easter_egg.load();
 </script>
 
 
-<script id="dsq-count-scr" type="text/javascript" src="//pleasantprog.disqus.com/count.js" async></script>
+<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	src="https://isso.pleasantprogrammer.com/js/count.min.js">
+</script>
 
 
 </body>

+ 1 - 1
output/page/1.html

@@ -1 +1 @@
-<!DOCTYPE html><html><head><title>http://pleasantprogrammer.com/</title><link rel="canonical" href="http://pleasantprogrammer.com/"/><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0; url=http://pleasantprogrammer.com/" /></head></html>
+<!DOCTYPE html><html><head><title>https://pleasantprogrammer.com/</title><link rel="canonical" href="https://pleasantprogrammer.com/"/><meta name="robots" content="noindex"><meta http-equiv="content-type" content="text/html; charset=utf-8" /><meta http-equiv="refresh" content="0; url=https://pleasantprogrammer.com/" /></head></html>

+ 115 - 52
output/page/2.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -35,6 +36,104 @@
 <main id="content" role="main">
 <div class="postindex">
 	
+	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
+		<header>
+			<h1 class="p-name entry-title" itemprop="headline">
+				<a href="/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html" class="u-url">TiddlyWiki in the Sky (or TiddlyWeb for TW5)</a>
+			</h1>
+		</header>
+		<div class="e-content entry-content">
+			
+
+<p>I&rsquo;ve always liked <a href="http://tiddlywiki.com">TiddlyWiki</a>. Back when it first came out, it was really amazing. A wiki all in one file, that worked in the browser. It didn&rsquo;t need a backend, it would just save itself as an all new HTML file with all your posts inside. I&rsquo;ve used it a lot over the years, as a personal wiki/journal and a class notebook. I even had a blog with it at one point using one of the server-side forks.</p>
+
+<p>Now, there&rsquo;s TiddlyWiki5 which is a rewrite of the original TiddlyWiki that looks a whole lot snazzier, and I assume has better architecture overall. It also has experimental support for all the server-side platforms (particularly TiddlyWeb) that have cropped up.</p>
+
+<p>If you&rsquo;re just looking for a simple server setup for TiddlyWiki5, it has native support for that on its own. There&rsquo;s plenty of documentation on the site. But if you&rsquo;re looking for more advanced features (like storing your posts in git or a database), then you&rsquo;ll need to use it with TiddlyWeb. The problem is that most of the documentation for TiddlyWeb still refers to the old TiddlyWiki.</p>
+
+<p>To support TiddlyWiki5, we&rsquo;ll need a version of the wiki which has the TiddlyWeb plugin already installed and configured. After that, some tweaking is necessary to get TiddlyWeb to provide what the wiki requires.</p>
+
+<h2 id="setting-up-tiddlywiki">Setting Up TiddlyWiki</h2>
+
+<p>TiddlyWiki5 provides a command line tool via <code>npm</code> that allows building custom versions of the wiki. In fact, it comes with templates, called &ldquo;editions&rdquo;, that we can use for our setup. Assuming you already have it installed, create the wiki using</p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>tiddlywiki mywiki --init tw5tank          <span style="color: #408080; font-style: italic"># create wiki from template</span>
+</code></pre></div>
+
+<p>This creates a wiki intended for use with <a href="https://tank.peermore.com/">Tank</a>, which is built on top of TiddlyWeb. From here, you should look in <code>mywiki/tiddlers/system</code> which contain the entries for <code>SiteTitle</code>, <code>SiteSubtitle</code>, <code>DefaultTiddlers</code>, and <code>tiddlyweb-host</code>. The first 3 should be configured however you want. These are necessary because they&rsquo;re needed before the wiki can load them from the server. <code>tiddlyweb-host</code> contains the location of the TiddlyWeb server, this should be <code>http://localhost:8080/</code> if you&rsquo;re just testing locally. With everything configured, you can build the new wiki by running</p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>tiddlywiki mywiki --build
+</code></pre></div>
+
+<p>This will output the wiki to <code>mywiki/output/tw5tank.html</code>. You can now serve it using your favorite local webserver, like <code>python -m http.server</code>.</p>
+
+<h2 id="setting-up-tiddlyweb">Setting Up TiddlyWeb</h2>
+
+<p>The TiddlyWeb tutorial recommends using <code>tiddlywebwiki</code> which has all the plugins setup for a nice wiki instance for the old TiddlyWiki. It has a lot of features that aren&rsquo;t really needed, so we won&rsquo;t go with that. So first, we&rsquo;ll need to install TiddlyWeb and any plugins we might want to use.</p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>pip install tiddlyweb tiddlywebplugins.status tiddlywebplugins.cherrypy tiddlywebplugins.cors
+</code></pre></div>
+
+<p>Next, we&rsquo;ll need the tiddlyweb configuration in <code>tiddlywebconfig.py</code></p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-python" data-lang="python"><span></span><span style="color: #408080; font-style: italic"># A basic configuration.</span>
+<span style="color: #408080; font-style: italic"># `pydoc tiddlyweb.config` for details on configuration items.</span>
+
+<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">tiddlywebplugins.status</span>
+
+config <span style="color: #666666">=</span> {
+    <span style="color: #BA2121">&#39;system_plugins&#39;</span>: [<span style="color: #BA2121">&#39;tiddlywebplugins.status&#39;</span>, <span style="color: #BA2121">&#39;tiddlywebplugins.cors&#39;</span>],
+    <span style="color: #BA2121">&#39;secret&#39;</span>: <span style="color: #BA2121">&#39;36c98d6d14618c79f0ed2d49cd1b9e272d8d4bd0&#39;</span>,
+    <span style="color: #BA2121">&#39;wsgi_server&#39;</span>: <span style="color: #BA2121">&#39;tiddlywebplugins.cherrypy&#39;</span>,
+    <span style="color: #BA2121">&#39;cors.enable_non_simple&#39;</span>: <span style="color: #008000">True</span>
+}
+
+original_gather_data <span style="color: #666666">=</span> tiddlywebplugins<span style="color: #666666">.</span>status<span style="color: #666666">.</span>_gather_data
+
+<span style="color: #008000; font-weight: bold">def</span> <span style="color: #0000FF">_status_gather_data</span>(environ):
+    data <span style="color: #666666">=</span> original_gather_data(environ)
+    data[<span style="color: #BA2121">&#39;space&#39;</span>] <span style="color: #666666">=</span> {<span style="color: #BA2121">&#39;recipe&#39;</span>: <span style="color: #BA2121">&#39;default&#39;</span>}
+    <span style="color: #008000; font-weight: bold">return</span> data
+
+tiddlywebplugins<span style="color: #666666">.</span>status<span style="color: #666666">.</span>_gather_data <span style="color: #666666">=</span> _status_gather_data
+</code></pre></div>
+
+<p>The tweaks involved are:</p>
+
+<ul>
+<li>using the status plugin which the wiki requires</li>
+<li>monkeypatching the status plugin for the wiki to use the correct &ldquo;recipe&rdquo;</li>
+<li>using cherrypy server instead of the buggy default one</li>
+<li>using cors since we&rsquo;re not hosting the wiki itself on the same server</li>
+</ul>
+
+<p>With that, we just need to create the store that will hold our data</p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>twanager recipe default <span style="color: #BA2121">&lt;&lt;EOF</span>
+<span style="color: #BA2121">desc: standard TiddlyWebWiki environment</span>
+<span style="color: #BA2121">policy: {&quot;read&quot;: [], &quot;create&quot;: [], &quot;manage&quot;: [&quot;R:ADMIN&quot;], &quot;accept&quot;: [], &quot;write&quot;: [&quot;R:ADMIN&quot;], &quot;owner&quot;: &quot;administrator&quot;, &quot;delete&quot;: [&quot;R:ADMIN&quot;]}</span>
+
+<span style="color: #BA2121">/bags/default/tiddlers</span>
+<span style="color: #BA2121">EOF</span>
+
+twanager bag default <span style="color: #BA2121">&lt;&lt;EOF</span>
+<span style="color: #BA2121">{&quot;policy&quot;: {&quot;read&quot;: [], &quot;create&quot;: [], &quot;manage&quot;: [&quot;R:ADMIN&quot;], &quot;accept&quot;: [], &quot;write&quot;: [], &quot;owner&quot;: &quot;administrator&quot;, &quot;delete&quot;: []}}</span>
+<span style="color: #BA2121">EOF</span>
+</code></pre></div>
+
+<p>Finally, we can start the TiddlyWeb server</p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>twanager server
+</code></pre></div>
+
+<h2 id="putting-it-all-together">Putting it all together</h2>
+
+<p>Once you have the TiddlyWeb server running, you can just go to wherever you&rsquo;re hosting the wiki html and it should work. You can try creating some posts, and the check mark on the sidebar should be red for a while and then turn black. Once that&rsquo;s done it&rsquo;s saved. You can refresh your browser and your posts should still be there.</p>
+
+<p>At this point, you can start customizing your TiddlyWeb instance, by changing your store to something like a database, or adding authorization. You can also tweak the server setup so you won&rsquo;t need CORS anymore.</p>
+
+<p>TiddlyWiki5 is still relatively new. I hope that eventually, support for server-side and the plugin ecosystem grows to be as great as the old TiddlyWiki.</p>
+
+		</div>
+		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2015-12-24">2015-12-24</time></small>
+		| <small class="commentline"><a href="/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html#isso-thread">Comments</a></small>
+	</article>
+	</article>
+	
 	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
 		<header>
 			<h1 class="p-name entry-title" itemprop="headline">
@@ -76,7 +175,7 @@
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2015-06-07">2015-06-07</time></small>
-		| <small class="commentline"><a href="/posts/is-my-terminal-window-active.html#disqus_thread" data-disqus-identifier="cache/posts/is-my-terminal-window-active.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/is-my-terminal-window-active.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -101,7 +200,7 @@
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-11-27">2013-11-27</time></small>
-		| <small class="commentline"><a href="/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html#disqus_thread" data-disqus-identifier="cache/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -123,12 +222,12 @@
 <p>After some further searching, I found <a href="http://unix.stackexchange.com/questions/2884/toggle-between-dvorak-and-qwerty">something close to what I wanted</a>. Apparently, Alt+Up sends a KeyboardSignal keycode to the init process, which can act on that. It also works anywhere, even before being logged in. For SysVinit systems, you can just add a line to your inittab for a command to be run when Alt+Up is pressed.</p>
 
 <p>In the office, however, we generally use Arch Linux which uses SystemD. But apparently, it also has a mechanism of accepting the Alt+Up press. It runs the kbrequest target whenever it gets the keypress. <code>kbrequest.target</code> is normally aliased to run the rescue service though, so you have to manually create the file in <code>/etc/systemd/system/kbrequest.target</code> and fill it with a description:</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">[Unit]</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-ini" data-lang="ini"><span></span><span style="color: #008000; font-weight: bold">[Unit]</span>
 <span style="color: #7D9029">Description</span><span style="color: #666666">=</span><span style="color: #BA2121">kbrequest target</span>
-</pre></div>
+</code></pre></div>
 
 <p>We can then add a service to be run whenever the target is called. Something like <code>/etc/systemd/system/keymap-switch.service</code>:</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">[Unit]</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-ini" data-lang="ini"><span></span><span style="color: #008000; font-weight: bold">[Unit]</span>
 <span style="color: #7D9029">Description</span><span style="color: #666666">=</span><span style="color: #BA2121">Keymap Switch Service</span>
 
 <span style="color: #008000; font-weight: bold">[Service]</span>
@@ -137,10 +236,10 @@
 
 <span style="color: #008000; font-weight: bold">[Install]</span>
 <span style="color: #7D9029">WantedBy</span><span style="color: #666666">=</span><span style="color: #BA2121">kbrequest.target</span>
-</pre></div>
+</code></pre></div>
 
 <p>After enabling said service, we only need the actual keymap switcher, <code>/usr/local/bin/keymap-switch</code>. The StackOverflow answer provides different ways of detecting the current keymap so we know which one to switch to. Since we&rsquo;re using SystemD, we can use that instead for managing which keymap we&rsquo;re actually using. It stores the current settings inside <code>/etc/vconsole.conf</code>. We can also then switch keymaps by using <code>localectl set-keymap</code>.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #408080; font-style: italic">#!/bin/sh</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span><span style="color: #408080; font-style: italic">#!/bin/sh</span>
 <span style="color: #008000">source</span> /etc/vconsole.conf
 
 <span style="color: #008000; font-weight: bold">if</span> <span style="color: #666666">[</span> <span style="color: #BA2121">&quot;</span><span style="color: #19177C">$TERM</span><span style="color: #BA2121">&quot;</span> <span style="color: #666666">=</span> <span style="color: #BA2121">&quot;dumb&quot;</span> <span style="color: #666666">]</span>; <span style="color: #008000; font-weight: bold">then</span>
@@ -150,13 +249,13 @@
     localectl set-keymap dvorak
   <span style="color: #008000; font-weight: bold">fi</span>
 <span style="color: #008000; font-weight: bold">fi</span>
-</pre></div>
+</code></pre></div>
 
 <p>After putting it all together, it works! We can switch keymaps on the fly by simply pressing Alt+Up.</p>
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-10-29">2013-10-29</time></small>
-		| <small class="commentline"><a href="/posts/console-keymap-switching.html#disqus_thread" data-disqus-identifier="cache/posts/console-keymap-switching.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/console-keymap-switching.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -183,46 +282,7 @@
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-09-25">2013-09-25</time></small>
-		| <small class="commentline"><a href="/posts/geocoding-services.html#disqus_thread" data-disqus-identifier="cache/posts/geocoding-services.html">Comments</a></small>
-	</article>
-	</article>
-	
-	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
-		<header>
-			<h1 class="p-name entry-title" itemprop="headline">
-				<a href="/posts/jeep-and-bus-schedules.html" class="u-url">Jeep and Bus Schedules</a>
-			</h1>
-		</header>
-		<div class="e-content entry-content">
-			<p>Wouldn&rsquo;t it be wonderful if there were no buses or jeepneys in the Philippines over the weekends? It would truly be a cyclist&rsquo;s paradise. Imagine biking along EDSA, normally that would be a death sentence, but according to the GTFS data, you shouldn&rsquo;t worry. I can assure you, it&rsquo;s still a death sentence.</p>
-
-<p>The GTFS spec defines 2 ways of statically specifying trip schedules. You can define the exact times that a service will arrive at a stop. You can also specify between what times the service is active and how often a new bus or jeep leaves the first stop. You also define which days those rules apply. You could say every MWF, the bus operates from 9:00AM to 9:00PM and every TTH, the bus services from 3:00AM to 11:00PM.</p>
-
-<p>This should be sufficient in theory, but real world conditions like traffic or the weather could throw the schedules off. To solve this, there&rsquo;s another spec, GTFS-realtime. This allows transit agencies to push temporary schedule updates and service announcements.</p>
-
-<p>Like much everything else about the Philippine transit system, there aren&rsquo;t really any &ldquo;schedules&rdquo; to speak of. It&rsquo;s generally whenever the buses or jeeps feel like it. So we have no static schedules. We don&rsquo;t have a central agency or the tracking technology to make it feasible to push updates via GTFS-RT.</p>
-
-<p>Ideally, we shouldn&rsquo;t bother inputting the schedule information into GTFS. Only the route data is really important for jeeps and buses. However, the schedule information is required in the GTFS, and routing apps wouldn&rsquo;t work without it. So we have to add a reasonable trip schedule for jeeps and buses.</p>
-
-<p>The current GTFS data does define these trip schedules. We assume that jeeps and buses operate between 6:00AM and 11:00PM and a new jeep passes by every 10 minutes. Also, jeeps and buses are defined to only operate on weekdays.</p>
-
-<p>While there might be jeeps who change routes or don&rsquo;t operate on weekends, I&rsquo;m pretty sure that jeeps and buses run on weekends. We&rsquo;ll have to fix it ourselves temporarily since there&rsquo;s no central GTFS feed yet.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #408080; font-style: italic"># 724594 seems to be the service id used by jeeps and buses</span>
-sed -i .bak <span style="color: #BA2121">&#39;/^724594/ s/0,0/1,1/&#39;</span> calendar.txt
-</pre></div>
-
-<p>Another thing we could do is to adjust the time between buses, although the improvement is arguable. With the current 10 minutes between jeeps, it might provide some routes a significant advantage just because the timing is right. So you might get differing route suggestions depending on what time you planned the route. This makes sense when you&rsquo;re sure what the times are, so you can minimize the wait, but with jeeps, you never really know how long the wait will actually be.</p>
-
-<p>If we set the frequency to one minute, it <em>might</em> give better routes by eliminating the timing issue. Or not, it&rsquo;s kind of hard to tell.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #408080; font-style: italic"># jeep and bus route ids tend to start with 72</span>
-sed -i .bak <span style="color: #BA2121">&#39;/^72/ s/,600/,60/&#39;</span> frequencies.txt
-</pre></div>
-
-<p>Overall, the problems we&rsquo;re having is a symptom of the mismatch between our transit system and the GTFS. It would be great if our transit system gets better and we don&rsquo;t need to do hackish things for it to fit the GTFS, but that&rsquo;s still a dream. For now, all we can really do is fit a triangle into a square hole.</p>
-
-		</div>
-		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-28">2013-07-28</time></small>
-		| <small class="commentline"><a href="/posts/jeep-and-bus-schedules.html#disqus_thread" data-disqus-identifier="cache/posts/jeep-and-bus-schedules.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/geocoding-services.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -249,7 +309,7 @@ sed -i .bak <span style="color: #BA2121">&#39;/^72/ s/,600/,60/&#39;</span> freq
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 
@@ -273,7 +333,10 @@ easter_egg.load();
 </script>
 
 
-<script id="dsq-count-scr" type="text/javascript" src="//pleasantprog.disqus.com/count.js" async></script>
+<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	src="https://isso.pleasantprogrammer.com/js/count.min.js">
+</script>
 
 
 </body>

+ 54 - 93
output/page/3.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -35,6 +36,45 @@
 <main id="content" role="main">
 <div class="postindex">
 	
+	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
+		<header>
+			<h1 class="p-name entry-title" itemprop="headline">
+				<a href="/posts/jeep-and-bus-schedules.html" class="u-url">Jeep and Bus Schedules</a>
+			</h1>
+		</header>
+		<div class="e-content entry-content">
+			<p>Wouldn&rsquo;t it be wonderful if there were no buses or jeepneys in the Philippines over the weekends? It would truly be a cyclist&rsquo;s paradise. Imagine biking along EDSA, normally that would be a death sentence, but according to the GTFS data, you shouldn&rsquo;t worry. I can assure you, it&rsquo;s still a death sentence.</p>
+
+<p>The GTFS spec defines 2 ways of statically specifying trip schedules. You can define the exact times that a service will arrive at a stop. You can also specify between what times the service is active and how often a new bus or jeep leaves the first stop. You also define which days those rules apply. You could say every MWF, the bus operates from 9:00AM to 9:00PM and every TTH, the bus services from 3:00AM to 11:00PM.</p>
+
+<p>This should be sufficient in theory, but real world conditions like traffic or the weather could throw the schedules off. To solve this, there&rsquo;s another spec, GTFS-realtime. This allows transit agencies to push temporary schedule updates and service announcements.</p>
+
+<p>Like much everything else about the Philippine transit system, there aren&rsquo;t really any &ldquo;schedules&rdquo; to speak of. It&rsquo;s generally whenever the buses or jeeps feel like it. So we have no static schedules. We don&rsquo;t have a central agency or the tracking technology to make it feasible to push updates via GTFS-RT.</p>
+
+<p>Ideally, we shouldn&rsquo;t bother inputting the schedule information into GTFS. Only the route data is really important for jeeps and buses. However, the schedule information is required in the GTFS, and routing apps wouldn&rsquo;t work without it. So we have to add a reasonable trip schedule for jeeps and buses.</p>
+
+<p>The current GTFS data does define these trip schedules. We assume that jeeps and buses operate between 6:00AM and 11:00PM and a new jeep passes by every 10 minutes. Also, jeeps and buses are defined to only operate on weekdays.</p>
+
+<p>While there might be jeeps who change routes or don&rsquo;t operate on weekends, I&rsquo;m pretty sure that jeeps and buses run on weekends. We&rsquo;ll have to fix it ourselves temporarily since there&rsquo;s no central GTFS feed yet.</p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span><span style="color: #408080; font-style: italic"># 724594 seems to be the service id used by jeeps and buses</span>
+sed -i .bak <span style="color: #BA2121">&#39;/^724594/ s/0,0/1,1/&#39;</span> calendar.txt
+</code></pre></div>
+
+<p>Another thing we could do is to adjust the time between buses, although the improvement is arguable. With the current 10 minutes between jeeps, it might provide some routes a significant advantage just because the timing is right. So you might get differing route suggestions depending on what time you planned the route. This makes sense when you&rsquo;re sure what the times are, so you can minimize the wait, but with jeeps, you never really know how long the wait will actually be.</p>
+
+<p>If we set the frequency to one minute, it <em>might</em> give better routes by eliminating the timing issue. Or not, it&rsquo;s kind of hard to tell.</p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span><span style="color: #408080; font-style: italic"># jeep and bus route ids tend to start with 72</span>
+sed -i .bak <span style="color: #BA2121">&#39;/^72/ s/,600/,60/&#39;</span> frequencies.txt
+</code></pre></div>
+
+<p>Overall, the problems we&rsquo;re having is a symptom of the mismatch between our transit system and the GTFS. It would be great if our transit system gets better and we don&rsquo;t need to do hackish things for it to fit the GTFS, but that&rsquo;s still a dream. For now, all we can really do is fit a triangle into a square hole.</p>
+
+		</div>
+		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-28">2013-07-28</time></small>
+		| <small class="commentline"><a href="/posts/jeep-and-bus-schedules.html#isso-thread">Comments</a></small>
+	</article>
+	</article>
+	
 	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
 		<header>
 			<h1 class="p-name entry-title" itemprop="headline">
@@ -51,8 +91,8 @@
 <p>OTP couldn&rsquo;t possibly be that dumb though, so there must be something we&rsquo;re doing wrong. If you notice, Katipunan Avenue is colored red compared to the other streets. OTP seems to be avoiding any path that goes along Katipunan Avenue. The problem might have something to do with the &ldquo;road type&rdquo; designated to Katipunan.</p>
 
 <p>Apparently, by default OTP will consider roads of type <code>trunk</code> to be non-walkable and non-bikable. This is documented in the <a href="http://wiki.openstreetmap.org/wiki/OpenTripPlanner">OpenStreetMap wiki</a> and the <a href="https://github.com/openplans/OpenTripPlanner/wiki/GraphBuilder#permissions-and-bicycle-safety">OTP wiki</a> as well. There are actually multiple ways to go about this then. The first solution that came to mind was to just edit the original OSM XML file.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>sed -i .bak s/trunk/primary/g manila.osm
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>sed -i .bak s/trunk/primary/g manila.osm
+</code></pre></div>
 
 <p>And rebuild the graph. It doesn&rsquo;t really matter much because the OSM data isn&rsquo;t used to render the maps. It&rsquo;s just used to build the routing data. This is actually what I did for <a href="http://maps.pleasantprogrammer.com">maps.pleasantprogrammer.com</a>.</p>
 
@@ -62,7 +102,7 @@
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-24">2013-07-24</time></small>
-		| <small class="commentline"><a href="/posts/highways-in-otp.html#disqus_thread" data-disqus-identifier="cache/posts/highways-in-otp.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/highways-in-otp.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -80,8 +120,8 @@
 <p>The <a href="https://github.com/openplans/OpenTripPlanner/wiki/FiveMinutes">5 minute tutorial</a> actually discusses the elevation data briefly, but a more in-depth thing you can look at is the <a href="https://github.com/openplans/OpenTripPlanner/wiki/GraphBuilder#elevation-data">GraphBuilder documentation</a>. It suggests using the ASTER dataset which is free but requires registration. I just opted to use the SRTM data available from the <a href="http://www.philgis.org/freegisdata.htm">PhilGIS website</a>.</p>
 
 <p>I don&rsquo;t know about the ASTER dataset, but the PhilGIS data was in the ERDAS img format. OTP only supports GeoTIFF so there was a need to convert it beforehand. You can use <a href="http://www.gdal.org/">GDAL</a> for this. You&rsquo;d just then run,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>gdal_translate srtm41_90m_phl.img phil.tiff
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>gdal_translate srtm41_90m_phl.img phil.tiff
+</code></pre></div>
 
 <p>Afterwards, it&rsquo;s just a matter of following the OTP instructions on using a local elevation dataset. The process actually doubled the size of the generated Graph.obj so it might not be ideal if you&rsquo;re running on limited RAM.</p>
 
@@ -89,7 +129,7 @@
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-23">2013-07-23</time></small>
-		| <small class="commentline"><a href="/posts/elevation-data-in-otp.html#disqus_thread" data-disqus-identifier="cache/posts/elevation-data-in-otp.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/elevation-data-in-otp.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -114,7 +154,7 @@
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-23">2013-07-23</time></small>
-		| <small class="commentline"><a href="/posts/graphserver.html#disqus_thread" data-disqus-identifier="cache/posts/graphserver.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/graphserver.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -147,89 +187,7 @@
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-15">2013-07-15</time></small>
-		| <small class="commentline"><a href="/posts/transit-wand.html#disqus_thread" data-disqus-identifier="cache/posts/transit-wand.html">Comments</a></small>
-	</article>
-	</article>
-	
-	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
-		<header>
-			<h1 class="p-name entry-title" itemprop="headline">
-				<a href="/posts/fare-data.html" class="u-url">Fare Data</a>
-			</h1>
-		</header>
-		<div class="e-content entry-content">
-			
-
-<p>As part of the data released by the DOTC, we also have the <a href="http://philippine-transit.hackathome.com/dataset-philippines-transit-information-service-gtfs/">fare matrix</a> for aircon buses, ordinary buses and jeeps. All as wonderful images. The data is also actually available from the <a href="http://ltfrb.gov.ph/main/farerates">LTFRB website</a>. Generally, the fare scheme is represented as &ldquo;pay <em>X</em> pesos for the first <em>Y</em> kilometers, pay <em>Z</em> for every succeeding kilometer.&rdquo; Instead of a table, we can simply represent this as a formula instead,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>base_fare + (distance - initial) * per_km
-</pre></div>
-
-<p>The relevant values for the three services are:</p>
-
-<table>
-<thead>
-  <tr>
-    <td>type</td>
-    <td>base_fare</td>
-    <td>initial</td>
-    <td>per_km</td>
-  </tr>
-</thead>
-<tbody>
-  <tr>
-    <td>bus aircon</td>
-    <td>12.00</td>
-    <td>5 km</td>
-    <td>2.20</td>
-  </tr>
-  <tr>
-    <td>bus ordinary</td>
-    <td>10.00</td>
-    <td>5 km</td>
-    <td>1.85</td>
-  </tr>
-  <tr>
-    <td>jeep aircon</td>
-    <td>8.00</td>
-    <td>4 km</td>
-    <td>1.40</td>
-  </tr>
-</tbody>
-</table>
-
-<p>It isn&rsquo;t as simple as that though. Fares are also rounded to the nearest 25 centavos. So we&rsquo;d need to round them off correctly. This can be achieved by doing,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>round(calculated_fare * 4.0)/4.0
-</pre></div>
-
-<p>There&rsquo;s also the discounted fare for students, senior citizens and persons with disability. They get 20% off the fare (prior to rounding) and the resulting fare is rounded off as well.</p>
-
-<p>Doing just this, we actually do get the same results as the fare matrices in the image for the most part. There are some discrepancies with the discounted jeep fares. I&rsquo;ve tried to resolve it by tweaking around with the formulas, but it really doesn&rsquo;t make sense in any way. I presume these were manually adjusted for one reason or another.</p>
-
-<p>Here&rsquo;s a <a href="../uploads/farematrix.rb">script</a> that generates CSVs of all the three fare matrices. If you&rsquo;re too lazy to run it, here are links to the <a href="../uploads/pub_aircon.csv">aircon bus</a>, <a href="../uploads/pub_ordinary.csv">ordinary bus</a> and <a href="../uploads/puj.csv">jeep</a> fare matrices.</p>
-
-<h3 id="gtfs-compatibility">GTFS compatibility</h3>
-
-<p>As is, the provided GTFS data does not have any fare data. I imagine this is because the existing spec doesn&rsquo;t have good support for distance-based fares like we have in the Philippines. Judging from the <a href="https://code.google.com/p/googletransitdatafeed/wiki/FareExamples">fare examples</a>, the only reasonable way we could implement distance-based fares is following example 6. This would involve setting a fare for each possible pair of stops based on the distance between them. This isn&rsquo;t exactly ideal. In fact, the people originally working on the DOTC project have voiced <a href="https://groups.google.com/forum/#!topic/gtfs-fare-wg/V63xRSnQJGw">issues</a> and made <a href="https://groups.google.com/forum/#!msg/gtfs-changes/uybrAokZ9Cg/rqlzXdMypUgJ">proposals</a> for having distance-based fares included into GTFS.</p>
-
-<p>Apparently, public transit fares are a really complicated thing. You have fares based on distance, number of stops passed through, and transfers which may or may not cost extra. Not only that, you might have discounted fares, or first-class vs economy fares. The community will want to get it right before it&rsquo;s formally included in the spec. You can see the current state of the consolidated <a href="https://docs.google.com/document/d/1mK3--o5g4-3cCXaqmch92U63JTwChh0L2VCmcDViIlM/edit">GTFS fare proposal here</a>.</p>
-
-<p>Even in it&rsquo;s proposal form though, we might have hope of being able to see these being used. There&rsquo;s currently a <a href="https://github.com/OneBusAway/onebusaway-gtfs-modules/pull/30">pull request</a> for supporting the distance-based fare scheme into the OneBusAway libraries. The libraries actually used by GTFS Editor and OpenTripPlanner for working with GTFS data.</p>
-
-<h3 id="remaining-problems">Remaining Problems</h3>
-
-<p>Given all that, it would probably still be a long way before this allows us to make a really good routing app. We still don&rsquo;t have shape data, so the distance estimates would really be rough estimates at best. There&rsquo;s no support for rounding to the nearest centavo. I realize that&rsquo;s just nitpicking, but if we want something truly polished, even that has to be taken care of.</p>
-
-<p>We also don&rsquo;t know if the jeeps or buses strictly follow the distance-based scheme. After all, if you can get on and off anywhere, you can&rsquo;t really measure distance that exactly. I assume they generally work off the notion of &ldquo;zones&rdquo; than actual distance travelled. In that sense, they work more similarly to the LRT which has fares based on how many stops you pass. For jeeps and buses, your fare is probably based more on how many &ldquo;zones&rdquo; you pass through.</p>
-
-<h3 id="conclusion">Conclusion</h3>
-
-<p>Philip, a co-worker of mine at By Implication, had suggested that we might want to use a different model than what the GTFS proposes. I have to agree with him. At this point, the GTFS doesn&rsquo;t really fit with our system. But I do think that open data and standards are great. In fact, I applaud the developers who made proposals for the fare system, as those are great first steps towards making the GTFS a more universal standard.</p>
-
-<p>Side note: I&rsquo;d also actually really like to hear about the DOTC developers&rsquo; experience with the project. It would be nice if they had a devblog.</p>
-
-		</div>
-		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-13">2013-07-13</time></small>
-		| <small class="commentline"><a href="/posts/fare-data.html#disqus_thread" data-disqus-identifier="cache/posts/fare-data.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/transit-wand.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -256,7 +214,7 @@
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 
@@ -280,7 +238,10 @@ easter_egg.load();
 </script>
 
 
-<script id="dsq-count-scr" type="text/javascript" src="//pleasantprog.disqus.com/count.js" async></script>
+<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	src="https://isso.pleasantprogrammer.com/js/count.min.js">
+</script>
 
 
 </body>

+ 107 - 40
output/page/4.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -35,6 +36,88 @@
 <main id="content" role="main">
 <div class="postindex">
 	
+	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
+		<header>
+			<h1 class="p-name entry-title" itemprop="headline">
+				<a href="/posts/fare-data.html" class="u-url">Fare Data</a>
+			</h1>
+		</header>
+		<div class="e-content entry-content">
+			
+
+<p>As part of the data released by the DOTC, we also have the <a href="http://philippine-transit.hackathome.com/dataset-philippines-transit-information-service-gtfs/">fare matrix</a> for aircon buses, ordinary buses and jeeps. All as wonderful images. The data is also actually available from the <a href="http://ltfrb.gov.ph/main/farerates">LTFRB website</a>. Generally, the fare scheme is represented as &ldquo;pay <em>X</em> pesos for the first <em>Y</em> kilometers, pay <em>Z</em> for every succeeding kilometer.&rdquo; Instead of a table, we can simply represent this as a formula instead,</p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>base_fare + (distance - initial) * per_km
+</code></pre></div>
+
+<p>The relevant values for the three services are:</p>
+
+<table>
+<thead>
+  <tr>
+    <td>type</td>
+    <td>base_fare</td>
+    <td>initial</td>
+    <td>per_km</td>
+  </tr>
+</thead>
+<tbody>
+  <tr>
+    <td>bus aircon</td>
+    <td>12.00</td>
+    <td>5 km</td>
+    <td>2.20</td>
+  </tr>
+  <tr>
+    <td>bus ordinary</td>
+    <td>10.00</td>
+    <td>5 km</td>
+    <td>1.85</td>
+  </tr>
+  <tr>
+    <td>jeep aircon</td>
+    <td>8.00</td>
+    <td>4 km</td>
+    <td>1.40</td>
+  </tr>
+</tbody>
+</table>
+
+<p>It isn&rsquo;t as simple as that though. Fares are also rounded to the nearest 25 centavos. So we&rsquo;d need to round them off correctly. This can be achieved by doing,</p>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>round(calculated_fare * 4.0)/4.0
+</code></pre></div>
+
+<p>There&rsquo;s also the discounted fare for students, senior citizens and persons with disability. They get 20% off the fare (prior to rounding) and the resulting fare is rounded off as well.</p>
+
+<p>Doing just this, we actually do get the same results as the fare matrices in the image for the most part. There are some discrepancies with the discounted jeep fares. I&rsquo;ve tried to resolve it by tweaking around with the formulas, but it really doesn&rsquo;t make sense in any way. I presume these were manually adjusted for one reason or another.</p>
+
+<p>Here&rsquo;s a <a href="../uploads/farematrix.rb">script</a> that generates CSVs of all the three fare matrices. If you&rsquo;re too lazy to run it, here are links to the <a href="../uploads/pub_aircon.csv">aircon bus</a>, <a href="../uploads/pub_ordinary.csv">ordinary bus</a> and <a href="../uploads/puj.csv">jeep</a> fare matrices.</p>
+
+<h3 id="gtfs-compatibility">GTFS compatibility</h3>
+
+<p>As is, the provided GTFS data does not have any fare data. I imagine this is because the existing spec doesn&rsquo;t have good support for distance-based fares like we have in the Philippines. Judging from the <a href="https://code.google.com/p/googletransitdatafeed/wiki/FareExamples">fare examples</a>, the only reasonable way we could implement distance-based fares is following example 6. This would involve setting a fare for each possible pair of stops based on the distance between them. This isn&rsquo;t exactly ideal. In fact, the people originally working on the DOTC project have voiced <a href="https://groups.google.com/forum/#!topic/gtfs-fare-wg/V63xRSnQJGw">issues</a> and made <a href="https://groups.google.com/forum/#!msg/gtfs-changes/uybrAokZ9Cg/rqlzXdMypUgJ">proposals</a> for having distance-based fares included into GTFS.</p>
+
+<p>Apparently, public transit fares are a really complicated thing. You have fares based on distance, number of stops passed through, and transfers which may or may not cost extra. Not only that, you might have discounted fares, or first-class vs economy fares. The community will want to get it right before it&rsquo;s formally included in the spec. You can see the current state of the consolidated <a href="https://docs.google.com/document/d/1mK3--o5g4-3cCXaqmch92U63JTwChh0L2VCmcDViIlM/edit">GTFS fare proposal here</a>.</p>
+
+<p>Even in it&rsquo;s proposal form though, we might have hope of being able to see these being used. There&rsquo;s currently a <a href="https://github.com/OneBusAway/onebusaway-gtfs-modules/pull/30">pull request</a> for supporting the distance-based fare scheme into the OneBusAway libraries. The libraries actually used by GTFS Editor and OpenTripPlanner for working with GTFS data.</p>
+
+<h3 id="remaining-problems">Remaining Problems</h3>
+
+<p>Given all that, it would probably still be a long way before this allows us to make a really good routing app. We still don&rsquo;t have shape data, so the distance estimates would really be rough estimates at best. There&rsquo;s no support for rounding to the nearest centavo. I realize that&rsquo;s just nitpicking, but if we want something truly polished, even that has to be taken care of.</p>
+
+<p>We also don&rsquo;t know if the jeeps or buses strictly follow the distance-based scheme. After all, if you can get on and off anywhere, you can&rsquo;t really measure distance that exactly. I assume they generally work off the notion of &ldquo;zones&rdquo; than actual distance travelled. In that sense, they work more similarly to the LRT which has fares based on how many stops you pass. For jeeps and buses, your fare is probably based more on how many &ldquo;zones&rdquo; you pass through.</p>
+
+<h3 id="conclusion">Conclusion</h3>
+
+<p>Philip, a co-worker of mine at By Implication, had suggested that we might want to use a different model than what the GTFS proposes. I have to agree with him. At this point, the GTFS doesn&rsquo;t really fit with our system. But I do think that open data and standards are great. In fact, I applaud the developers who made proposals for the fare system, as those are great first steps towards making the GTFS a more universal standard.</p>
+
+<p>Side note: I&rsquo;d also actually really like to hear about the DOTC developers&rsquo; experience with the project. It would be nice if they had a devblog.</p>
+
+		</div>
+		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-13">2013-07-13</time></small>
+		| <small class="commentline"><a href="/posts/fare-data.html#isso-thread">Comments</a></small>
+	</article>
+	</article>
+	
 	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
 		<header>
 			<h1 class="p-name entry-title" itemprop="headline">
@@ -61,21 +144,21 @@
 <h3 id="first-pass">First Pass</h3>
 
 <p>A thing to note about Play (and one of the reasons it&rsquo;s a lovely Java framework) is that you don&rsquo;t need to do manual compilation. Just edit some source files, refresh your browser and it will automatically do the compilation for you. One less argument for using PHP. It even shows you (in the browser!) the source and which line of code caused the compilation error. So that&rsquo;s what I saw, <code>Error: type Check already defined</code></p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #AA22FF">@Retention</span><span style="color: #666666">(</span>RetentionPolicy<span style="color: #666666">.</span><span style="color: #7D9029">RUNTIME</span><span style="color: #666666">)</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-java" data-lang="java"><span></span><span style="color: #AA22FF">@Retention</span><span style="color: #666666">(</span>RetentionPolicy<span style="color: #666666">.</span><span style="color: #7D9029">RUNTIME</span><span style="color: #666666">)</span>
 <span style="color: #AA22FF">@Target</span><span style="color: #666666">({</span>ElementType<span style="color: #666666">.</span><span style="color: #7D9029">METHOD</span><span style="color: #666666">,</span> ElementType<span style="color: #666666">.</span><span style="color: #7D9029">TYPE</span><span style="color: #666666">})</span>
 <span style="color: #008000; font-weight: bold">public</span> <span style="color: #AA22FF">@interface</span> Check <span style="color: #666666">{</span> <span style="color: #408080; font-style: italic">// error here</span>
 
     String<span style="color: #666666">[]</span> <span style="color: #0000FF">value</span><span style="color: #666666">();</span>
 <span style="color: #666666">}</span>
-</pre></div>
+</code></pre></div>
 
 <p>You also know that typical behavior among programmers where your program doesn&rsquo;t compile, but you keep trying to compile it anyway hoping that it will magically just work. That&rsquo;s what I did, and it actually ran. I couldn&rsquo;t really just let this pass, so I decided to try deleting <code>Check.java</code>. I got another compilation error, <code>Error: type Secure already defined</code></p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">public</span> <span style="color: #008000; font-weight: bold">class</span> <span style="color: #0000FF; font-weight: bold">Secure</span> <span style="color: #008000; font-weight: bold">extends</span> Controller <span style="color: #666666">{</span> <span style="color: #408080; font-style: italic">// error here</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-java" data-lang="java"><span></span><span style="color: #008000; font-weight: bold">public</span> <span style="color: #008000; font-weight: bold">class</span> <span style="color: #0000FF; font-weight: bold">Secure</span> <span style="color: #008000; font-weight: bold">extends</span> Controller <span style="color: #666666">{</span> <span style="color: #408080; font-style: italic">// error here</span>
 
     <span style="color: #AA22FF">@Before</span><span style="color: #666666">(</span>unless<span style="color: #666666">={</span><span style="color: #BA2121">&quot;login&quot;</span><span style="color: #666666">,</span> <span style="color: #BA2121">&quot;authenticate&quot;</span><span style="color: #666666">,</span> <span style="color: #BA2121">&quot;logout&quot;</span><span style="color: #666666">})</span>
 
     <span style="color: #008000; font-weight: bold">static</span> <span style="color: #B00040">void</span> <span style="color: #0000FF">checkAccess</span><span style="color: #666666">()</span> <span style="color: #008000; font-weight: bold">throws</span> Throwable <span style="color: #666666">{</span>
-</pre></div>
+</code></pre></div>
 
 <p>At that point, I just decided to just debug it later. It works by just forcing it anyway. So I put <code>Check.java</code> back in and proceeded to just refresh until it compiled and ran.</p>
 
@@ -84,18 +167,18 @@
 <p>Another note regarding Play 1.x, it provides the <a href="http://www.playframework.com/documentation/1.2.5/secure">secure module</a> which handles logins and keeping state, you simply need to implement the method <code>boolean authenticate(String username, String password)</code>. It leaves the actual process of verifying the login to the programmer. This can be exploited by just making the method return <code>true</code> and then any login would work. No need to actually set the password. Excellent.</p>
 
 <p>And we&rsquo;re logged in, just in time to encounter a runtime exception. This also works much like compilation errors in Play. It shows a page with the error and the relevant source lines. Now we get, <code>IndexOutOfBoundsException occured : Index: 0, Size: 0</code></p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">if</span><span style="color: #666666">(</span>session<span style="color: #666666">.</span><span style="color: #7D9029">get</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;agencyId&quot;</span><span style="color: #666666">)</span> <span style="color: #666666">==</span> <span style="color: #008000; font-weight: bold">null</span><span style="color: #666666">)</span> <span style="color: #666666">{</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-java" data-lang="java"><span></span><span style="color: #008000; font-weight: bold">if</span><span style="color: #666666">(</span>session<span style="color: #666666">.</span><span style="color: #7D9029">get</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;agencyId&quot;</span><span style="color: #666666">)</span> <span style="color: #666666">==</span> <span style="color: #008000; font-weight: bold">null</span><span style="color: #666666">)</span> <span style="color: #666666">{</span>
 
     Agency agency <span style="color: #666666">=</span> agencies<span style="color: #666666">.</span><span style="color: #7D9029">get</span><span style="color: #666666">(0);</span> <span style="color: #408080; font-style: italic">// error here</span>
 
     session<span style="color: #666666">.</span><span style="color: #7D9029">put</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;agencyId&quot;</span><span style="color: #666666">,</span> agency<span style="color: #666666">.</span><span style="color: #7D9029">id</span><span style="color: #666666">);</span>
     session<span style="color: #666666">.</span><span style="color: #7D9029">put</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;agencyName&quot;</span><span style="color: #666666">,</span> agency<span style="color: #666666">.</span><span style="color: #7D9029">name</span><span style="color: #666666">);</span>
-</pre></div>
+</code></pre></div>
 
 <p>Apparently, we need to have an agency. That&rsquo;s generally simple enough. You just manually insert an agency into the <code>agency</code> table. After that&rsquo;s done, we finally have a view of the actual application. It&rsquo;s very Bootstrap-y, but that&rsquo;s just fine. The workflow though, is not perfectly intuitive, but I&rsquo;ll talk about that some other day.</p>
 
 <p>That&rsquo;s not the end of it though, we still have to fix these bugs. The developer obviously didn&rsquo;t have to put up with this when they were working, so what happened? Also, the log is showing some weird things,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>~        _            _
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>~        _            _
 ~  _ __ | | __ _ _  _| |
 ~ | &#39;_ \| |/ _&#39; | || |_|
 ~ |  __/|_|\____|\__ (_)
@@ -202,7 +285,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 	at play.mvc.ActionInvoker.handleBefores(ActionInvoker.java:328)
 	at play.mvc.ActionInvoker.invoke(ActionInvoker.java:142)
 	... 1 more
-</pre></div>
+</code></pre></div>
 
 <p>After <code>23:32:34</code> is when I get the login page. <code>23:32:40</code> is after I&rsquo;ve logged in.</p>
 
@@ -211,7 +294,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 <p>So how did you do? First, the error that <code>type Check already defined</code> usually does mean that <code>Check</code> was already defined elsewhere. Looking in the app folder though, there was nothing of the sort. It&rsquo;s the only one there that was <code>Check.java</code>. But remember the secure module? Modules work by providing source files and Play just compiles them all together. Bingo, <code>Check.java</code>. Doing a diff shows nothing was changed. So the solution really was just simply delete <code>Check.java</code> and also <code>Secure.java</code>. No more compilation errors!</p>
 
 <p>The next question is, how do you get the initial user? There actually is some code that looks like it creates the default admin user,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">if</span><span style="color: #666666">(</span>Security<span style="color: #666666">.</span><span style="color: #7D9029">isConnected</span><span style="color: #666666">())</span> <span style="color: #666666">{</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-java" data-lang="java"><span></span><span style="color: #008000; font-weight: bold">if</span><span style="color: #666666">(</span>Security<span style="color: #666666">.</span><span style="color: #7D9029">isConnected</span><span style="color: #666666">())</span> <span style="color: #666666">{</span>
     <span style="color: #666666">...</span>
     Account account <span style="color: #666666">=</span> Account<span style="color: #666666">.</span><span style="color: #7D9029">find</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;username = ?&quot;</span><span style="color: #666666">,</span> Security<span style="color: #666666">.</span><span style="color: #7D9029">connected</span><span style="color: #666666">()).</span><span style="color: #7D9029">first</span><span style="color: #666666">();</span>
     <span style="color: #666666">...</span>
@@ -221,7 +304,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
     <span style="color: #666666">}</span>
     <span style="color: #666666">...</span>
 <span style="color: #666666">}</span>
-</pre></div>
+</code></pre></div>
 
 <p>You can actually see this in action at <code>23:32:41,051</code> in the log. So what&rsquo;s wrong with all of this? The account creation happened after I&rsquo;ve already logged in. In fact, <code>Security.isConnected()</code> checks whether the user is already logged in or not. How does this even make sense?</p>
 
@@ -239,7 +322,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-10">2013-07-10</time></small>
-		| <small class="commentline"><a href="/posts/gtfs-editor.html#disqus_thread" data-disqus-identifier="cache/posts/gtfs-editor.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/gtfs-editor.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -276,7 +359,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-09">2013-07-09</time></small>
-		| <small class="commentline"><a href="/posts/one-bus-or-maybe-jeep-away.html#disqus_thread" data-disqus-identifier="cache/posts/one-bus-or-maybe-jeep-away.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/one-bus-or-maybe-jeep-away.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -331,7 +414,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-09">2013-07-09</time></small>
-		| <small class="commentline"><a href="/posts/open-trip-planner.html#disqus_thread" data-disqus-identifier="cache/posts/open-trip-planner.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/open-trip-planner.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -358,30 +441,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 
 		</div>
 		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-07">2013-07-07</time></small>
-		| <small class="commentline"><a href="/posts/jeepney-and-bus-routes.html#disqus_thread" data-disqus-identifier="cache/posts/jeepney-and-bus-routes.html">Comments</a></small>
-	</article>
-	</article>
-	
-	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
-		<header>
-			<h1 class="p-name entry-title" itemprop="headline">
-				<a href="/posts/philippine-transit-app-challenge.html" class="u-url">Philippine Transit App Challenge</a>
-			</h1>
-		</header>
-		<div class="e-content entry-content">
-			<p>Last week, the DOTC launched the <a href="http://philippine-transit.hackathome.com">Philippine Transit App Challenge</a>. It&rsquo;s a competition to build something great using the newly available 1) jeepney/bus/rail routes and 2) traffic incident data in Metro Manila and Cebu.</p>
-
-<p>I&rsquo;m actually quite excited about this as it&rsquo;s not everyday our government does wonderful things. Many people have been waiting for this kind of data to be available. Before, the only way to figure out which jeeps to ride to get from A to B is by asking other people. The website of the LTFRB used to just have a list of jeepney routes, but nothing else, no maps or list of stops.</p>
-
-<p>During the launch, they also presented how CITOM (the Cebu MMDA) is pilot-testing a <a href="http://cebutraffic.org/">traffic tracking system</a>. What they did was supply Android phones to taxi drivers. The phones send GPS data which can then be aggregated to see what the average speeds along streets are. This also benefits the taxi company as it provides easy tracking of their taxis compared to their old telephone/radio with pen-and-paper process.</p>
-
-<p>The <a href="http://philippine-transit.hackathome.com/dataset-philippines-transit-information-service-gtfs/">route data</a> are already available, as well as the <a href="http://philippine-transit.hackathome.com/dataset-citom-traffic-alert-platform/">Cebu</a> and <a href="http://philippine-transit.hackathome.com/dataset-mmda-traffic-alert-platform/">Metro Manila</a> incident data. You do have to register to access them though. Right now, they&rsquo;re just one-off dumps of the data but the various agencies have promised to provide consistently updated data. This will be provided via ASTI later in the year.</p>
-
-<p>I&rsquo;ve just started looking at the route data and playing around with it. The quality could be better, but I&rsquo;m glad we at least have something to work with.</p>
-
-		</div>
-		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-07">2013-07-07</time></small>
-		| <small class="commentline"><a href="/posts/philippine-transit-app-challenge.html#disqus_thread" data-disqus-identifier="cache/posts/philippine-transit-app-challenge.html">Comments</a></small>
+		| <small class="commentline"><a href="/posts/jeepney-and-bus-routes.html#isso-thread">Comments</a></small>
 	</article>
 	</article>
 	
@@ -394,6 +454,10 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 		</li>
 		
 		
+		<li class="next">
+			<a href="/page/5.html">Older posts &rarr;</a>
+		</li>
+		
 	</ul>
 </nav>
 
@@ -404,7 +468,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 
@@ -428,7 +492,10 @@ easter_egg.load();
 </script>
 
 
-<script id="dsq-count-scr" type="text/javascript" src="//pleasantprog.disqus.com/count.js" async></script>
+<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	src="https://isso.pleasantprogrammer.com/js/count.min.js">
+</script>
 
 
 </body>

+ 113 - 0
output/page/5.html

@@ -0,0 +1,113 @@
+<!DOCTYPE html>
+<html lang="en-us">
+<head>
+	<meta charset="utf-8">
+	<meta name="generator" content="Hugo 0.36" />
+	<meta name="viewport" content="width=device-width, initial-scale=1">
+	<link rel="stylesheet" href="/assets/css/theme.css">
+	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
+	<script type="text/javascript" src="//use.typekit.net/iwm5axp.js"></script>
+	<script type="text/javascript">try{Typekit.load();}catch(e){}</script>
+	<title>Pleasant Programmer</title>
+</head>
+
+<body>
+	<header id="header" role="banner">
+		<div id="thomas">
+			<img src="/assets/img/thomas.gif" alt="DJ THOMAS IN DA HAUS">
+			<img src="/assets/img/thomas.png" alt="Pleasant Programmer">
+		</div>
+		<h1 class="site-title"><a href="/">Pleasant Programmer</a></h1>
+		<nav id="menu" role="navigation">
+			<ul>
+				<li class="twitter">
+					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
+				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
+				<li><a href="/posts.html">archives</a></li>
+				<li><a href="/tags.html">tags</a></li>
+				<li><a href="/rss.xml">rss</a></li>
+			</ul>
+		</nav>
+	</header>
+	<div id="container">
+
+
+<main id="content" role="main">
+<div class="postindex">
+	
+	<article class="h-entry post-text" itemscope itemtype="http://schema.org/Blog">
+		<header>
+			<h1 class="p-name entry-title" itemprop="headline">
+				<a href="/posts/philippine-transit-app-challenge.html" class="u-url">Philippine Transit App Challenge</a>
+			</h1>
+		</header>
+		<div class="e-content entry-content">
+			<p>Last week, the DOTC launched the <a href="http://philippine-transit.hackathome.com">Philippine Transit App Challenge</a>. It&rsquo;s a competition to build something great using the newly available 1) jeepney/bus/rail routes and 2) traffic incident data in Metro Manila and Cebu.</p>
+
+<p>I&rsquo;m actually quite excited about this as it&rsquo;s not everyday our government does wonderful things. Many people have been waiting for this kind of data to be available. Before, the only way to figure out which jeeps to ride to get from A to B is by asking other people. The website of the LTFRB used to just have a list of jeepney routes, but nothing else, no maps or list of stops.</p>
+
+<p>During the launch, they also presented how CITOM (the Cebu MMDA) is pilot-testing a <a href="http://cebutraffic.org/">traffic tracking system</a>. What they did was supply Android phones to taxi drivers. The phones send GPS data which can then be aggregated to see what the average speeds along streets are. This also benefits the taxi company as it provides easy tracking of their taxis compared to their old telephone/radio with pen-and-paper process.</p>
+
+<p>The <a href="http://philippine-transit.hackathome.com/dataset-philippines-transit-information-service-gtfs/">route data</a> are already available, as well as the <a href="http://philippine-transit.hackathome.com/dataset-citom-traffic-alert-platform/">Cebu</a> and <a href="http://philippine-transit.hackathome.com/dataset-mmda-traffic-alert-platform/">Metro Manila</a> incident data. You do have to register to access them though. Right now, they&rsquo;re just one-off dumps of the data but the various agencies have promised to provide consistently updated data. This will be provided via ASTI later in the year.</p>
+
+<p>I&rsquo;ve just started looking at the route data and playing around with it. The quality could be better, but I&rsquo;m glad we at least have something to work with.</p>
+
+		</div>
+		<small class="dateline">Posted: <time class="published dt-published" itemprop="datePublished" datetime="2013-07-07">2013-07-07</time></small>
+		| <small class="commentline"><a href="/posts/philippine-transit-app-challenge.html#isso-thread">Comments</a></small>
+	</article>
+	</article>
+	
+</div>
+<nav class="postindexpager">
+	<ul class="pager clearfix">
+		
+		<li class="previous">
+			<a href="/page/4.html">&larr; Newer posts</a>
+		</li>
+		
+		
+	</ul>
+</nav>
+
+</main>
+
+
+	<footer id="footer" role="contentinfo">
+		<p>
+		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
+			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+	</footer>
+</div>
+
+<script src="/assets/js/konami.js"></script>
+<script>
+var easter_egg = new Konami();
+easter_egg.code = function() {
+	var el = document.getElementById('thomas');
+	if(el.className == "whoa") {
+		el.className = "";
+	}
+	else {
+		el.className = "whoa";
+	}
+	document.body.scrollTop = document.documentElement.scrollTop = 0;
+}
+easter_egg.load();
+
+
+
+</script>
+
+
+<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	src="https://isso.pleasantprogrammer.com/js/count.min.js">
+</script>
+
+
+</body>
+</html>
+

+ 83 - 0
output/pages.html

@@ -0,0 +1,83 @@
+<!DOCTYPE html>
+<html lang="en-us">
+<head>
+	<meta charset="utf-8">
+	<meta name="generator" content="Hugo 0.36" />
+	<meta name="viewport" content="width=device-width, initial-scale=1">
+	<link rel="stylesheet" href="/assets/css/theme.css">
+	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
+	<script type="text/javascript" src="//use.typekit.net/iwm5axp.js"></script>
+	<script type="text/javascript">try{Typekit.load();}catch(e){}</script>
+	<title>Pages - Pleasant Programmer</title>
+</head>
+
+<body>
+	<header id="header" role="banner">
+		<div id="thomas">
+			<img src="/assets/img/thomas.gif" alt="DJ THOMAS IN DA HAUS">
+			<img src="/assets/img/thomas.png" alt="Pleasant Programmer">
+		</div>
+		<h1 class="site-title"><a href="/">Pleasant Programmer</a></h1>
+		<nav id="menu" role="navigation">
+			<ul>
+				<li class="twitter">
+					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
+				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
+				<li><a href="/posts.html">archives</a></li>
+				<li><a href="/tags.html">tags</a></li>
+				<li><a href="/rss.xml">rss</a></li>
+			</ul>
+		</nav>
+	</header>
+	<div id="container">
+
+
+<main id="content" role="main">
+<article class="tagpage">
+	<header>
+		<h1 class="list-title">Archive</h1>
+	</header>
+	<ul class="postlist">
+		
+		<li>
+			<a class="listtitle" href="/pages/projects.html">Projects</a>
+			<span class="entry-meta"><time itemprop="datePublished" datetime="2018-02-10">2018-02-10</time></span>
+		</li>
+		
+	</ul>
+</main>
+
+
+	<footer id="footer" role="contentinfo">
+		<p>
+		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
+			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+	</footer>
+</div>
+
+<script src="/assets/js/konami.js"></script>
+<script>
+var easter_egg = new Konami();
+easter_egg.code = function() {
+	var el = document.getElementById('thomas');
+	if(el.className == "whoa") {
+		el.className = "";
+	}
+	else {
+		el.className = "whoa";
+	}
+	document.body.scrollTop = document.documentElement.scrollTop = 0;
+}
+easter_egg.load();
+
+
+
+</script>
+
+
+
+</body>
+</html>
+

+ 115 - 0
output/pages/projects.html

@@ -0,0 +1,115 @@
+<!DOCTYPE html>
+<html lang="en-us">
+<head>
+	<meta charset="utf-8">
+	<meta name="generator" content="Hugo 0.36" />
+	<meta name="viewport" content="width=device-width, initial-scale=1">
+	<link rel="stylesheet" href="/assets/css/theme.css">
+	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
+	<script type="text/javascript" src="//use.typekit.net/iwm5axp.js"></script>
+	<script type="text/javascript">try{Typekit.load();}catch(e){}</script>
+	<title>Projects - Pleasant Programmer</title>
+</head>
+
+<body>
+	<header id="header" role="banner">
+		<div id="thomas">
+			<img src="/assets/img/thomas.gif" alt="DJ THOMAS IN DA HAUS">
+			<img src="/assets/img/thomas.png" alt="Pleasant Programmer">
+		</div>
+		<h1 class="site-title"><a href="/">Pleasant Programmer</a></h1>
+		<nav id="menu" role="navigation">
+			<ul>
+				<li class="twitter">
+					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
+				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
+				<li><a href="/posts.html">archives</a></li>
+				<li><a href="/tags.html">tags</a></li>
+				<li><a href="/rss.xml">rss</a></li>
+			</ul>
+		</nav>
+	</header>
+	<div id="container">
+
+
+<main id="content" role="main">
+<article itemscope itemtype="http://schema.org/BlogPosting">
+	<h1 class="p-name entry-title" itemprop="headline name">
+		<a href="/pages/projects.html">Projects</a></h1>
+	<div class="e-content entry-content" itemprop="entry-text">
+		
+
+<p>I&rsquo;ve made a lot of things in my free time mostly to try out new web
+technologies. I&rsquo;ve also made some non-web things as well, but those aren&rsquo;t as
+easy to show off.</p>
+
+<h2 id="datalinks">Datalinks</h2>
+
+<p>The <a href="https://datalinks.pleasantprogrammer.com">Datalinks</a> is a recreation of the
+in-game manual of Sid Meier&rsquo;s Alpha Centauri. I really like the game,
+particularly how well the setting and atmosphere was done. The voice quotes
+whenever you discover a new technology were what really made the game for me and
+I&rsquo;ve included those into the site. I also tried my very best to capture the
+original look and feel from the game using HTML and CSS.</p>
+
+<h2 id="game-n-chat">Game n&rsquo; Chat</h2>
+
+<p><a href="https://gamenchat.pleasantprogrammer.com">Game n&rsquo; Chat</a> is an online chatroom
+where you can play the Taboo board game. I got the chance to play at a party one
+time and I really enjoyed it. I also remembered having quite a bit of fun
+playing trivia and other games over IRC back in the day, so I decided to build
+something similar.</p>
+
+<h2 id="audventure">Audventure</h2>
+
+<p><a href="https://audventure.pleasantprogrammer.com">Audventure</a> is a clone of the
+Gameboy Advance game, bit generations: Soundvoyager. The game really got my
+interest as the main mechanic involves navigating via sound. The original game
+was comprised of 5 different minigames, but I&rsquo;ve only really implemented one of
+them.</p>
+
+<h2 id="gtfs-html">GTFS.html</h2>
+
+<p><a href="https://gtfs.pleasantprogrammer.com">GTFS.html</a> is a viewer for transit data in
+the GTFS format. I work a lot with GTFS for Sakay.ph and it helps quite a lot to
+be able to visualize the GTFS quickly instead of looking at the raw CSV files or
+actually loading it into the routing engine and testing manually.</p>
+
+	</div>
+</article>
+</main>
+
+
+	<footer id="footer" role="contentinfo">
+		<p>
+		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
+			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+	</footer>
+</div>
+
+<script src="/assets/js/konami.js"></script>
+<script>
+var easter_egg = new Konami();
+easter_egg.code = function() {
+	var el = document.getElementById('thomas');
+	if(el.className == "whoa") {
+		el.className = "";
+	}
+	else {
+		el.className = "whoa";
+	}
+	document.body.scrollTop = document.documentElement.scrollTop = 0;
+}
+easter_egg.load();
+
+
+
+</script>
+
+
+
+</body>
+</html>
+

+ 25 - 0
output/pages/rss.xml

@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
+<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
+  <channel>
+    <title>Pages on Pleasant Programmer</title>
+    <link>https://pleasantprogrammer.com/pages.html</link>
+    <description>Recent content in Pages on Pleasant Programmer</description>
+    <generator>Hugo -- gohugo.io</generator>
+    <language>en-us</language>
+    <lastBuildDate>Sat, 10 Feb 2018 16:47:55 +0900</lastBuildDate>
+    
+	<atom:link href="https://pleasantprogrammer.com/pages/rss.xml" rel="self" type="application/rss+xml" />
+    
+    
+    <item>
+      <title>Projects</title>
+      <link>https://pleasantprogrammer.com/pages/projects.html</link>
+      <pubDate>Sat, 10 Feb 2018 16:47:55 +0900</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/pages/projects.html</guid>
+      <description>I&amp;rsquo;ve made a lot of things in my free time mostly to try out new web technologies. I&amp;rsquo;ve also made some non-web things as well, but those aren&amp;rsquo;t as easy to show off.
+Datalinks The Datalinks is a recreation of the in-game manual of Sid Meier&amp;rsquo;s Alpha Centauri. I really like the game, particularly how well the setting and atmosphere was done. The voice quotes whenever you discover a new technology were what really made the game for me and I&amp;rsquo;ve included those into the site.</description>
+    </item>
+    
+  </channel>
+</rss>

+ 3 - 2
output/posts.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -147,7 +148,7 @@
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/audventure.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -159,21 +160,13 @@ want to contribute music or sound effects, I&rsquo;d gladly appreciate it.</p>
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/audventure.html';
-var disqus_title = 'Audventure';
-var disqus_identifier = 'cache/posts/audventure.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -184,7 +177,7 @@ var disqus_identifier = 'cache/posts/audventure.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 11 - 18
output/posts/cloudflare-shenanigans.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -61,7 +62,7 @@
 <p>Since Cloudflare was essentially just a giant reverse proxy, theoretically there should be no distinction between one IP address from another. The specific IP we get is probably just for load balancing. So we tried accessing the IPs in the range directly and just setting the Host header and it worked! But we get SSL errors because the IP itself doesn&rsquo;t have its own certificate.</p>
 
 <p>After more testing, we figured out that you could actually use any Cloudflare backed domain so long as we properly set the Host header. We just needed to find one still in the old range. Coincidentally, 4chan.org was. Which led to this wonderful commit</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>commit 123456789abcdef
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-diff" data-lang="diff"><span></span>commit 123456789abcdef
 Author: ~~~~~~
 Date:   ~~~~~~
 
@@ -90,7 +91,7 @@ Date:   ~~~~~~
 
                 if(data == null) {
                         data = new ArrayList&lt;NameValuePair&gt;();
-</pre></div>
+</code></pre></div>
 
 <p>Eventually, we did decide to just abandon Cloudflare for the server. We probably weren&rsquo;t going to be the target of a DDOS or anything. This also allowed us to do more secure things like pinning the server certificate in the application itself. Clearly, this is what we should have just done in the first place, but at the time we just wanted a stopgap solution.</p>
 
@@ -114,21 +115,13 @@ Date:   ~~~~~~
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/cloudflare-shenanigans.html';
-var disqus_title = 'Cloudflare Shenanigans';
-var disqus_identifier = 'cache/posts/cloudflare-shenanigans.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -139,7 +132,7 @@ var disqus_identifier = 'cache/posts/cloudflare-shenanigans.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 15 - 22
output/posts/console-keymap-switching.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -61,12 +62,12 @@
 <p>After some further searching, I found <a href="http://unix.stackexchange.com/questions/2884/toggle-between-dvorak-and-qwerty">something close to what I wanted</a>. Apparently, Alt+Up sends a KeyboardSignal keycode to the init process, which can act on that. It also works anywhere, even before being logged in. For SysVinit systems, you can just add a line to your inittab for a command to be run when Alt+Up is pressed.</p>
 
 <p>In the office, however, we generally use Arch Linux which uses SystemD. But apparently, it also has a mechanism of accepting the Alt+Up press. It runs the kbrequest target whenever it gets the keypress. <code>kbrequest.target</code> is normally aliased to run the rescue service though, so you have to manually create the file in <code>/etc/systemd/system/kbrequest.target</code> and fill it with a description:</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">[Unit]</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-ini" data-lang="ini"><span></span><span style="color: #008000; font-weight: bold">[Unit]</span>
 <span style="color: #7D9029">Description</span><span style="color: #666666">=</span><span style="color: #BA2121">kbrequest target</span>
-</pre></div>
+</code></pre></div>
 
 <p>We can then add a service to be run whenever the target is called. Something like <code>/etc/systemd/system/keymap-switch.service</code>:</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">[Unit]</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-ini" data-lang="ini"><span></span><span style="color: #008000; font-weight: bold">[Unit]</span>
 <span style="color: #7D9029">Description</span><span style="color: #666666">=</span><span style="color: #BA2121">Keymap Switch Service</span>
 
 <span style="color: #008000; font-weight: bold">[Service]</span>
@@ -75,10 +76,10 @@
 
 <span style="color: #008000; font-weight: bold">[Install]</span>
 <span style="color: #7D9029">WantedBy</span><span style="color: #666666">=</span><span style="color: #BA2121">kbrequest.target</span>
-</pre></div>
+</code></pre></div>
 
 <p>After enabling said service, we only need the actual keymap switcher, <code>/usr/local/bin/keymap-switch</code>. The StackOverflow answer provides different ways of detecting the current keymap so we know which one to switch to. Since we&rsquo;re using SystemD, we can use that instead for managing which keymap we&rsquo;re actually using. It stores the current settings inside <code>/etc/vconsole.conf</code>. We can also then switch keymaps by using <code>localectl set-keymap</code>.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #408080; font-style: italic">#!/bin/sh</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span><span style="color: #408080; font-style: italic">#!/bin/sh</span>
 <span style="color: #008000">source</span> /etc/vconsole.conf
 
 <span style="color: #008000; font-weight: bold">if</span> <span style="color: #666666">[</span> <span style="color: #BA2121">&quot;</span><span style="color: #19177C">$TERM</span><span style="color: #BA2121">&quot;</span> <span style="color: #666666">=</span> <span style="color: #BA2121">&quot;dumb&quot;</span> <span style="color: #666666">]</span>; <span style="color: #008000; font-weight: bold">then</span>
@@ -88,7 +89,7 @@
     localectl set-keymap dvorak
   <span style="color: #008000; font-weight: bold">fi</span>
 <span style="color: #008000; font-weight: bold">fi</span>
-</pre></div>
+</code></pre></div>
 
 <p>After putting it all together, it works! We can switch keymaps on the fly by simply pressing Alt+Up.</p>
 
@@ -110,21 +111,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/console-keymap-switching.html';
-var disqus_title = 'Console Keymap Switching';
-var disqus_identifier = 'cache/posts/console-keymap-switching.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -135,7 +128,7 @@ var disqus_identifier = 'cache/posts/console-keymap-switching.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 11 - 18
output/posts/elevation-data-in-otp.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -57,8 +58,8 @@
 <p>The <a href="https://github.com/openplans/OpenTripPlanner/wiki/FiveMinutes">5 minute tutorial</a> actually discusses the elevation data briefly, but a more in-depth thing you can look at is the <a href="https://github.com/openplans/OpenTripPlanner/wiki/GraphBuilder#elevation-data">GraphBuilder documentation</a>. It suggests using the ASTER dataset which is free but requires registration. I just opted to use the SRTM data available from the <a href="http://www.philgis.org/freegisdata.htm">PhilGIS website</a>.</p>
 
 <p>I don&rsquo;t know about the ASTER dataset, but the PhilGIS data was in the ERDAS img format. OTP only supports GeoTIFF so there was a need to convert it beforehand. You can use <a href="http://www.gdal.org/">GDAL</a> for this. You&rsquo;d just then run,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>gdal_translate srtm41_90m_phl.img phil.tiff
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>gdal_translate srtm41_90m_phl.img phil.tiff
+</code></pre></div>
 
 <p>Afterwards, it&rsquo;s just a matter of following the OTP instructions on using a local elevation dataset. The process actually doubled the size of the generated Graph.obj so it might not be ideal if you&rsquo;re running on limited RAM.</p>
 
@@ -82,21 +83,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/elevation-data-in-otp.html';
-var disqus_title = 'Elevation Data in OTP';
-var disqus_identifier = 'cache/posts/elevation-data-in-otp.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -107,7 +100,7 @@ var disqus_identifier = 'cache/posts/elevation-data-in-otp.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 13 - 20
output/posts/fare-data.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -53,8 +54,8 @@
 		
 
 <p>As part of the data released by the DOTC, we also have the <a href="http://philippine-transit.hackathome.com/dataset-philippines-transit-information-service-gtfs/">fare matrix</a> for aircon buses, ordinary buses and jeeps. All as wonderful images. The data is also actually available from the <a href="http://ltfrb.gov.ph/main/farerates">LTFRB website</a>. Generally, the fare scheme is represented as &ldquo;pay <em>X</em> pesos for the first <em>Y</em> kilometers, pay <em>Z</em> for every succeeding kilometer.&rdquo; Instead of a table, we can simply represent this as a formula instead,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>base_fare + (distance - initial) * per_km
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>base_fare + (distance - initial) * per_km
+</code></pre></div>
 
 <p>The relevant values for the three services are:</p>
 
@@ -90,8 +91,8 @@
 </table>
 
 <p>It isn&rsquo;t as simple as that though. Fares are also rounded to the nearest 25 centavos. So we&rsquo;d need to round them off correctly. This can be achieved by doing,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>round(calculated_fare * 4.0)/4.0
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>round(calculated_fare * 4.0)/4.0
+</code></pre></div>
 
 <p>There&rsquo;s also the discounted fare for students, senior citizens and persons with disability. They get 20% off the fare (prior to rounding) and the resulting fare is rounded off as well.</p>
 
@@ -137,21 +138,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/fare-data.html';
-var disqus_title = 'Fare Data';
-var disqus_identifier = 'cache/posts/fare-data.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -162,7 +155,7 @@ var disqus_identifier = 'cache/posts/fare-data.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/geocoding-services.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -82,21 +83,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/geocoding-services.html';
-var disqus_title = 'Geocoding Services';
-var disqus_identifier = 'cache/posts/geocoding-services.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -107,7 +100,7 @@ var disqus_identifier = 'cache/posts/geocoding-services.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/graphserver.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -80,21 +81,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/graphserver.html';
-var disqus_title = 'GraphServer';
-var disqus_identifier = 'cache/posts/graphserver.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -105,7 +98,7 @@ var disqus_identifier = 'cache/posts/graphserver.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 19 - 26
output/posts/gtfs-editor.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -73,21 +74,21 @@
 <h3 id="first-pass">First Pass</h3>
 
 <p>A thing to note about Play (and one of the reasons it&rsquo;s a lovely Java framework) is that you don&rsquo;t need to do manual compilation. Just edit some source files, refresh your browser and it will automatically do the compilation for you. One less argument for using PHP. It even shows you (in the browser!) the source and which line of code caused the compilation error. So that&rsquo;s what I saw, <code>Error: type Check already defined</code></p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #AA22FF">@Retention</span><span style="color: #666666">(</span>RetentionPolicy<span style="color: #666666">.</span><span style="color: #7D9029">RUNTIME</span><span style="color: #666666">)</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-java" data-lang="java"><span></span><span style="color: #AA22FF">@Retention</span><span style="color: #666666">(</span>RetentionPolicy<span style="color: #666666">.</span><span style="color: #7D9029">RUNTIME</span><span style="color: #666666">)</span>
 <span style="color: #AA22FF">@Target</span><span style="color: #666666">({</span>ElementType<span style="color: #666666">.</span><span style="color: #7D9029">METHOD</span><span style="color: #666666">,</span> ElementType<span style="color: #666666">.</span><span style="color: #7D9029">TYPE</span><span style="color: #666666">})</span>
 <span style="color: #008000; font-weight: bold">public</span> <span style="color: #AA22FF">@interface</span> Check <span style="color: #666666">{</span> <span style="color: #408080; font-style: italic">// error here</span>
 
     String<span style="color: #666666">[]</span> <span style="color: #0000FF">value</span><span style="color: #666666">();</span>
 <span style="color: #666666">}</span>
-</pre></div>
+</code></pre></div>
 
 <p>You also know that typical behavior among programmers where your program doesn&rsquo;t compile, but you keep trying to compile it anyway hoping that it will magically just work. That&rsquo;s what I did, and it actually ran. I couldn&rsquo;t really just let this pass, so I decided to try deleting <code>Check.java</code>. I got another compilation error, <code>Error: type Secure already defined</code></p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">public</span> <span style="color: #008000; font-weight: bold">class</span> <span style="color: #0000FF; font-weight: bold">Secure</span> <span style="color: #008000; font-weight: bold">extends</span> Controller <span style="color: #666666">{</span> <span style="color: #408080; font-style: italic">// error here</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-java" data-lang="java"><span></span><span style="color: #008000; font-weight: bold">public</span> <span style="color: #008000; font-weight: bold">class</span> <span style="color: #0000FF; font-weight: bold">Secure</span> <span style="color: #008000; font-weight: bold">extends</span> Controller <span style="color: #666666">{</span> <span style="color: #408080; font-style: italic">// error here</span>
 
     <span style="color: #AA22FF">@Before</span><span style="color: #666666">(</span>unless<span style="color: #666666">={</span><span style="color: #BA2121">&quot;login&quot;</span><span style="color: #666666">,</span> <span style="color: #BA2121">&quot;authenticate&quot;</span><span style="color: #666666">,</span> <span style="color: #BA2121">&quot;logout&quot;</span><span style="color: #666666">})</span>
 
     <span style="color: #008000; font-weight: bold">static</span> <span style="color: #B00040">void</span> <span style="color: #0000FF">checkAccess</span><span style="color: #666666">()</span> <span style="color: #008000; font-weight: bold">throws</span> Throwable <span style="color: #666666">{</span>
-</pre></div>
+</code></pre></div>
 
 <p>At that point, I just decided to just debug it later. It works by just forcing it anyway. So I put <code>Check.java</code> back in and proceeded to just refresh until it compiled and ran.</p>
 
@@ -96,18 +97,18 @@
 <p>Another note regarding Play 1.x, it provides the <a href="http://www.playframework.com/documentation/1.2.5/secure">secure module</a> which handles logins and keeping state, you simply need to implement the method <code>boolean authenticate(String username, String password)</code>. It leaves the actual process of verifying the login to the programmer. This can be exploited by just making the method return <code>true</code> and then any login would work. No need to actually set the password. Excellent.</p>
 
 <p>And we&rsquo;re logged in, just in time to encounter a runtime exception. This also works much like compilation errors in Play. It shows a page with the error and the relevant source lines. Now we get, <code>IndexOutOfBoundsException occured : Index: 0, Size: 0</code></p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">if</span><span style="color: #666666">(</span>session<span style="color: #666666">.</span><span style="color: #7D9029">get</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;agencyId&quot;</span><span style="color: #666666">)</span> <span style="color: #666666">==</span> <span style="color: #008000; font-weight: bold">null</span><span style="color: #666666">)</span> <span style="color: #666666">{</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-java" data-lang="java"><span></span><span style="color: #008000; font-weight: bold">if</span><span style="color: #666666">(</span>session<span style="color: #666666">.</span><span style="color: #7D9029">get</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;agencyId&quot;</span><span style="color: #666666">)</span> <span style="color: #666666">==</span> <span style="color: #008000; font-weight: bold">null</span><span style="color: #666666">)</span> <span style="color: #666666">{</span>
 
     Agency agency <span style="color: #666666">=</span> agencies<span style="color: #666666">.</span><span style="color: #7D9029">get</span><span style="color: #666666">(0);</span> <span style="color: #408080; font-style: italic">// error here</span>
 
     session<span style="color: #666666">.</span><span style="color: #7D9029">put</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;agencyId&quot;</span><span style="color: #666666">,</span> agency<span style="color: #666666">.</span><span style="color: #7D9029">id</span><span style="color: #666666">);</span>
     session<span style="color: #666666">.</span><span style="color: #7D9029">put</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;agencyName&quot;</span><span style="color: #666666">,</span> agency<span style="color: #666666">.</span><span style="color: #7D9029">name</span><span style="color: #666666">);</span>
-</pre></div>
+</code></pre></div>
 
 <p>Apparently, we need to have an agency. That&rsquo;s generally simple enough. You just manually insert an agency into the <code>agency</code> table. After that&rsquo;s done, we finally have a view of the actual application. It&rsquo;s very Bootstrap-y, but that&rsquo;s just fine. The workflow though, is not perfectly intuitive, but I&rsquo;ll talk about that some other day.</p>
 
 <p>That&rsquo;s not the end of it though, we still have to fix these bugs. The developer obviously didn&rsquo;t have to put up with this when they were working, so what happened? Also, the log is showing some weird things,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>~        _            _
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>~        _            _
 ~  _ __ | | __ _ _  _| |
 ~ | &#39;_ \| |/ _&#39; | || |_|
 ~ |  __/|_|\____|\__ (_)
@@ -214,7 +215,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 	at play.mvc.ActionInvoker.handleBefores(ActionInvoker.java:328)
 	at play.mvc.ActionInvoker.invoke(ActionInvoker.java:142)
 	... 1 more
-</pre></div>
+</code></pre></div>
 
 <p>After <code>23:32:34</code> is when I get the login page. <code>23:32:40</code> is after I&rsquo;ve logged in.</p>
 
@@ -223,7 +224,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 <p>So how did you do? First, the error that <code>type Check already defined</code> usually does mean that <code>Check</code> was already defined elsewhere. Looking in the app folder though, there was nothing of the sort. It&rsquo;s the only one there that was <code>Check.java</code>. But remember the secure module? Modules work by providing source files and Play just compiles them all together. Bingo, <code>Check.java</code>. Doing a diff shows nothing was changed. So the solution really was just simply delete <code>Check.java</code> and also <code>Secure.java</code>. No more compilation errors!</p>
 
 <p>The next question is, how do you get the initial user? There actually is some code that looks like it creates the default admin user,</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">if</span><span style="color: #666666">(</span>Security<span style="color: #666666">.</span><span style="color: #7D9029">isConnected</span><span style="color: #666666">())</span> <span style="color: #666666">{</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-java" data-lang="java"><span></span><span style="color: #008000; font-weight: bold">if</span><span style="color: #666666">(</span>Security<span style="color: #666666">.</span><span style="color: #7D9029">isConnected</span><span style="color: #666666">())</span> <span style="color: #666666">{</span>
     <span style="color: #666666">...</span>
     Account account <span style="color: #666666">=</span> Account<span style="color: #666666">.</span><span style="color: #7D9029">find</span><span style="color: #666666">(</span><span style="color: #BA2121">&quot;username = ?&quot;</span><span style="color: #666666">,</span> Security<span style="color: #666666">.</span><span style="color: #7D9029">connected</span><span style="color: #666666">()).</span><span style="color: #7D9029">first</span><span style="color: #666666">();</span>
     <span style="color: #666666">...</span>
@@ -233,7 +234,7 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
     <span style="color: #666666">}</span>
     <span style="color: #666666">...</span>
 <span style="color: #666666">}</span>
-</pre></div>
+</code></pre></div>
 
 <p>You can actually see this in action at <code>23:32:41,051</code> in the log. So what&rsquo;s wrong with all of this? The account creation happened after I&rsquo;ve already logged in. In fact, <code>Security.isConnected()</code> checks whether the user is already logged in or not. How does this even make sense?</p>
 
@@ -267,21 +268,13 @@ Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/gtfs-editor.html';
-var disqus_title = 'GTFS Editor';
-var disqus_identifier = 'cache/posts/gtfs-editor.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -292,7 +285,7 @@ var disqus_identifier = 'cache/posts/gtfs-editor.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 11 - 18
output/posts/haproxy-charset.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -57,10 +58,10 @@
 <p>Being lazy, we usually just correct this at the reverse proxy side. It&rsquo;s trivial to do in nginx. You just need to add <code>charset utf-8;</code> to your configuration and you&rsquo;re good. For haproxy though, I couldn&rsquo;t readily find a solution for it and had to go through the docs to see what I could do.</p>
 
 <p>After a bit of experimenting, I had success with this:</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span># set content-type to utf-8 if not already
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span># set content-type to utf-8 if not already
 acl has_charset hdr_sub(content-type) -i charset=
 rspirep (Content-Type.*) \1;\ charset=utf-8 unless has_charset
-</pre></div>
+</code></pre></div>
 
 <p>This is probably not the best way to do it. Arguably, we should just fix our services to have the correct <code>Content-Type</code> in the first place, but I can do that some other time.</p>
 
@@ -82,21 +83,13 @@ rspirep (Content-Type.*) \1;\ charset=utf-8 unless has_charset
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/haproxy-charset.html';
-var disqus_title = 'Haproxy Charset';
-var disqus_identifier = 'cache/posts/haproxy-charset.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -107,7 +100,7 @@ var disqus_identifier = 'cache/posts/haproxy-charset.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 11 - 18
output/posts/highways-in-otp.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -59,8 +60,8 @@
 <p>OTP couldn&rsquo;t possibly be that dumb though, so there must be something we&rsquo;re doing wrong. If you notice, Katipunan Avenue is colored red compared to the other streets. OTP seems to be avoiding any path that goes along Katipunan Avenue. The problem might have something to do with the &ldquo;road type&rdquo; designated to Katipunan.</p>
 
 <p>Apparently, by default OTP will consider roads of type <code>trunk</code> to be non-walkable and non-bikable. This is documented in the <a href="http://wiki.openstreetmap.org/wiki/OpenTripPlanner">OpenStreetMap wiki</a> and the <a href="https://github.com/openplans/OpenTripPlanner/wiki/GraphBuilder#permissions-and-bicycle-safety">OTP wiki</a> as well. There are actually multiple ways to go about this then. The first solution that came to mind was to just edit the original OSM XML file.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>sed -i .bak s/trunk/primary/g manila.osm
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>sed -i .bak s/trunk/primary/g manila.osm
+</code></pre></div>
 
 <p>And rebuild the graph. It doesn&rsquo;t really matter much because the OSM data isn&rsquo;t used to render the maps. It&rsquo;s just used to build the routing data. This is actually what I did for <a href="http://maps.pleasantprogrammer.com">maps.pleasantprogrammer.com</a>.</p>
 
@@ -86,21 +87,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/highways-in-otp.html';
-var disqus_title = 'Highways in OTP';
-var disqus_identifier = 'cache/posts/highways-in-otp.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -111,7 +104,7 @@ var disqus_identifier = 'cache/posts/highways-in-otp.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/is-my-terminal-window-active.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -96,21 +97,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/is-my-terminal-window-active.html';
-var disqus_title = 'Is My Terminal Window Active?';
-var disqus_identifier = 'cache/posts/is-my-terminal-window-active.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -121,7 +114,7 @@ var disqus_identifier = 'cache/posts/is-my-terminal-window-active.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 13 - 20
output/posts/jeep-and-bus-schedules.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -63,16 +64,16 @@
 <p>The current GTFS data does define these trip schedules. We assume that jeeps and buses operate between 6:00AM and 11:00PM and a new jeep passes by every 10 minutes. Also, jeeps and buses are defined to only operate on weekdays.</p>
 
 <p>While there might be jeeps who change routes or don&rsquo;t operate on weekends, I&rsquo;m pretty sure that jeeps and buses run on weekends. We&rsquo;ll have to fix it ourselves temporarily since there&rsquo;s no central GTFS feed yet.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #408080; font-style: italic"># 724594 seems to be the service id used by jeeps and buses</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span><span style="color: #408080; font-style: italic"># 724594 seems to be the service id used by jeeps and buses</span>
 sed -i .bak <span style="color: #BA2121">&#39;/^724594/ s/0,0/1,1/&#39;</span> calendar.txt
-</pre></div>
+</code></pre></div>
 
 <p>Another thing we could do is to adjust the time between buses, although the improvement is arguable. With the current 10 minutes between jeeps, it might provide some routes a significant advantage just because the timing is right. So you might get differing route suggestions depending on what time you planned the route. This makes sense when you&rsquo;re sure what the times are, so you can minimize the wait, but with jeeps, you never really know how long the wait will actually be.</p>
 
 <p>If we set the frequency to one minute, it <em>might</em> give better routes by eliminating the timing issue. Or not, it&rsquo;s kind of hard to tell.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #408080; font-style: italic"># jeep and bus route ids tend to start with 72</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span><span style="color: #408080; font-style: italic"># jeep and bus route ids tend to start with 72</span>
 sed -i .bak <span style="color: #BA2121">&#39;/^72/ s/,600/,60/&#39;</span> frequencies.txt
-</pre></div>
+</code></pre></div>
 
 <p>Overall, the problems we&rsquo;re having is a symptom of the mismatch between our transit system and the GTFS. It would be great if our transit system gets better and we don&rsquo;t need to do hackish things for it to fit the GTFS, but that&rsquo;s still a dream. For now, all we can really do is fit a triangle into a square hole.</p>
 
@@ -94,21 +95,13 @@ sed -i .bak <span style="color: #BA2121">&#39;/^72/ s/,600/,60/&#39;</span> freq
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/jeep-and-bus-schedules.html';
-var disqus_title = 'Jeep and Bus Schedules';
-var disqus_identifier = 'cache/posts/jeep-and-bus-schedules.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -119,7 +112,7 @@ var disqus_identifier = 'cache/posts/jeep-and-bus-schedules.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/jeepney-and-bus-routes.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -82,21 +83,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/jeepney-and-bus-routes.html';
-var disqus_title = 'Jeepney and Bus Routes';
-var disqus_identifier = 'cache/posts/jeepney-and-bus-routes.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -107,7 +100,7 @@ var disqus_identifier = 'cache/posts/jeepney-and-bus-routes.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/one-bus-or-maybe-jeep-away.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -92,21 +93,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/one-bus-or-maybe-jeep-away.html';
-var disqus_title = 'One Bus (or maybe Jeep) Away';
-var disqus_identifier = 'cache/posts/one-bus-or-maybe-jeep-away.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -117,7 +110,7 @@ var disqus_identifier = 'cache/posts/one-bus-or-maybe-jeep-away.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/open-trip-planner.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -110,21 +111,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/open-trip-planner.html';
-var disqus_title = 'Open Trip Planner';
-var disqus_identifier = 'cache/posts/open-trip-planner.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -135,7 +128,7 @@ var disqus_identifier = 'cache/posts/open-trip-planner.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 19 - 26
output/posts/openpreppad.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -86,7 +87,7 @@ to get my bluetooth mouse connected on Linux. The main thing I used then was
 started there.</p>
 
 <p>I started up <code>bluetoothctl</code> and turned on the Prep Pad. And it showed up!</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[bluetooth]# power on
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[bluetooth]# power on
 [CHG] Controller ... Class: 0x00010c
 Changing power on succeeded
 [CHG] Controller ... Powered: yes
@@ -95,15 +96,15 @@ Discovery started
 [CHG] Device 1C:BA:8C:21:7C:BB RSSI: -51
 [CHG] Device 1C:BA:8C:21:7C:BB Name: CHSLEEV_00
 [CHG] Device 1C:BA:8C:21:7C:BB Alias: CHSLEEV_00
-</pre></div>
+</code></pre></div>
 
 <p>I then connected to it, which was surprisingly easy.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[bluetooth]# connect 1C:BA:8C:21:7C:BB
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[bluetooth]# connect 1C:BA:8C:21:7C:BB
 Attempting to connect to 1C:BA:8C:21:7C:BB
 [CHG] Device 1C:BA:8C:21:7C:BB Connected: yes
 [CHG] Device 1C:BA:8C:21:7C:BB Name: CH BTScale_00
 [CHG] Device 1C:BA:8C:21:7C:BB Alias: CH BTScale_00
-</pre></div>
+</code></pre></div>
 
 <p>Now normally, when you turn the device on, the green light flashes occasionally.
 Once I connected to it, the green light stayed on permanently. Clearly, I was
@@ -113,7 +114,7 @@ those things were at that point.</p>
 <p>After a lot of poking around, I could check the general device information. You
 could get the hardware, software and firmware version. There&rsquo;s also the device
 serial number which was nowhere on the actual physical device.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
 [CH BTScale_00:/service0010/char0017]# attribute-info
 Characteristic - Firmware Revision String
 	UUID: 00002a26-0000-1000-8000-00805f9b34fb
@@ -135,12 +136,12 @@ Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x00
   31 2e 31 33 41 00                                1.13A.
 [CH BTScale_00:/service0010/char0017]#
-</pre></div>
+</code></pre></div>
 
 <p>There was also a service which contained Accel Enable, Accel Range, Accel
 X-Coordinate, Accel Y-Coordinate, and Accel Z-Coordinate. I guess it stands for
 accelerometer, which is probably what it uses to weigh things.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
 [CH BTScale_00:/service0023/char0024/desc0026]# read
 Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x41
@@ -156,14 +157,14 @@ Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/de
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x6c
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x65
   41 63 63 65 6c 20 45 6e 61 62 6c 65              Accel Enable
-</pre></div>
+</code></pre></div>
 
 <p>I couldn&rsquo;t read from any of the Accel Coordinates. It kept saying permission
 denied. I could however, notify on them. But that didn&rsquo;t yield anything as well.
 What I <em>could</em> read was Accel Enable, which was set to 00. I guess that means it
 was off. After writing 01 to Accel Enable, I found I could get values out of
 Accel X-Coordinate! Also, the green LED which was permanently on turned off.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-text" data-lang="text"><span></span>[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
 [CH BTScale_00:/service0023/char0024]# write 01
 Attempting to write /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
 [CH BTScale_00:/service0023/char0024]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a
@@ -182,7 +183,7 @@ Notify started
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0xa3
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x02
 [CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x00
-</pre></div>
+</code></pre></div>
 
 <p>I tried pressing the scale down a few times, and the values changed accordingly.
 Now, I just had to figure out how to convert the values into grams. It looked
@@ -228,21 +229,13 @@ are good, I might not even need to finish it.</p>
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/openpreppad.html';
-var disqus_title = 'OpenPrepPad';
-var disqus_identifier = 'cache/posts/.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -253,7 +246,7 @@ var disqus_identifier = 'cache/posts/.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/philippine-transit-app-challenge.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -74,21 +75,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/philippine-transit-app-challenge.html';
-var disqus_title = 'Philippine Transit App Challenge';
-var disqus_identifier = 'cache/posts/philippine-transit-app-challenge.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -99,7 +92,7 @@ var disqus_identifier = 'cache/posts/philippine-transit-app-challenge.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -76,21 +77,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html';
-var disqus_title = 'Removing PLDTMyDSLBiz from the ZyXEL P-2612HNU';
-var disqus_identifier = 'cache/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -101,7 +94,7 @@ var disqus_identifier = 'cache/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 116 - 691
output/posts/rss.xml

@@ -2,790 +2,215 @@
 <rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
   <channel>
     <title>Posts on Pleasant Programmer</title>
-    <link>http://pleasantprogrammer.com/posts/rss.xml</link>
+    <link>https://pleasantprogrammer.com/posts.html</link>
     <description>Recent content in Posts on Pleasant Programmer</description>
     <generator>Hugo -- gohugo.io</generator>
     <language>en-us</language>
     <lastBuildDate>Sun, 19 Nov 2017 22:00:00 +0800</lastBuildDate>
-    <atom:link href="http://pleasantprogrammer.com/posts/rss.xml" rel="self" type="application/rss+xml" />
+    
+	<atom:link href="https://pleasantprogrammer.com/posts/rss.xml" rel="self" type="application/rss+xml" />
+    
     
     <item>
       <title>Audventure</title>
-      <link>http://pleasantprogrammer.com/posts/audventure.html</link>
+      <link>https://pleasantprogrammer.com/posts/audventure.html</link>
       <pubDate>Sun, 19 Nov 2017 22:00:00 +0800</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/audventure.html</guid>
-      <description>
-
-&lt;p&gt;Sometime around 2013 I wrote a clone of the GBA game &lt;a href=&#34;https://www.nintendo.co.jp/n08/bit_g/&#34;&gt;bit Generations
-SoundVoyager&lt;/a&gt; called
-&lt;a href=&#34;https://audventure.pleasantprogrammer.com&#34;&gt;audventure&lt;/a&gt;. SoundVoyager is
-actually a collection of mini-games where sound is the main focus. You can
-actually play the game blind, and at some point, that&amp;rsquo;s pretty much what
-happens.&lt;/p&gt;
-
-&lt;h2 id=&#34;sound-catcher&#34;&gt;sound catcher&lt;/h2&gt;
-
-&lt;p&gt;The signature mini-game in SoundVoyager is sound catcher. In the mini-game, you
-can only move left and right at the bottom of the stage, while a &amp;ldquo;sound&amp;rdquo; falls
-from the top. Your goal is to catch the sound which is signified by a green dot.
-When you catch it, the sound or beat becomes part of the BGM and a new dot
-appears with a different sound.&lt;/p&gt;
-
-&lt;p&gt;You can of course use your eyes and move accordingly, but if you put on
-earphones, you can actually hear where the dot is, either on your left or right,
-with it getting louder as it gets close to you. As you collect more sounds, the
-dot gets more and more transparent. Eventually (and this is where it gets fun),
-you won&amp;rsquo;t be able to see the sounds anymore and will have to rely mostly on your
-ears.&lt;/p&gt;
-
-&lt;p&gt;You can see what the original game looks like in &lt;a href=&#34;https://www.youtube.com/watch?v=C12WRgfIOC8&#34;&gt;this
-video&lt;/a&gt; or you can play it under
-&lt;em&gt;sound safari&lt;/em&gt; in &lt;a href=&#34;https://audventure.pleasantprogrammer.com&#34;&gt;audventure&lt;/a&gt;.&lt;/p&gt;
-
-&lt;h2 id=&#34;webaudio-vs-flash&#34;&gt;WebAudio vs Flash&lt;/h2&gt;
-
-&lt;p&gt;At the time I wrote audventure, only Chrome supported WebAudio. Also, the API
-looked (and still looks) quite complicated. Flash on the other hand, was
-starting to die, but still well-supported so I went with that. For the most
-part, it worked okay though Chrome actually had timing issues when playing
-sounds. Now, it doesn&amp;rsquo;t work in any browser. I tried to debug the issues but
-ultimately ended up just rewriting it to use WebAudio instead.&lt;/p&gt;
-
-&lt;p&gt;For the game, I needed to simulate the source of the sound in 2D/3D space. Flash
-only really gives you stereo panning and volume control. With some maths, we can
-actually get an acceptable solution. Less importantly, I needed to be able to
-get frequency data of the currently playing &amp;ldquo;sound&amp;rdquo; to pulse the background. For
-this, I actually had to implement the feature in the Flash library I was using.&lt;/p&gt;
-
-&lt;p&gt;With WebAudio, spatial audio is already built-in and you can simply give it the
-coordinates of the sounds and the listener. There are some other options to
-tweak, but for the most part, no complex math is needed. Getting frequency data
-for a sound is also actually built-in and didn&amp;rsquo;t take too long to integrate.&lt;/p&gt;
-
-&lt;p&gt;Overall, I was impressed by how much you can do with WebAudio out-of-the-box. I
-kind of understand why it&amp;rsquo;s complicated, but there&amp;rsquo;s some simple functionality
-that I wish was included. For example, there is no API to pause and then resume
-playing an audio buffer. You have to manually save the elapsed time and play
-from there.&lt;/p&gt;
-
-&lt;h2 id=&#34;other-mini-games&#34;&gt;Other mini-games&lt;/h2&gt;
-
-&lt;p&gt;So far I&amp;rsquo;ve only actually implemented the sound catcher mini-game. There are
-around 4 different categories with slight variations in between.&lt;/p&gt;
-
-&lt;h3 id=&#34;sound-catcher-sound-slalom&#34;&gt;sound catcher / sound slalom&lt;/h3&gt;
-
-&lt;p&gt;I&amp;rsquo;ve explained sound catcher a while ago; sound slalom is a minor variation on
-that. Instead of waiting for the &amp;ldquo;sound&amp;rdquo; to reach you, you now have to guide
-yourself in between 2 &amp;ldquo;poles&amp;rdquo; of sound, as in &lt;a href=&#34;https://en.wikipedia.org/wiki/Slalom_skiing&#34;&gt;slalom
-skiing&lt;/a&gt;. But this time, you can
-also accelerate forward. The goal is to finish the course before the time runs
-out.&lt;/p&gt;
-
-&lt;h3 id=&#34;sound-drive-sound-chase&#34;&gt;sound drive / sound chase&lt;/h3&gt;
-
-&lt;p&gt;In sound drive, you&amp;rsquo;re driving against the flow on a 5 lane road. You have to
-avoid oncoming cars, trucks and animals until you reach the end. You&amp;rsquo;re allowed
-to change lanes and accelerate, and the game tracks your best time. Sound chase
-is pretty much the same, except you&amp;rsquo;re trying to catch up to a &amp;ldquo;sound&amp;rdquo;.&lt;/p&gt;
-
-&lt;h3 id=&#34;sound-cannon&#34;&gt;sound cannon&lt;/h3&gt;
-
-&lt;p&gt;In sound cannon, you&amp;rsquo;re immobile but can rotate within a 180 degree angle. Your
-goal is too shoot down &amp;ldquo;sounds&amp;rdquo; which are heading your way. If a sound reaches
-you, it&amp;rsquo;s game over. You win when you kill all the sounds.&lt;/p&gt;
-
-&lt;h3 id=&#34;sound-picker-sound-cock&#34;&gt;sound picker / sound cock&lt;/h3&gt;
-
-&lt;p&gt;In sound picker, you can move in a giant square field where various sounds are
-scattered around. Your goal is to pick up all the sounds within the time limit.
-Sound cock is similar, except the sounds are chickens and you have to chase them
-around.&lt;/p&gt;
-
-&lt;h2 id=&#34;source-code&#34;&gt;Source Code&lt;/h2&gt;
-
-&lt;p&gt;If you want to see the source code, you can check it out
-&lt;a href=&#34;https://git.pleasantprogrammer.com/games/audventure&#34;&gt;here&lt;/a&gt;. The sound files
-aren&amp;rsquo;t in the repo though, since I&amp;rsquo;m not quite sure about the licensing. If you
-want to contribute music or sound effects, I&amp;rsquo;d gladly appreciate it.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/audventure.html</guid>
+      <description>Sometime around 2013 I wrote a clone of the GBA game bit Generations SoundVoyager called audventure. SoundVoyager is actually a collection of mini-games where sound is the main focus. You can actually play the game blind, and at some point, that&amp;rsquo;s pretty much what happens.
+sound catcher The signature mini-game in SoundVoyager is sound catcher. In the mini-game, you can only move left and right at the bottom of the stage, while a &amp;ldquo;sound&amp;rdquo; falls from the top.</description>
     </item>
     
     <item>
       <title>OpenPrepPad</title>
-      <link>http://pleasantprogrammer.com/posts/openpreppad.html</link>
+      <link>https://pleasantprogrammer.com/posts/openpreppad.html</link>
       <pubDate>Sun, 15 Jan 2017 19:31:00 +0800</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/openpreppad.html</guid>
-      <description>
-
-&lt;p&gt;Smart electronics and IoT (Internet of Things) are all the rage these days. You
-have a lot of companies sprout up trying to make the next big thing, which also
-leads to a lot of failures big and small. Pebble, the maker of my smartwatch,
-got bought out by Fitbit recently. This left watch owners without any official
-support, but thankfully, community members &lt;a href=&#34;http://rebble.io/&#34;&gt;stepped up&lt;/a&gt; to continue
-maintaining it.&lt;/p&gt;
-
-&lt;p&gt;Another casualty of the IoT boom was the &lt;a href=&#34;http://theorangechef.com/&#34;&gt;Orange Chef&lt;/a&gt; &lt;a href=&#34;https://www.amazon.com/Orange-Chef-Smart-Scale-Silver/dp/B00KFW8L90&#34;&gt;Prep Pad&lt;/a&gt;. It&amp;rsquo;s a
-bluetooth connected weighing scale to make it easy to track your calories and
-carb/fat/protein intake. My dad bought it last year only to find out that the
-app was incredibly buggy. The search function doesn&amp;rsquo;t work which makes the whole
-thing practically useless. I also found out later that you can&amp;rsquo;t even download
-the app to use the scale anymore.&lt;/p&gt;
-
-&lt;p&gt;&lt;strong&gt;Note&lt;/strong&gt; I just found out as I was writing this post that it &lt;em&gt;may&lt;/em&gt; get supported
-by &lt;a href=&#34;http://www.prnewswire.com/news-releases/perfect-company-acquires-orange-chefs-prep-pad-related-ip-continues-momentum-in-the-connected-kitchen-300383178.html&#34;&gt;another company&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;So the app is useless, but at least you can use it as a scale, right?&lt;/p&gt;
-
-&lt;p&gt;&lt;img src=&#34;http://pleasantprogrammer.com/galleries/openpreppad/preppad.jpg&#34; alt=&#34;Prep Pad&#34; /&gt;&lt;/p&gt;
-
-&lt;p&gt;Nope. The device has no display whatsoever. The only controls on it are the
-on/off button and a green LED that isn&amp;rsquo;t even that useful at telling you whether
-it&amp;rsquo;s on or not. At this point, it&amp;rsquo;s just a giant paperweight.&lt;/p&gt;
-
-&lt;h2 id=&#34;reverse-engineering&#34;&gt;Reverse Engineering&lt;/h2&gt;
-
-&lt;p&gt;Since I essentially had nothing to lose, I tried poking at the thing to figure
-out how it works. I didn&amp;rsquo;t really have experience with bluetooth besides trying
-to get my bluetooth mouse connected on Linux. The main thing I used then was
-&lt;code&gt;bluetoothctl&lt;/code&gt; which is essentially a CLI for managing bluetooth devices so I
-started there.&lt;/p&gt;
-
-&lt;p&gt;I started up &lt;code&gt;bluetoothctl&lt;/code&gt; and turned on the Prep Pad. And it showed up!&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[bluetooth]# power on
-[CHG] Controller ... Class: 0x00010c
-Changing power on succeeded
-[CHG] Controller ... Powered: yes
-[bluetooth]# scan on
-Discovery started
-[CHG] Device 1C:BA:8C:21:7C:BB RSSI: -51
-[CHG] Device 1C:BA:8C:21:7C:BB Name: CHSLEEV_00
-[CHG] Device 1C:BA:8C:21:7C:BB Alias: CHSLEEV_00
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;I then connected to it, which was surprisingly easy.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[bluetooth]# connect 1C:BA:8C:21:7C:BB
-Attempting to connect to 1C:BA:8C:21:7C:BB
-[CHG] Device 1C:BA:8C:21:7C:BB Connected: yes
-[CHG] Device 1C:BA:8C:21:7C:BB Name: CH BTScale_00
-[CHG] Device 1C:BA:8C:21:7C:BB Alias: CH BTScale_00
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Now normally, when you turn the device on, the green light flashes occasionally.
-Once I connected to it, the green light stayed on permanently. Clearly, I was
-making progress. A lot of services were also discovered but I had no idea what
-those things were at that point.&lt;/p&gt;
-
-&lt;p&gt;After a lot of poking around, I could check the general device information. You
-could get the hardware, software and firmware version. There&amp;rsquo;s also the device
-serial number which was nowhere on the actual physical device.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
-[CH BTScale_00:/service0010/char0017]# attribute-info
-Characteristic - Firmware Revision String
-	UUID: 00002a26-0000-1000-8000-00805f9b34fb
-	Service: /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010
-	Value: 0x31
-	Value: 0x2e
-	Value: 0x31
-	Value: 0x33
-	Value: 0x41
-	Value: 0x00
-	Flags: read
-[CH BTScale_00:/service0010/char0017]# read
-Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x31
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x2e
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x31
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x33
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x41
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x00
-  31 2e 31 33 41 00                                1.13A.
-[CH BTScale_00:/service0010/char0017]#
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;There was also a service which contained Accel Enable, Accel Range, Accel
-X-Coordinate, Accel Y-Coordinate, and Accel Z-Coordinate. I guess it stands for
-accelerometer, which is probably what it uses to weigh things.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
-[CH BTScale_00:/service0023/char0024/desc0026]# read
-Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x41
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x63
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x63
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x65
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x6c
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x20
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x45
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x6e
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x61
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x62
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x6c
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x65
-  41 63 63 65 6c 20 45 6e 61 62 6c 65              Accel Enable
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;I couldn&amp;rsquo;t read from any of the Accel Coordinates. It kept saying permission
-denied. I could however, notify on them. But that didn&amp;rsquo;t yield anything as well.
-What I &lt;em&gt;could&lt;/em&gt; read was Accel Enable, which was set to 00. I guess that means it
-was off. After writing 01 to Accel Enable, I found I could get values out of
-Accel X-Coordinate! Also, the green LED which was permanently on turned off.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
-[CH BTScale_00:/service0023/char0024]# write 01
-Attempting to write /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
-[CH BTScale_00:/service0023/char0024]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a
-[CH BTScale_00:/service0023/char002a]# notify on
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Notifying: yes
-Notify started
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x5b
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0xa3
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x02
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x00
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x55
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0xa3
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x02
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x00
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x59
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0xa3
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x02
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x00
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;I tried pressing the scale down a few times, and the values changed accordingly.
-Now, I just had to figure out how to convert the values into grams. It looked
-like the values were 32-bit integers sent as 4 bytes. In the above example it
-would be &lt;code&gt;0x0002a35b&lt;/code&gt;, &lt;code&gt;0x0002a355&lt;/code&gt;, &lt;code&gt;0x0002a359&lt;/code&gt; or 172891, 172855, 172899. The
-values also decrease as you exert more effort on the scale. So assuming you take
-the initial value as &lt;em&gt;tare&lt;/em&gt;, you simply subtract any succeeding value from that
-&lt;em&gt;tare&lt;/em&gt; and you get the &amp;ldquo;weight&amp;rdquo;.&lt;/p&gt;
-
-&lt;p&gt;The values I got didn&amp;rsquo;t seem to be in grams though. After weighing some things
-on an actual scale and comparing the values I got, I found I can just divide the
-values by 14 and get something in grams. That 14 is entirely a magic number
-though and I have no idea whether other Prep Pad&amp;rsquo;s would have the same constant.&lt;/p&gt;
-
-&lt;h2 id=&#34;openpreppad&#34;&gt;OpenPrepPad&lt;/h2&gt;
-
-&lt;p&gt;With all that figured out, I went ahead and made a &lt;a href=&#34;https://github.com/thatsmydoing/openpreppad&#34;&gt;simple CLI application&lt;/a&gt;
-to interface with the Prep Pad. Ironically, node was the simplest thing I found
-that had &lt;a href=&#34;https://github.com/sandeepmistry/noble&#34;&gt;nice bluetooth library support&lt;/a&gt; so that&amp;rsquo;s what I wrote it in. I
-also added most of the technical details in the README for that as well.&lt;/p&gt;
-
-&lt;p&gt;While this is all well and cool, I doubt the intersection of Linux users and
-people who &lt;s&gt;got ripped off&lt;/s&gt; bought the Prep Pad is anyone besides me. In
-light of that, I&amp;rsquo;m in the process of making a React Native version of the app,
-but that&amp;rsquo;s still a work in progress. Who knows, if the new owners of Prep Pad
-are good, I might not even need to finish it.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/openpreppad.html</guid>
+      <description>Smart electronics and IoT (Internet of Things) are all the rage these days. You have a lot of companies sprout up trying to make the next big thing, which also leads to a lot of failures big and small. Pebble, the maker of my smartwatch, got bought out by Fitbit recently. This left watch owners without any official support, but thankfully, community members stepped up to continue maintaining it.</description>
     </item>
     
     <item>
       <title>Haproxy Charset</title>
-      <link>http://pleasantprogrammer.com/posts/haproxy-charset.html</link>
+      <link>https://pleasantprogrammer.com/posts/haproxy-charset.html</link>
       <pubDate>Fri, 24 Jun 2016 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/haproxy-charset.html</guid>
-      <description>&lt;p&gt;A common problem we encounter is for things like &lt;em&gt;ñ&lt;/em&gt; not showing up correctly. This actually caused &lt;a href=&#34;http://www.rappler.com/nation/politics/elections/2016/132894-human-error-hash-election-results-code-mismatch&#34;&gt;some issues&lt;/a&gt; in the recent Philippine elections, but this isn&amp;rsquo;t about hash codes or anything like that.&lt;/p&gt;
-
-&lt;p&gt;By default, we use UTF-8 for text storage and rendering. A problem is that browsers don&amp;rsquo;t assume UTF-8 as the default and you need to have either a &lt;code&gt;&amp;lt;meta charset=&amp;quot;utf-8&amp;quot; /&amp;gt;&lt;/code&gt; in the HTML or &lt;code&gt;Content-Type: text/html; charset=utf-8&lt;/code&gt; in the headers. A few of our services don&amp;rsquo;t set the &lt;code&gt;Content-Type&lt;/code&gt; with the &lt;code&gt;charset=utf-8&lt;/code&gt; part so you&amp;rsquo;d get piñata instead of piñata.&lt;/p&gt;
-
-&lt;p&gt;Being lazy, we usually just correct this at the reverse proxy side. It&amp;rsquo;s trivial to do in nginx. You just need to add &lt;code&gt;charset utf-8;&lt;/code&gt; to your configuration and you&amp;rsquo;re good. For haproxy though, I couldn&amp;rsquo;t readily find a solution for it and had to go through the docs to see what I could do.&lt;/p&gt;
-
-&lt;p&gt;After a bit of experimenting, I had success with this:&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;# set content-type to utf-8 if not already
-acl has_charset hdr_sub(content-type) -i charset=
-rspirep (Content-Type.*) \1;\ charset=utf-8 unless has_charset
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;This is probably not the best way to do it. Arguably, we should just fix our services to have the correct &lt;code&gt;Content-Type&lt;/code&gt; in the first place, but I can do that some other time.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/haproxy-charset.html</guid>
+      <description>A common problem we encounter is for things like ñ not showing up correctly. This actually caused some issues in the recent Philippine elections, but this isn&amp;rsquo;t about hash codes or anything like that.
+By default, we use UTF-8 for text storage and rendering. A problem is that browsers don&amp;rsquo;t assume UTF-8 as the default and you need to have either a &amp;lt;meta charset=&amp;quot;utf-8&amp;quot; /&amp;gt; in the HTML or Content-Type: text/html; charset=utf-8 in the headers.</description>
     </item>
     
     <item>
       <title>Cloudflare Shenanigans</title>
-      <link>http://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</link>
+      <link>https://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</link>
       <pubDate>Fri, 25 Dec 2015 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</guid>
-      <description>&lt;p&gt;An old client of ours managed to convince a telco to zero-rate the data for their app. In order to whitelist it though, we needed to use plain HTTP for domain whitelisting. For HTTPS, they can only whitelist by IP address. Like any good developer, we were using HTTPS. Also, like any good developer, we put our server behind Cloudflare.&lt;/p&gt;
-
-&lt;p&gt;Now the problem is that Cloudflare can put you behind &lt;a href=&#34;https://www.cloudflare.com/ips/&#34;&gt;any IP they own&lt;/a&gt;, which is a huge range. There&amp;rsquo;s no guarantee that the IP we have now is going to be the same later on. So we did the reasonable thing and asked them to whitelist all of the Cloudflare IPs. And the telco agreed! We were in total disbelief when that happened. But hey, if life gives you free internet, you take it.&lt;/p&gt;
-
-&lt;p&gt;We never actually empirically tested whether other sites hosted on Cloudflare were also actually zero-rated. But I like to think that we saved a lot of people on their data costs from browsing Reddit and 4chan. But alas, good things must come to an end.&lt;/p&gt;
-
-&lt;p&gt;A few months after we started beta testing the app, Cloudflare added more IPs to their range. Unfortunately, our server got moved to those new IPs which were not whitelisted yet. Apparently, the telco whitelisting process was incredibly convoluted and time consuming. Our client didn&amp;rsquo;t want to bother asking them to whitelist more IPs. We also tried asking Cloudflare to move us back to the original IP range, but they could only do that if we were in their enterprise tier. We couldn&amp;rsquo;t really afford that, so we looked for other options.&lt;/p&gt;
-
-&lt;p&gt;Since Cloudflare was essentially just a giant reverse proxy, theoretically there should be no distinction between one IP address from another. The specific IP we get is probably just for load balancing. So we tried accessing the IPs in the range directly and just setting the Host header and it worked! But we get SSL errors because the IP itself doesn&amp;rsquo;t have its own certificate.&lt;/p&gt;
-
-&lt;p&gt;After more testing, we figured out that you could actually use any Cloudflare backed domain so long as we properly set the Host header. We just needed to find one still in the old range. Coincidentally, 4chan.org was. Which led to this wonderful commit&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;commit 123456789abcdef
-Author: ~~~~~~
-Date:   ~~~~~~
-
-    4chan hack
-
-&lt;span style=&#34;color: #000080; font-weight: bold&#34;&gt;diff --git a/src/com/client/common/Util.java b/src/com/client/common/Util.java&lt;/span&gt;
-&lt;span style=&#34;color: #A00000&#34;&gt;--- a/src/com/client/common/Util.java&lt;/span&gt;
-&lt;span style=&#34;color: #00A000&#34;&gt;+++ b/src/com/client/common/Util.java&lt;/span&gt;
-&lt;span style=&#34;color: #800080; font-weight: bold&#34;&gt;@@ -210,7 +210,8 @@ public class Util {&lt;/span&gt;
-        }
-
-        public static String getServerAddress(Context context) {
-&lt;span style=&#34;color: #A00000&#34;&gt;-               String address = &amp;quot;https://backend.client.com&amp;quot;;&lt;/span&gt;
-&lt;span style=&#34;color: #00A000&#34;&gt;+               // String address = &amp;quot;https://backend.client.com&amp;quot;;&lt;/span&gt;
-&lt;span style=&#34;color: #00A000&#34;&gt;+               String address = &amp;quot;https://4chan.org&amp;quot;;&lt;/span&gt;
-                if(!isDebug(context)) return address;
-                try {
-&lt;span style=&#34;color: #000080; font-weight: bold&#34;&gt;diff --git a/src/com/client/common/logging/APIClient.java b/src/com/client/common/logging/APIClient.java&lt;/span&gt;
-&lt;span style=&#34;color: #A00000&#34;&gt;--- a/src/com/client/common/logging/APIClient.java&lt;/span&gt;
-&lt;span style=&#34;color: #00A000&#34;&gt;+++ b/src/com/client/common/logging/APIClient.java&lt;/span&gt;
-&lt;span style=&#34;color: #800080; font-weight: bold&#34;&gt;@@ -101,6 +101,7 @@ public class APIClient {&lt;/span&gt;
-        private HttpResponse postInternal(String url, List&amp;lt;NameValuePair&amp;gt; data, boolean forRegistration) throws ClientProtocolException, IOException {
-                HttpPost request = new HttpPost(Util.getServerAddress(mContext)+&amp;quot;/api/&amp;quot;+url);
-                request.setHeader(&amp;quot;X-API-VERSION&amp;quot;, apiVersion);
-&lt;span style=&#34;color: #00A000&#34;&gt;+               request.setHeader(&amp;quot;Host&amp;quot;, &amp;quot;backend.client.com&amp;quot;);&lt;/span&gt;
-
-                if(data == null) {
-                        data = new ArrayList&amp;lt;NameValuePair&amp;gt;();
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Eventually, we did decide to just abandon Cloudflare for the server. We probably weren&amp;rsquo;t going to be the target of a DDOS or anything. This also allowed us to do more secure things like pinning the server certificate in the application itself. Clearly, this is what we should have just done in the first place, but at the time we just wanted a stopgap solution.&lt;/p&gt;
-
-&lt;p&gt;I just still find it funny we were making people&amp;rsquo;s phones go to 4chan.org everyday for more than a year.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</guid>
+      <description>An old client of ours managed to convince a telco to zero-rate the data for their app. In order to whitelist it though, we needed to use plain HTTP for domain whitelisting. For HTTPS, they can only whitelist by IP address. Like any good developer, we were using HTTPS. Also, like any good developer, we put our server behind Cloudflare.
+Now the problem is that Cloudflare can put you behind any IP they own, which is a huge range.</description>
     </item>
     
     <item>
       <title>TiddlyWiki in the Sky (or TiddlyWeb for TW5)</title>
-      <link>http://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</link>
+      <link>https://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</link>
       <pubDate>Thu, 24 Dec 2015 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</guid>
-      <description>
-
-&lt;p&gt;I&amp;rsquo;ve always liked &lt;a href=&#34;http://tiddlywiki.com&#34;&gt;TiddlyWiki&lt;/a&gt;. Back when it first came out, it was really amazing. A wiki all in one file, that worked in the browser. It didn&amp;rsquo;t need a backend, it would just save itself as an all new HTML file with all your posts inside. I&amp;rsquo;ve used it a lot over the years, as a personal wiki/journal and a class notebook. I even had a blog with it at one point using one of the server-side forks.&lt;/p&gt;
-
-&lt;p&gt;Now, there&amp;rsquo;s TiddlyWiki5 which is a rewrite of the original TiddlyWiki that looks a whole lot snazzier, and I assume has better architecture overall. It also has experimental support for all the server-side platforms (particularly TiddlyWeb) that have cropped up.&lt;/p&gt;
-
-&lt;p&gt;If you&amp;rsquo;re just looking for a simple server setup for TiddlyWiki5, it has native support for that on its own. There&amp;rsquo;s plenty of documentation on the site. But if you&amp;rsquo;re looking for more advanced features (like storing your posts in git or a database), then you&amp;rsquo;ll need to use it with TiddlyWeb. The problem is that most of the documentation for TiddlyWeb still refers to the old TiddlyWiki.&lt;/p&gt;
-
-&lt;p&gt;To support TiddlyWiki5, we&amp;rsquo;ll need a version of the wiki which has the TiddlyWeb plugin already installed and configured. After that, some tweaking is necessary to get TiddlyWeb to provide what the wiki requires.&lt;/p&gt;
-
-&lt;h2 id=&#34;setting-up-tiddlywiki&#34;&gt;Setting Up TiddlyWiki&lt;/h2&gt;
-
-&lt;p&gt;TiddlyWiki5 provides a command line tool via &lt;code&gt;npm&lt;/code&gt; that allows building custom versions of the wiki. In fact, it comes with templates, called &amp;ldquo;editions&amp;rdquo;, that we can use for our setup. Assuming you already have it installed, create the wiki using&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;tiddlywiki mywiki --init tw5tank          &lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# create wiki from template&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;This creates a wiki intended for use with &lt;a href=&#34;https://tank.peermore.com/&#34;&gt;Tank&lt;/a&gt;, which is built on top of TiddlyWeb. From here, you should look in &lt;code&gt;mywiki/tiddlers/system&lt;/code&gt; which contain the entries for &lt;code&gt;SiteTitle&lt;/code&gt;, &lt;code&gt;SiteSubtitle&lt;/code&gt;, &lt;code&gt;DefaultTiddlers&lt;/code&gt;, and &lt;code&gt;tiddlyweb-host&lt;/code&gt;. The first 3 should be configured however you want. These are necessary because they&amp;rsquo;re needed before the wiki can load them from the server. &lt;code&gt;tiddlyweb-host&lt;/code&gt; contains the location of the TiddlyWeb server, this should be &lt;code&gt;http://localhost:8080/&lt;/code&gt; if you&amp;rsquo;re just testing locally. With everything configured, you can build the new wiki by running&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;tiddlywiki mywiki --build
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;This will output the wiki to &lt;code&gt;mywiki/output/tw5tank.html&lt;/code&gt;. You can now serve it using your favorite local webserver, like &lt;code&gt;python -m http.server&lt;/code&gt;.&lt;/p&gt;
-
-&lt;h2 id=&#34;setting-up-tiddlyweb&#34;&gt;Setting Up TiddlyWeb&lt;/h2&gt;
-
-&lt;p&gt;The TiddlyWeb tutorial recommends using &lt;code&gt;tiddlywebwiki&lt;/code&gt; which has all the plugins setup for a nice wiki instance for the old TiddlyWiki. It has a lot of features that aren&amp;rsquo;t really needed, so we won&amp;rsquo;t go with that. So first, we&amp;rsquo;ll need to install TiddlyWeb and any plugins we might want to use.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;pip install tiddlyweb tiddlywebplugins.status tiddlywebplugins.cherrypy tiddlywebplugins.cors
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Next, we&amp;rsquo;ll need the tiddlyweb configuration in &lt;code&gt;tiddlywebconfig.py&lt;/code&gt;&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# A basic configuration.&lt;/span&gt;
-&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# `pydoc tiddlyweb.config` for details on configuration items.&lt;/span&gt;
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;import&lt;/span&gt; &lt;span style=&#34;color: #0000FF; font-weight: bold&#34;&gt;tiddlywebplugins.status&lt;/span&gt;
-
-config &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; {
-    &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;system_plugins&amp;#39;&lt;/span&gt;: [&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;tiddlywebplugins.status&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;tiddlywebplugins.cors&amp;#39;&lt;/span&gt;],
-    &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;secret&amp;#39;&lt;/span&gt;: &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;36c98d6d14618c79f0ed2d49cd1b9e272d8d4bd0&amp;#39;&lt;/span&gt;,
-    &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;wsgi_server&amp;#39;&lt;/span&gt;: &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;tiddlywebplugins.cherrypy&amp;#39;&lt;/span&gt;,
-    &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;cors.enable_non_simple&amp;#39;&lt;/span&gt;: &lt;span style=&#34;color: #008000&#34;&gt;True&lt;/span&gt;
-}
-
-original_gather_data &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; tiddlywebplugins&lt;span style=&#34;color: #666666&#34;&gt;.&lt;/span&gt;status&lt;span style=&#34;color: #666666&#34;&gt;.&lt;/span&gt;_gather_data
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color: #0000FF&#34;&gt;_status_gather_data&lt;/span&gt;(environ):
-    data &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; original_gather_data(environ)
-    data[&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;space&amp;#39;&lt;/span&gt;] &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; {&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;recipe&amp;#39;&lt;/span&gt;: &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;default&amp;#39;&lt;/span&gt;}
-    &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;return&lt;/span&gt; data
-
-tiddlywebplugins&lt;span style=&#34;color: #666666&#34;&gt;.&lt;/span&gt;status&lt;span style=&#34;color: #666666&#34;&gt;.&lt;/span&gt;_gather_data &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; _status_gather_data
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;The tweaks involved are:&lt;/p&gt;
-
-&lt;ul&gt;
-&lt;li&gt;using the status plugin which the wiki requires&lt;/li&gt;
-&lt;li&gt;monkeypatching the status plugin for the wiki to use the correct &amp;ldquo;recipe&amp;rdquo;&lt;/li&gt;
-&lt;li&gt;using cherrypy server instead of the buggy default one&lt;/li&gt;
-&lt;li&gt;using cors since we&amp;rsquo;re not hosting the wiki itself on the same server&lt;/li&gt;
-&lt;/ul&gt;
-
-&lt;p&gt;With that, we just need to create the store that will hold our data&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;twanager recipe default &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;lt;&amp;lt;EOF&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;desc: standard TiddlyWebWiki environment&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;policy: {&amp;quot;read&amp;quot;: [], &amp;quot;create&amp;quot;: [], &amp;quot;manage&amp;quot;: [&amp;quot;R:ADMIN&amp;quot;], &amp;quot;accept&amp;quot;: [], &amp;quot;write&amp;quot;: [&amp;quot;R:ADMIN&amp;quot;], &amp;quot;owner&amp;quot;: &amp;quot;administrator&amp;quot;, &amp;quot;delete&amp;quot;: [&amp;quot;R:ADMIN&amp;quot;]}&lt;/span&gt;
-
-&lt;span style=&#34;color: #BA2121&#34;&gt;/bags/default/tiddlers&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;EOF&lt;/span&gt;
-
-twanager bag default &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;lt;&amp;lt;EOF&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;{&amp;quot;policy&amp;quot;: {&amp;quot;read&amp;quot;: [], &amp;quot;create&amp;quot;: [], &amp;quot;manage&amp;quot;: [&amp;quot;R:ADMIN&amp;quot;], &amp;quot;accept&amp;quot;: [], &amp;quot;write&amp;quot;: [], &amp;quot;owner&amp;quot;: &amp;quot;administrator&amp;quot;, &amp;quot;delete&amp;quot;: []}}&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;EOF&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Finally, we can start the TiddlyWeb server&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;twanager server
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;h2 id=&#34;putting-it-all-together&#34;&gt;Putting it all together&lt;/h2&gt;
-
-&lt;p&gt;Once you have the TiddlyWeb server running, you can just go to wherever you&amp;rsquo;re hosting the wiki html and it should work. You can try creating some posts, and the check mark on the sidebar should be red for a while and then turn black. Once that&amp;rsquo;s done it&amp;rsquo;s saved. You can refresh your browser and your posts should still be there.&lt;/p&gt;
-
-&lt;p&gt;At this point, you can start customizing your TiddlyWeb instance, by changing your store to something like a database, or adding authorization. You can also tweak the server setup so you won&amp;rsquo;t need CORS anymore.&lt;/p&gt;
-
-&lt;p&gt;TiddlyWiki5 is still relatively new. I hope that eventually, support for server-side and the plugin ecosystem grows to be as great as the old TiddlyWiki.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</guid>
+      <description>I&amp;rsquo;ve always liked TiddlyWiki. Back when it first came out, it was really amazing. A wiki all in one file, that worked in the browser. It didn&amp;rsquo;t need a backend, it would just save itself as an all new HTML file with all your posts inside. I&amp;rsquo;ve used it a lot over the years, as a personal wiki/journal and a class notebook. I even had a blog with it at one point using one of the server-side forks.</description>
     </item>
     
     <item>
       <title>Is My Terminal Window Active?</title>
-      <link>http://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</link>
+      <link>https://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</link>
       <pubDate>Sun, 07 Jun 2015 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</guid>
-      <description>
-
-&lt;p&gt;I&amp;rsquo;ve been working in OSX for almost 3 years now, but I recently switched back to Linux because of all the problems people encountered with Yosemite. There are some things I missed from OSX though. One of which is &lt;a href=&#34;https://github.com/marzocchi/zsh-notify&#34;&gt;zsh-notify&lt;/a&gt;. It&amp;rsquo;s a zsh plugin that alerts you if your long-running task is complete, and whether it failed or not.&lt;/p&gt;
-
-&lt;p&gt;It&amp;rsquo;s pretty convenient when you&amp;rsquo;re compiling something and then go on to browse reddit while waiting. Usually, I spend too much time just reading and forget about the compilation entirely. With the plugin, I get the notification and maybe go back to work.&lt;/p&gt;
-
-&lt;p&gt;One nice feature it has is that if you&amp;rsquo;re currently looking at the terminal window of the job that just finished, it won&amp;rsquo;t notify you. It only notifies on windows that aren&amp;rsquo;t currently in focus. To do this, it has to actually talk to Terminal.app or iTerm2 to see if the window and tab are active.&lt;/p&gt;
-
-&lt;p&gt;This is alright in OSX since those 2 are the generally most used terminal emulators. On Linux though, everyone has their own favorite terminal. Given that, I figured I could probably rely on talking to X to see if the window is active instead of each single terminal emulator. X can&amp;rsquo;t tell if the tab is active though, but I don&amp;rsquo;t use tabs in my current setup so it should still be good.&lt;/p&gt;
-
-&lt;h2 id=&#34;xdotool&#34;&gt;xdotool&lt;/h2&gt;
-
-&lt;p&gt;&lt;a href=&#34;http://superuser.com/questions/382616/detecting-currently-active-window&#34;&gt;Preliminary research&lt;/a&gt; reveals that we can easily get what the active window is with xdotool. &lt;code&gt;xdotool getactivewindow&lt;/code&gt; gives us the X window id of the active one. Now all we need is a way to get the window id of the terminal we&amp;rsquo;re in.&lt;/p&gt;
-
-&lt;h2 id=&#34;first-attempt-windowid&#34;&gt;First Attempt: $WINDOWID&lt;/h2&gt;
-
-&lt;p&gt;Apparently, xterm and similar terminal emulators define an environment variable called &lt;code&gt;$WINDOWID&lt;/code&gt; with the window id of the terminal. Obviously, this is too good to be true. In xterm and konsole the &lt;code&gt;$WINDOWID&lt;/code&gt; was correct, but in VTE-based terminal emulators, &lt;code&gt;$WINDOWID&lt;/code&gt; had the wrong value. In terminology, it didn&amp;rsquo;t define &lt;code&gt;$WINDOWID&lt;/code&gt; altogether. So &lt;code&gt;$WINDOWID&lt;/code&gt; wasn&amp;rsquo;t going to work.&lt;/p&gt;
-
-&lt;h2 id=&#34;second-attempt-xdotool-search-magic&#34;&gt;Second Attempt: xdotool search $MAGIC&lt;/h2&gt;
-
-&lt;p&gt;My second idea was that you can use zsh to change the window title to a magic number and then just check if the active window is the same one as the window with the magic number. This sort of worked for most terminals, except konsole which does whatever it wants with the window title. There&amp;rsquo;s also the problem of some zsh configs automatically settings the window title to the current command.&lt;/p&gt;
-
-&lt;p&gt;In hindsight, I could probably have just done &lt;code&gt;xdotool search --name xdotool&lt;/code&gt; since in most cases, when you run the search, zsh or konsole will set the window name to the current command. Maybe that&amp;rsquo;s another option I can explore some day.&lt;/p&gt;
-
-&lt;h2 id=&#34;third-attempt-ppid&#34;&gt;Third Attempt: $PPID&lt;/h2&gt;
-
-&lt;p&gt;My third idea was another environment variable called &lt;code&gt;$PPID&lt;/code&gt;, which is the process id of the parent of the shell. As it happens, the parent is the window containing the zsh instance. This is actually pretty consistent across most terminals. The only problem was if you launched zsh from another shell since your new zsh&amp;rsquo;s parent will now be another zsh instance instead of an X window.&lt;/p&gt;
-
-&lt;p&gt;At first glance, launching zsh within zsh doesn&amp;rsquo;t seem like something most people would do, but this is what happens when you run screen or tmux. To work around this, we can actually just save the original &lt;code&gt;$PPID&lt;/code&gt; in a different variable and use that instead.&lt;/p&gt;
-
-&lt;p&gt;Now that we have the PID of the window from zsh, we can once again use xdotool to get the PID of the current active window with &lt;code&gt;xdotool getactivewindow getwindowpid&lt;/code&gt;. We just simply compare that with our &lt;code&gt;$PPID&lt;/code&gt; and we can tell if we&amp;rsquo;re in an active window or not. Overall, this approach worked surprisingly well so that&amp;rsquo;s the final solution I went with.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</guid>
+      <description>I&amp;rsquo;ve been working in OSX for almost 3 years now, but I recently switched back to Linux because of all the problems people encountered with Yosemite. There are some things I missed from OSX though. One of which is zsh-notify. It&amp;rsquo;s a zsh plugin that alerts you if your long-running task is complete, and whether it failed or not.
+It&amp;rsquo;s pretty convenient when you&amp;rsquo;re compiling something and then go on to browse reddit while waiting.</description>
     </item>
     
     <item>
       <title>Removing PLDTMyDSLBiz from the ZyXEL P-2612HNU</title>
-      <link>http://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</link>
+      <link>https://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</link>
       <pubDate>Wed, 27 Nov 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</guid>
-      <description>&lt;p&gt;I&amp;rsquo;ve always thought that people were just too lazy to change their SSIDs when I see &amp;ldquo;PLDTMyDSLBizCafeJapan&amp;rdquo;. It became apparent when we got our own PLDT line that it was because the bundled router/modem &lt;em&gt;does not&lt;/em&gt; allow you to remove the prefix.&lt;/p&gt;
-
-&lt;p&gt;This is not the kind of thing you expect as a business customer. Even for home customers, I feel it&amp;rsquo;s still a bit dishonest. I&amp;rsquo;d be fine if it was just the default SSID, but forcing people to have it as part of their SSID is like advertising that your company (I mean PLDT) is a douche.&lt;/p&gt;
-
-&lt;p&gt;Of course, we couldn&amp;rsquo;t just leave the SSID prefix there, so we tried a number of things to get rid of it. There are articles for removing it from the &lt;a href=&#34;http://www.phandroidinternet.com/2013/06/how-to-remove-on-wifi-name-or-ssid-on.html&#34;&gt;Prolink H5004N&lt;/a&gt; or the &lt;a href=&#34;http://www.symbianize.com/showthread.php?t=730091&#34;&gt;ZyXEL P-660HN-T1A&lt;/a&gt; but not for the one we got which was the ZyXEL P-2612HNU-F1F.&lt;/p&gt;
-
-&lt;p&gt;We did still try the firebug/inspector tricks, but it seems that there is a server-side check that adds in the &amp;ldquo;PLDTMyDSLBiz&amp;rdquo;. We tried a number of things, but the one that ultimately worked (and we had a good laugh about) was to backup the configuration, edit the dumped file and restore it.&lt;/p&gt;
-
-&lt;p&gt;The backup is actually just an XML file. You can search for SSID and change the parameter there. It&amp;rsquo;s a bit annoying because the router has to restart after restoring the configuration, but it works!&lt;/p&gt;
-
-&lt;p&gt;A minor note, the router doesn&amp;rsquo;t seem to support SSIDs with a comma (,) well. It just gets everything before the comma as the SSID for some reason.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</guid>
+      <description>I&amp;rsquo;ve always thought that people were just too lazy to change their SSIDs when I see &amp;ldquo;PLDTMyDSLBizCafeJapan&amp;rdquo;. It became apparent when we got our own PLDT line that it was because the bundled router/modem does not allow you to remove the prefix.
+This is not the kind of thing you expect as a business customer. Even for home customers, I feel it&amp;rsquo;s still a bit dishonest. I&amp;rsquo;d be fine if it was just the default SSID, but forcing people to have it as part of their SSID is like advertising that your company (I mean PLDT) is a douche.</description>
     </item>
     
     <item>
       <title>Console Keymap Switching</title>
-      <link>http://pleasantprogrammer.com/posts/console-keymap-switching.html</link>
+      <link>https://pleasantprogrammer.com/posts/console-keymap-switching.html</link>
       <pubDate>Tue, 29 Oct 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/console-keymap-switching.html</guid>
-      <description>&lt;p&gt;At the office, we have some people who use DVORAK. Normally, this isn&amp;rsquo;t a problem. To each his own after all. It does become a bit problematic though, when we&amp;rsquo;re dealing with the servers around the office.&lt;/p&gt;
-
-&lt;p&gt;We normally leave the servers on QWERTY. After all, most people start off as QWERTY typists and migrate to something else. That said, it&amp;rsquo;s apparently difficult to stay fluent in both. People tend to forget how to type in QWERTY once they learn DVORAK or something else. While it is true that they can just look a the keyboard while typing, my coworkers would prefer it to just be in DVORAK.&lt;/p&gt;
-
-&lt;p&gt;For the console, they&amp;rsquo;d typically do &lt;code&gt;sudo loadkeys dvorak&lt;/code&gt; after logging in. The problem with this is, after they logout, the keymapping is still on DVORAK. This has been quite annoying for a few times since I can&amp;rsquo;t even login to change the keymap. What I wanted was something like you get in the graphical login screens where you can pick your keymap before logging in. Apparently, there isn&amp;rsquo;t a readily available thing for the console.&lt;/p&gt;
-
-&lt;p&gt;I googled around for solutions and came across &lt;a href=&#34;http://superuser.com/questions/548234/how-can-i-easily-toggle-between-dvorak-and-qwerty-keyboard-layouts-from-a-linux&#34;&gt;a nice idea&lt;/a&gt;. You could alias &lt;code&gt;asdf&lt;/code&gt; to load the DVORAK mapping and &lt;code&gt;aoeu&lt;/code&gt; (the equivalent to asdf in DVORAK) to load the QWERTY mapping. This actually makes sense since you don&amp;rsquo;t really have to know where the letters are. The only problem is, you once again have to be logged in to change the key mappings.&lt;/p&gt;
-
-&lt;p&gt;After some further searching, I found &lt;a href=&#34;http://unix.stackexchange.com/questions/2884/toggle-between-dvorak-and-qwerty&#34;&gt;something close to what I wanted&lt;/a&gt;. Apparently, Alt+Up sends a KeyboardSignal keycode to the init process, which can act on that. It also works anywhere, even before being logged in. For SysVinit systems, you can just add a line to your inittab for a command to be run when Alt+Up is pressed.&lt;/p&gt;
-
-&lt;p&gt;In the office, however, we generally use Arch Linux which uses SystemD. But apparently, it also has a mechanism of accepting the Alt+Up press. It runs the kbrequest target whenever it gets the keypress. &lt;code&gt;kbrequest.target&lt;/code&gt; is normally aliased to run the rescue service though, so you have to manually create the file in &lt;code&gt;/etc/systemd/system/kbrequest.target&lt;/code&gt; and fill it with a description:&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;[Unit]&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;Description&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;kbrequest target&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;We can then add a service to be run whenever the target is called. Something like &lt;code&gt;/etc/systemd/system/keymap-switch.service&lt;/code&gt;:&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;[Unit]&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;Description&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;Keymap Switch Service&lt;/span&gt;
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;[Service]&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;Type&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;oneshot&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;ExecStart&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;/usr/local/bin/keymap-switch&lt;/span&gt;
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;[Install]&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;WantedBy&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;kbrequest.target&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;After enabling said service, we only need the actual keymap switcher, &lt;code&gt;/usr/local/bin/keymap-switch&lt;/code&gt;. The StackOverflow answer provides different ways of detecting the current keymap so we know which one to switch to. Since we&amp;rsquo;re using SystemD, we can use that instead for managing which keymap we&amp;rsquo;re actually using. It stores the current settings inside &lt;code&gt;/etc/vconsole.conf&lt;/code&gt;. We can also then switch keymaps by using &lt;code&gt;localectl set-keymap&lt;/code&gt;.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;#!/bin/sh&lt;/span&gt;
-&lt;span style=&#34;color: #008000&#34;&gt;source&lt;/span&gt; /etc/vconsole.conf
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;[&lt;/span&gt; &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;&lt;/span&gt;&lt;span style=&#34;color: #19177C&#34;&gt;$TERM&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;dumb&amp;quot;&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;]&lt;/span&gt;; &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;then&lt;/span&gt;
-  &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;[&lt;/span&gt; &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;&lt;/span&gt;&lt;span style=&#34;color: #19177C&#34;&gt;$KEYMAP&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;dvorak&amp;quot;&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;]&lt;/span&gt;; &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;then&lt;/span&gt;
-    localectl set-keymap us
-  &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;else&lt;/span&gt;
-    localectl set-keymap dvorak
-  &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;fi&lt;/span&gt;
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;fi&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;After putting it all together, it works! We can switch keymaps on the fly by simply pressing Alt+Up.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/console-keymap-switching.html</guid>
+      <description>At the office, we have some people who use DVORAK. Normally, this isn&amp;rsquo;t a problem. To each his own after all. It does become a bit problematic though, when we&amp;rsquo;re dealing with the servers around the office.
+We normally leave the servers on QWERTY. After all, most people start off as QWERTY typists and migrate to something else. That said, it&amp;rsquo;s apparently difficult to stay fluent in both. People tend to forget how to type in QWERTY once they learn DVORAK or something else.</description>
     </item>
     
     <item>
       <title>Geocoding Services</title>
-      <link>http://pleasantprogrammer.com/posts/geocoding-services.html</link>
+      <link>https://pleasantprogrammer.com/posts/geocoding-services.html</link>
       <pubDate>Wed, 25 Sep 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/geocoding-services.html</guid>
-      <description>&lt;p&gt;A key component for any routing service is being able to do geocoding. Most people who are looking for routes most probably don&amp;rsquo;t know exactly where their start and end points are on the map. Even then, manually looking for a location on a map is a time-consuming task.&lt;/p&gt;
-
-&lt;p&gt;The gold standard for doing geocoding right now is Google Maps. It&amp;rsquo;s hard to find a better location search experience. If they actually provided routing for jeeps here in the Philippines, I imagine there wouldn&amp;rsquo;t be &lt;em&gt;that&lt;/em&gt; much you could do for the competition.&lt;/p&gt;
-
-&lt;p&gt;When the competition started though, I took it as a challenge to avoid Google Maps as much as possible. I wanted to see how much is currently possible with other options such as OpenStreetMap. In fact, OSM does have a geocoding service called &lt;a href=&#34;http://nominatim.openstreetmap.org&#34;&gt;Nominatim&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;Sadly, for a mapping app, what you want to do is not simply just geocoding. With geocoding, you take an address and turn it into coordinates. When you want to search for a place in a mapping app, you take part of an address, infer the rest of it, and give the user options to choose from.&lt;/p&gt;
-
-&lt;p&gt;Given a typical mapping app, you might type in &amp;ldquo;ateneo&amp;rdquo; and expect it to give you Ateneo de Manila University. With typical geocoding services like Nominatim or even Google&amp;rsquo;s &lt;a href=&#34;https://developers.google.com/maps/documentation/javascript/geocoding&#34;&gt;geocoding API&lt;/a&gt;, you probably won&amp;rsquo;t get any result for this. What you want to use is the &lt;a href=&#34;https://developers.google.com/maps/documentation/javascript/places&#34;&gt;Places API&lt;/a&gt; which provides an autocomplete search box. Using it, when you type in &amp;ldquo;ateneo&amp;rdquo;, it automatically suggests in the dropdown, &amp;ldquo;Ateneo de Manila University&amp;rdquo;.&lt;/p&gt;
-
-&lt;p&gt;A downside to using the Places API is that it&amp;rsquo;s against the terms of service to use it with something that isn&amp;rsquo;t Google Maps, which means no OpenStreetMap. If there were more time, writing your own autocompletion engine using OpenStreetMap&amp;rsquo;s data will probably be a better long term solution.&lt;/p&gt;
-
-&lt;p&gt;For now, since the competition&amp;rsquo;s deadline is just a few days away, I&amp;rsquo;ll be using Google Maps.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/geocoding-services.html</guid>
+      <description>A key component for any routing service is being able to do geocoding. Most people who are looking for routes most probably don&amp;rsquo;t know exactly where their start and end points are on the map. Even then, manually looking for a location on a map is a time-consuming task.
+The gold standard for doing geocoding right now is Google Maps. It&amp;rsquo;s hard to find a better location search experience. If they actually provided routing for jeeps here in the Philippines, I imagine there wouldn&amp;rsquo;t be that much you could do for the competition.</description>
     </item>
     
     <item>
       <title>Jeep and Bus Schedules</title>
-      <link>http://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</link>
+      <link>https://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</link>
       <pubDate>Sun, 28 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</guid>
-      <description>&lt;p&gt;Wouldn&amp;rsquo;t it be wonderful if there were no buses or jeepneys in the Philippines over the weekends? It would truly be a cyclist&amp;rsquo;s paradise. Imagine biking along EDSA, normally that would be a death sentence, but according to the GTFS data, you shouldn&amp;rsquo;t worry. I can assure you, it&amp;rsquo;s still a death sentence.&lt;/p&gt;
-
-&lt;p&gt;The GTFS spec defines 2 ways of statically specifying trip schedules. You can define the exact times that a service will arrive at a stop. You can also specify between what times the service is active and how often a new bus or jeep leaves the first stop. You also define which days those rules apply. You could say every MWF, the bus operates from 9:00AM to 9:00PM and every TTH, the bus services from 3:00AM to 11:00PM.&lt;/p&gt;
-
-&lt;p&gt;This should be sufficient in theory, but real world conditions like traffic or the weather could throw the schedules off. To solve this, there&amp;rsquo;s another spec, GTFS-realtime. This allows transit agencies to push temporary schedule updates and service announcements.&lt;/p&gt;
-
-&lt;p&gt;Like much everything else about the Philippine transit system, there aren&amp;rsquo;t really any &amp;ldquo;schedules&amp;rdquo; to speak of. It&amp;rsquo;s generally whenever the buses or jeeps feel like it. So we have no static schedules. We don&amp;rsquo;t have a central agency or the tracking technology to make it feasible to push updates via GTFS-RT.&lt;/p&gt;
-
-&lt;p&gt;Ideally, we shouldn&amp;rsquo;t bother inputting the schedule information into GTFS. Only the route data is really important for jeeps and buses. However, the schedule information is required in the GTFS, and routing apps wouldn&amp;rsquo;t work without it. So we have to add a reasonable trip schedule for jeeps and buses.&lt;/p&gt;
-
-&lt;p&gt;The current GTFS data does define these trip schedules. We assume that jeeps and buses operate between 6:00AM and 11:00PM and a new jeep passes by every 10 minutes. Also, jeeps and buses are defined to only operate on weekdays.&lt;/p&gt;
-
-&lt;p&gt;While there might be jeeps who change routes or don&amp;rsquo;t operate on weekends, I&amp;rsquo;m pretty sure that jeeps and buses run on weekends. We&amp;rsquo;ll have to fix it ourselves temporarily since there&amp;rsquo;s no central GTFS feed yet.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# 724594 seems to be the service id used by jeeps and buses&lt;/span&gt;
-sed -i .bak &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;/^724594/ s/0,0/1,1/&amp;#39;&lt;/span&gt; calendar.txt
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Another thing we could do is to adjust the time between buses, although the improvement is arguable. With the current 10 minutes between jeeps, it might provide some routes a significant advantage just because the timing is right. So you might get differing route suggestions depending on what time you planned the route. This makes sense when you&amp;rsquo;re sure what the times are, so you can minimize the wait, but with jeeps, you never really know how long the wait will actually be.&lt;/p&gt;
-
-&lt;p&gt;If we set the frequency to one minute, it &lt;em&gt;might&lt;/em&gt; give better routes by eliminating the timing issue. Or not, it&amp;rsquo;s kind of hard to tell.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# jeep and bus route ids tend to start with 72&lt;/span&gt;
-sed -i .bak &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;/^72/ s/,600/,60/&amp;#39;&lt;/span&gt; frequencies.txt
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Overall, the problems we&amp;rsquo;re having is a symptom of the mismatch between our transit system and the GTFS. It would be great if our transit system gets better and we don&amp;rsquo;t need to do hackish things for it to fit the GTFS, but that&amp;rsquo;s still a dream. For now, all we can really do is fit a triangle into a square hole.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</guid>
+      <description>Wouldn&amp;rsquo;t it be wonderful if there were no buses or jeepneys in the Philippines over the weekends? It would truly be a cyclist&amp;rsquo;s paradise. Imagine biking along EDSA, normally that would be a death sentence, but according to the GTFS data, you shouldn&amp;rsquo;t worry. I can assure you, it&amp;rsquo;s still a death sentence.
+The GTFS spec defines 2 ways of statically specifying trip schedules. You can define the exact times that a service will arrive at a stop.</description>
     </item>
     
     <item>
       <title>Highways in OTP</title>
-      <link>http://pleasantprogrammer.com/posts/highways-in-otp.html</link>
+      <link>https://pleasantprogrammer.com/posts/highways-in-otp.html</link>
       <pubDate>Wed, 24 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/highways-in-otp.html</guid>
-      <description>&lt;p&gt;One of the weird things that happens with OTP is sometimes it gives absurdly roundabout routes. Here is OTP&amp;rsquo;s suggested route for walking from UP to Ateneo:&lt;/p&gt;
-
-&lt;p&gt;&lt;img src=&#34;../galleries/transit/otproundabout.png&#34; alt=&#34;Roundabout route from UP to Ateneo&#34; /&gt;&lt;/p&gt;
-
-&lt;p&gt;This is just so hilariously wrong. It&amp;rsquo;s much simpler to just walk along Katipunan Avenue.&lt;/p&gt;
-
-&lt;p&gt;OTP couldn&amp;rsquo;t possibly be that dumb though, so there must be something we&amp;rsquo;re doing wrong. If you notice, Katipunan Avenue is colored red compared to the other streets. OTP seems to be avoiding any path that goes along Katipunan Avenue. The problem might have something to do with the &amp;ldquo;road type&amp;rdquo; designated to Katipunan.&lt;/p&gt;
-
-&lt;p&gt;Apparently, by default OTP will consider roads of type &lt;code&gt;trunk&lt;/code&gt; to be non-walkable and non-bikable. This is documented in the &lt;a href=&#34;http://wiki.openstreetmap.org/wiki/OpenTripPlanner&#34;&gt;OpenStreetMap wiki&lt;/a&gt; and the &lt;a href=&#34;https://github.com/openplans/OpenTripPlanner/wiki/GraphBuilder#permissions-and-bicycle-safety&#34;&gt;OTP wiki&lt;/a&gt; as well. There are actually multiple ways to go about this then. The first solution that came to mind was to just edit the original OSM XML file.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;sed -i .bak s/trunk/primary/g manila.osm
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;And rebuild the graph. It doesn&amp;rsquo;t really matter much because the OSM data isn&amp;rsquo;t used to render the maps. It&amp;rsquo;s just used to build the routing data. This is actually what I did for &lt;a href=&#34;http://maps.pleasantprogrammer.com&#34;&gt;maps.pleasantprogrammer.com&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;It&amp;rsquo;s also possible to set the default way properties in OTP. Instead of disallowing walking and biking on &lt;code&gt;highway=trunk&lt;/code&gt; we could allow that. This is not much better than the &lt;code&gt;sed&lt;/code&gt; solution though. It&amp;rsquo;s better since you keep the weighting done by OTP, but you&amp;rsquo;re still saying that all trunks are walkable which might not be the case.&lt;/p&gt;
-
-&lt;p&gt;The most correct way to actually fix this is to go through each of the trunks and specifying &lt;code&gt;foot=yes&lt;/code&gt; and &lt;code&gt;bicycle=yes&lt;/code&gt; for those trunks that are actually walkable. You could either do this locally with the dumped data, or contribute it directly to OSM. I&amp;rsquo;m not sure on the particulars with updating OSM though.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/highways-in-otp.html</guid>
+      <description>One of the weird things that happens with OTP is sometimes it gives absurdly roundabout routes. Here is OTP&amp;rsquo;s suggested route for walking from UP to Ateneo:
+This is just so hilariously wrong. It&amp;rsquo;s much simpler to just walk along Katipunan Avenue.
+OTP couldn&amp;rsquo;t possibly be that dumb though, so there must be something we&amp;rsquo;re doing wrong. If you notice, Katipunan Avenue is colored red compared to the other streets. OTP seems to be avoiding any path that goes along Katipunan Avenue.</description>
     </item>
     
     <item>
       <title>Elevation Data in OTP</title>
-      <link>http://pleasantprogrammer.com/posts/elevation-data-in-otp.html</link>
+      <link>https://pleasantprogrammer.com/posts/elevation-data-in-otp.html</link>
       <pubDate>Tue, 23 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/elevation-data-in-otp.html</guid>
-      <description>&lt;p&gt;&lt;img src=&#34;../galleries/transit/otpelevation.png&#34; alt=&#34;OpenTripPlanner showing elevation data&#34; /&gt;&lt;/p&gt;
-
-&lt;p&gt;One thing I hadn&amp;rsquo;t tested out last time was OTP&amp;rsquo;s support for elevation data. It makes use of this by showing the elevation you have to traverse while walking along the suggested route. It can also take it into account when suggesting bike routes.&lt;/p&gt;
-
-&lt;p&gt;The &lt;a href=&#34;https://github.com/openplans/OpenTripPlanner/wiki/FiveMinutes&#34;&gt;5 minute tutorial&lt;/a&gt; actually discusses the elevation data briefly, but a more in-depth thing you can look at is the &lt;a href=&#34;https://github.com/openplans/OpenTripPlanner/wiki/GraphBuilder#elevation-data&#34;&gt;GraphBuilder documentation&lt;/a&gt;. It suggests using the ASTER dataset which is free but requires registration. I just opted to use the SRTM data available from the &lt;a href=&#34;http://www.philgis.org/freegisdata.htm&#34;&gt;PhilGIS website&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;I don&amp;rsquo;t know about the ASTER dataset, but the PhilGIS data was in the ERDAS img format. OTP only supports GeoTIFF so there was a need to convert it beforehand. You can use &lt;a href=&#34;http://www.gdal.org/&#34;&gt;GDAL&lt;/a&gt; for this. You&amp;rsquo;d just then run,&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;gdal_translate srtm41_90m_phl.img phil.tiff
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Afterwards, it&amp;rsquo;s just a matter of following the OTP instructions on using a local elevation dataset. The process actually doubled the size of the generated Graph.obj so it might not be ideal if you&amp;rsquo;re running on limited RAM.&lt;/p&gt;
-
-&lt;p&gt;I&amp;rsquo;ve actually hosted a &lt;a href=&#34;http://maps.pleasantprogrammer.com&#34;&gt;working example&lt;/a&gt;. It&amp;rsquo;s pretty much at the limits of the RAM so it might be slow and unreliable, but you can test it out just for fun. Please don&amp;rsquo;t abuse it though.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/elevation-data-in-otp.html</guid>
+      <description>One thing I hadn&amp;rsquo;t tested out last time was OTP&amp;rsquo;s support for elevation data. It makes use of this by showing the elevation you have to traverse while walking along the suggested route. It can also take it into account when suggesting bike routes.
+The 5 minute tutorial actually discusses the elevation data briefly, but a more in-depth thing you can look at is the GraphBuilder documentation. It suggests using the ASTER dataset which is free but requires registration.</description>
     </item>
     
     <item>
       <title>GraphServer</title>
-      <link>http://pleasantprogrammer.com/posts/graphserver.html</link>
+      <link>https://pleasantprogrammer.com/posts/graphserver.html</link>
       <pubDate>Tue, 23 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/graphserver.html</guid>
-      <description>&lt;p&gt;Link: &lt;a href=&#34;http://graphserver.github.io/graphserver/&#34;&gt;http://graphserver.github.io/graphserver/&lt;/a&gt;&lt;/p&gt;
-
-&lt;p&gt;One other routing webapp I saw was GraphServer. It&amp;rsquo;s actually more of a general purpose Graph library which supports GTFS and OSM data than an actual dedicated routing software like OpenTripPlanner. It&amp;rsquo;s also based off python and C instead of Java, so it feels a lot less heavy.&lt;/p&gt;
-
-&lt;p&gt;The instructions on the website are already pretty good. There are just some minor errors with it. Where it says &lt;code&gt;gs_gtfsdb_build&lt;/code&gt;, you should actually use &lt;code&gt;gs_gtfsdb_compile&lt;/code&gt;. Also, when running &lt;code&gt;gs_osmdb_compile&lt;/code&gt; you might need to use &lt;code&gt;-t&lt;/code&gt; for tolerant in case you follow the instructions on chopping up the original OSM data.&lt;/p&gt;
-
-&lt;p&gt;A nice suggestion from the GraphServer instructions was to crop the OSM data to minimize the graph size. This is actually quite helpful if you downloaded the entire Philippine OSM dump. It reduced the original 900MB file to 135MB which was a lot more workable. I did hit a problem with their instructions though. The linked version of osmosis is an old one, which doesn&amp;rsquo;t support 64-bit ids. The &lt;a href=&#34;http://wiki.openstreetmap.org/wiki/Osmosis&#34;&gt;latest version of Osmosis&lt;/a&gt; easily did the job though.&lt;/p&gt;
-
-&lt;p&gt;The actual routing though, was not exactly good. I only tried one route which should normally take 1-2 transfers, it suggested a route which involved 4+ transfers. It also didn&amp;rsquo;t provide any alternate routes aside from that one. I&amp;rsquo;m not sure if it&amp;rsquo;s a limitation of the provided routeserver, but I didn&amp;rsquo;t bother checking if it supported parameters which might provide better routes.&lt;/p&gt;
-
-&lt;p&gt;I think graphserver could be useful, but it seems more involved than say OpenTripPlanner. There do seem to be people who use graphserver for their routing apps, but for the bounds of the contest, or just as a side project, it might require too much effort.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/graphserver.html</guid>
+      <description>Link: http://graphserver.github.io/graphserver/
+One other routing webapp I saw was GraphServer. It&amp;rsquo;s actually more of a general purpose Graph library which supports GTFS and OSM data than an actual dedicated routing software like OpenTripPlanner. It&amp;rsquo;s also based off python and C instead of Java, so it feels a lot less heavy.
+The instructions on the website are already pretty good. There are just some minor errors with it. Where it says gs_gtfsdb_build, you should actually use gs_gtfsdb_compile.</description>
     </item>
     
     <item>
       <title>Transit Wand</title>
-      <link>http://pleasantprogrammer.com/posts/transit-wand.html</link>
+      <link>https://pleasantprogrammer.com/posts/transit-wand.html</link>
       <pubDate>Mon, 15 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/transit-wand.html</guid>
-      <description>&lt;p&gt;Link: &lt;a href=&#34;https://play.google.com/store/apps/details?id=com.conveyal.transitwand&#34;&gt;http://transitwand.com&lt;/a&gt;&lt;/p&gt;
-
-&lt;p&gt;Overall, this was the simplest of the &lt;a href=&#34;http://philippine-transit.hackathome.com/use-this-code/&#34;&gt;open-source transit tools&lt;/a&gt; to actually get up and running. There&amp;rsquo;s already a deployed instance of the server, and you can easily download the phone app via the &lt;a href=&#34;https://play.google.com/store/apps/details?id=com.conveyal.transitwand&#34;&gt;Play Store&lt;/a&gt;. Even running the server by yourself didn&amp;rsquo;t have any of the hiccups I had with GTFS Editor.&lt;/p&gt;
-
-&lt;p&gt;The phone app is actually quite simple. It allows you to capture a trip, which will record your GPS coordinates as you ride public transit. It also allows you to mark points of the trip where you stop and also how long the stop took. Lastly, it allows you to record embarking and disembarking passengers which is potentially useful for ridership data.&lt;/p&gt;
-
-&lt;p&gt;After doing a capture session, you can review the data on the phone. It will plot out the route on a map, with markers for the stops. You then either delete the data if it looks wrong, or you can upload it to the Transit Wand server. Uploading involves registering an account, but it&amp;rsquo;s free and you don&amp;rsquo;t even actually need to put in a username or anything. It simply registers the phone&amp;rsquo;s IMEI on the server and gives you a 6-digit identifier.&lt;/p&gt;
-
-&lt;p&gt;You can then use the 6-digit identifier to view the data on Transit Wand&amp;rsquo;s server, which is good since uploading any data automatically deletes it from the phone. There really isn&amp;rsquo;t much else you can do with it though. It just allows you to view the data, and export it as a &lt;a href=&#34;https://en.wikipedia.org/wiki/Shapefile&#34;&gt;Shapefile&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;As is, this is purely a data collection client-server app. Barring looking at the database, there is no way to get a list of phones which have collected data. Only the person who initiated the data collection knows the 6-digit code to view their data. There&amp;rsquo;s also no way to extract the ridership information from the server yet. This isn&amp;rsquo;t to say that the data won&amp;rsquo;t eventually go public though.&lt;/p&gt;
-
-&lt;p&gt;An interesting thing you &lt;em&gt;can&lt;/em&gt; do with the Transit Wand data is import it into GTFS Editor to make a new route. You don&amp;rsquo;t even have to manually download and upload the data. Just type in your 6-digit identifier and it will give you a list of routes you&amp;rsquo;ve captured via Transit Wand. This is wonderful as you get all the stop data, as well as the shape of the route.&lt;/p&gt;
-
-&lt;p&gt;I imagine these two tools were how the DOTC came up with all the GTFS data we have now. What I don&amp;rsquo;t understand is why the shape data isn&amp;rsquo;t present. Importing from Transit Wand already gets you shape data. There are even facilities to edit the shape within the editor if clean up is necessary. The only problem I saw was the fact that you can&amp;rsquo;t easily move stops, you have to input coordinates to change the position.&lt;/p&gt;
-
-&lt;p&gt;It &lt;em&gt;might&lt;/em&gt; also be possible that when the DOTC was still collecting the data, the route collection or editing features weren&amp;rsquo;t present yet. That would just be lame and depressing though.&lt;/p&gt;
-
-&lt;p&gt;Overall, Transit Wand does what it&amp;rsquo;s supposed to do. You collect data, and then upload it to a server. There is a lot of room for improvement though. It would be nice to have a better API that allows access to more of the data. Building in analysis tools for the ridership data might also be a welcome thing. I imagine it would also be great if you could encourage people to use the app and upload their own trips.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/transit-wand.html</guid>
+      <description>Link: http://transitwand.com
+Overall, this was the simplest of the open-source transit tools to actually get up and running. There&amp;rsquo;s already a deployed instance of the server, and you can easily download the phone app via the Play Store. Even running the server by yourself didn&amp;rsquo;t have any of the hiccups I had with GTFS Editor.
+The phone app is actually quite simple. It allows you to capture a trip, which will record your GPS coordinates as you ride public transit.</description>
     </item>
     
     <item>
       <title>Fare Data</title>
-      <link>http://pleasantprogrammer.com/posts/fare-data.html</link>
+      <link>https://pleasantprogrammer.com/posts/fare-data.html</link>
       <pubDate>Sat, 13 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/fare-data.html</guid>
-      <description>
-
-&lt;p&gt;As part of the data released by the DOTC, we also have the &lt;a href=&#34;http://philippine-transit.hackathome.com/dataset-philippines-transit-information-service-gtfs/&#34;&gt;fare matrix&lt;/a&gt; for aircon buses, ordinary buses and jeeps. All as wonderful images. The data is also actually available from the &lt;a href=&#34;http://ltfrb.gov.ph/main/farerates&#34;&gt;LTFRB website&lt;/a&gt;. Generally, the fare scheme is represented as &amp;ldquo;pay &lt;em&gt;X&lt;/em&gt; pesos for the first &lt;em&gt;Y&lt;/em&gt; kilometers, pay &lt;em&gt;Z&lt;/em&gt; for every succeeding kilometer.&amp;rdquo; Instead of a table, we can simply represent this as a formula instead,&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;base_fare + (distance - initial) * per_km
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;The relevant values for the three services are:&lt;/p&gt;
-
-&lt;table&gt;
-&lt;thead&gt;
-  &lt;tr&gt;
-    &lt;td&gt;type&lt;/td&gt;
-    &lt;td&gt;base_fare&lt;/td&gt;
-    &lt;td&gt;initial&lt;/td&gt;
-    &lt;td&gt;per_km&lt;/td&gt;
-  &lt;/tr&gt;
-&lt;/thead&gt;
-&lt;tbody&gt;
-  &lt;tr&gt;
-    &lt;td&gt;bus aircon&lt;/td&gt;
-    &lt;td&gt;12.00&lt;/td&gt;
-    &lt;td&gt;5 km&lt;/td&gt;
-    &lt;td&gt;2.20&lt;/td&gt;
-  &lt;/tr&gt;
-  &lt;tr&gt;
-    &lt;td&gt;bus ordinary&lt;/td&gt;
-    &lt;td&gt;10.00&lt;/td&gt;
-    &lt;td&gt;5 km&lt;/td&gt;
-    &lt;td&gt;1.85&lt;/td&gt;
-  &lt;/tr&gt;
-  &lt;tr&gt;
-    &lt;td&gt;jeep aircon&lt;/td&gt;
-    &lt;td&gt;8.00&lt;/td&gt;
-    &lt;td&gt;4 km&lt;/td&gt;
-    &lt;td&gt;1.40&lt;/td&gt;
-  &lt;/tr&gt;
-&lt;/tbody&gt;
-&lt;/table&gt;
-
-&lt;p&gt;It isn&amp;rsquo;t as simple as that though. Fares are also rounded to the nearest 25 centavos. So we&amp;rsquo;d need to round them off correctly. This can be achieved by doing,&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;round(calculated_fare * 4.0)/4.0
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;There&amp;rsquo;s also the discounted fare for students, senior citizens and persons with disability. They get 20% off the fare (prior to rounding) and the resulting fare is rounded off as well.&lt;/p&gt;
-
-&lt;p&gt;Doing just this, we actually do get the same results as the fare matrices in the image for the most part. There are some discrepancies with the discounted jeep fares. I&amp;rsquo;ve tried to resolve it by tweaking around with the formulas, but it really doesn&amp;rsquo;t make sense in any way. I presume these were manually adjusted for one reason or another.&lt;/p&gt;
-
-&lt;p&gt;Here&amp;rsquo;s a &lt;a href=&#34;../uploads/farematrix.rb&#34;&gt;script&lt;/a&gt; that generates CSVs of all the three fare matrices. If you&amp;rsquo;re too lazy to run it, here are links to the &lt;a href=&#34;../uploads/pub_aircon.csv&#34;&gt;aircon bus&lt;/a&gt;, &lt;a href=&#34;../uploads/pub_ordinary.csv&#34;&gt;ordinary bus&lt;/a&gt; and &lt;a href=&#34;../uploads/puj.csv&#34;&gt;jeep&lt;/a&gt; fare matrices.&lt;/p&gt;
-
-&lt;h3 id=&#34;gtfs-compatibility&#34;&gt;GTFS compatibility&lt;/h3&gt;
-
-&lt;p&gt;As is, the provided GTFS data does not have any fare data. I imagine this is because the existing spec doesn&amp;rsquo;t have good support for distance-based fares like we have in the Philippines. Judging from the &lt;a href=&#34;https://code.google.com/p/googletransitdatafeed/wiki/FareExamples&#34;&gt;fare examples&lt;/a&gt;, the only reasonable way we could implement distance-based fares is following example 6. This would involve setting a fare for each possible pair of stops based on the distance between them. This isn&amp;rsquo;t exactly ideal. In fact, the people originally working on the DOTC project have voiced &lt;a href=&#34;https://groups.google.com/forum/#!topic/gtfs-fare-wg/V63xRSnQJGw&#34;&gt;issues&lt;/a&gt; and made &lt;a href=&#34;https://groups.google.com/forum/#!msg/gtfs-changes/uybrAokZ9Cg/rqlzXdMypUgJ&#34;&gt;proposals&lt;/a&gt; for having distance-based fares included into GTFS.&lt;/p&gt;
-
-&lt;p&gt;Apparently, public transit fares are a really complicated thing. You have fares based on distance, number of stops passed through, and transfers which may or may not cost extra. Not only that, you might have discounted fares, or first-class vs economy fares. The community will want to get it right before it&amp;rsquo;s formally included in the spec. You can see the current state of the consolidated &lt;a href=&#34;https://docs.google.com/document/d/1mK3--o5g4-3cCXaqmch92U63JTwChh0L2VCmcDViIlM/edit&#34;&gt;GTFS fare proposal here&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;Even in it&amp;rsquo;s proposal form though, we might have hope of being able to see these being used. There&amp;rsquo;s currently a &lt;a href=&#34;https://github.com/OneBusAway/onebusaway-gtfs-modules/pull/30&#34;&gt;pull request&lt;/a&gt; for supporting the distance-based fare scheme into the OneBusAway libraries. The libraries actually used by GTFS Editor and OpenTripPlanner for working with GTFS data.&lt;/p&gt;
-
-&lt;h3 id=&#34;remaining-problems&#34;&gt;Remaining Problems&lt;/h3&gt;
-
-&lt;p&gt;Given all that, it would probably still be a long way before this allows us to make a really good routing app. We still don&amp;rsquo;t have shape data, so the distance estimates would really be rough estimates at best. There&amp;rsquo;s no support for rounding to the nearest centavo. I realize that&amp;rsquo;s just nitpicking, but if we want something truly polished, even that has to be taken care of.&lt;/p&gt;
-
-&lt;p&gt;We also don&amp;rsquo;t know if the jeeps or buses strictly follow the distance-based scheme. After all, if you can get on and off anywhere, you can&amp;rsquo;t really measure distance that exactly. I assume they generally work off the notion of &amp;ldquo;zones&amp;rdquo; than actual distance travelled. In that sense, they work more similarly to the LRT which has fares based on how many stops you pass. For jeeps and buses, your fare is probably based more on how many &amp;ldquo;zones&amp;rdquo; you pass through.&lt;/p&gt;
-
-&lt;h3 id=&#34;conclusion&#34;&gt;Conclusion&lt;/h3&gt;
-
-&lt;p&gt;Philip, a co-worker of mine at By Implication, had suggested that we might want to use a different model than what the GTFS proposes. I have to agree with him. At this point, the GTFS doesn&amp;rsquo;t really fit with our system. But I do think that open data and standards are great. In fact, I applaud the developers who made proposals for the fare system, as those are great first steps towards making the GTFS a more universal standard.&lt;/p&gt;
-
-&lt;p&gt;Side note: I&amp;rsquo;d also actually really like to hear about the DOTC developers&amp;rsquo; experience with the project. It would be nice if they had a devblog.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/fare-data.html</guid>
+      <description>As part of the data released by the DOTC, we also have the fare matrix for aircon buses, ordinary buses and jeeps. All as wonderful images. The data is also actually available from the LTFRB website. Generally, the fare scheme is represented as &amp;ldquo;pay X pesos for the first Y kilometers, pay Z for every succeeding kilometer.&amp;rdquo; Instead of a table, we can simply represent this as a formula instead,</description>
+    </item>
+    
+    <item>
+      <title>GTFS Editor</title>
+      <link>https://pleasantprogrammer.com/posts/gtfs-editor.html</link>
+      <pubDate>Wed, 10 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/gtfs-editor.html</guid>
+      <description>Link: https://github.com/conveyal/gtfs-editor
+TL;DR they really meant under development
+When I first saw the source of GTFS Editor, I was ecstatic. They used Play framework!!! Not only that, they&amp;rsquo;re targeting PostgreSQL as the main database. Those are our favorite tools for building webapps at By Implication. I was a bit sad though, when I saw it was on the 1.x release of Play though. I did have some experience with that release, but not as much compared to 2.</description>
+    </item>
+    
+    <item>
+      <title>One Bus (or maybe Jeep) Away</title>
+      <link>https://pleasantprogrammer.com/posts/one-bus-or-maybe-jeep-away.html</link>
+      <pubDate>Tue, 09 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/one-bus-or-maybe-jeep-away.html</guid>
+      <description>Link: http://onebusaway.org/
+TL;DR no routing; useless in Philippines
+OneBusAway is a transit information app. It provides data on what bus stops are near you, which buses pass by. You can also get schedules and the route of a particular bus given the number. It can also provide realtime updates like how many minutes until the next bus arrives. It does not, however, provide routing. There is no support for providing directions to get from point A to point B.</description>
+    </item>
+    
+    <item>
+      <title>Open Trip Planner</title>
+      <link>https://pleasantprogrammer.com/posts/open-trip-planner.html</link>
+      <pubDate>Tue, 09 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/open-trip-planner.html</guid>
+      <description>Link: http://www.opentripplanner.org
+TL;DR routes pretty well; data might cause weird issues
+OpenTripPlanner, as the name implies, is a routing app. Given point A and point B, it can provide possible routes by taking transit, riding a bike, or a mix of both. You can also specify options on how much walking you&amp;rsquo;re willing to do or if you prefer fewer transfers over trip time. It could be a good competitor to the transit directions of Google Maps.</description>
+    </item>
+    
+    <item>
+      <title>Jeepney and Bus Routes</title>
+      <link>https://pleasantprogrammer.com/posts/jeepney-and-bus-routes.html</link>
+      <pubDate>Sun, 07 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/jeepney-and-bus-routes.html</guid>
+      <description>In the last post, I talked about how we now have data about jeepney and bus routes in the Philippines. The data is actually in the GTFS format, which is the format the Google Maps consumes transit data. Apparently, the government will be submitting the GTFS data later this year. Transit directions for Metro Manila in Google Maps would be wonderful. That said, it definitely raises the bar for the app challenge people.</description>
+    </item>
+    
+    <item>
+      <title>Philippine Transit App Challenge</title>
+      <link>https://pleasantprogrammer.com/posts/philippine-transit-app-challenge.html</link>
+      <pubDate>Sun, 07 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/philippine-transit-app-challenge.html</guid>
+      <description>Last week, the DOTC launched the Philippine Transit App Challenge. It&amp;rsquo;s a competition to build something great using the newly available 1) jeepney/bus/rail routes and 2) traffic incident data in Metro Manila and Cebu.
+I&amp;rsquo;m actually quite excited about this as it&amp;rsquo;s not everyday our government does wonderful things. Many people have been waiting for this kind of data to be available. Before, the only way to figure out which jeeps to ride to get from A to B is by asking other people.</description>
     </item>
     
   </channel>

+ 21 - 28
output/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -63,23 +64,23 @@
 <h2 id="setting-up-tiddlywiki">Setting Up TiddlyWiki</h2>
 
 <p>TiddlyWiki5 provides a command line tool via <code>npm</code> that allows building custom versions of the wiki. In fact, it comes with templates, called &ldquo;editions&rdquo;, that we can use for our setup. Assuming you already have it installed, create the wiki using</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>tiddlywiki mywiki --init tw5tank          <span style="color: #408080; font-style: italic"># create wiki from template</span>
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>tiddlywiki mywiki --init tw5tank          <span style="color: #408080; font-style: italic"># create wiki from template</span>
+</code></pre></div>
 
 <p>This creates a wiki intended for use with <a href="https://tank.peermore.com/">Tank</a>, which is built on top of TiddlyWeb. From here, you should look in <code>mywiki/tiddlers/system</code> which contain the entries for <code>SiteTitle</code>, <code>SiteSubtitle</code>, <code>DefaultTiddlers</code>, and <code>tiddlyweb-host</code>. The first 3 should be configured however you want. These are necessary because they&rsquo;re needed before the wiki can load them from the server. <code>tiddlyweb-host</code> contains the location of the TiddlyWeb server, this should be <code>http://localhost:8080/</code> if you&rsquo;re just testing locally. With everything configured, you can build the new wiki by running</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>tiddlywiki mywiki --build
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>tiddlywiki mywiki --build
+</code></pre></div>
 
 <p>This will output the wiki to <code>mywiki/output/tw5tank.html</code>. You can now serve it using your favorite local webserver, like <code>python -m http.server</code>.</p>
 
 <h2 id="setting-up-tiddlyweb">Setting Up TiddlyWeb</h2>
 
 <p>The TiddlyWeb tutorial recommends using <code>tiddlywebwiki</code> which has all the plugins setup for a nice wiki instance for the old TiddlyWiki. It has a lot of features that aren&rsquo;t really needed, so we won&rsquo;t go with that. So first, we&rsquo;ll need to install TiddlyWeb and any plugins we might want to use.</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>pip install tiddlyweb tiddlywebplugins.status tiddlywebplugins.cherrypy tiddlywebplugins.cors
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>pip install tiddlyweb tiddlywebplugins.status tiddlywebplugins.cherrypy tiddlywebplugins.cors
+</code></pre></div>
 
 <p>Next, we&rsquo;ll need the tiddlyweb configuration in <code>tiddlywebconfig.py</code></p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #408080; font-style: italic"># A basic configuration.</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-python" data-lang="python"><span></span><span style="color: #408080; font-style: italic"># A basic configuration.</span>
 <span style="color: #408080; font-style: italic"># `pydoc tiddlyweb.config` for details on configuration items.</span>
 
 <span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">tiddlywebplugins.status</span>
@@ -99,7 +100,7 @@ original_gather_data <span style="color: #666666">=</span> tiddlywebplugins<span
     <span style="color: #008000; font-weight: bold">return</span> data
 
 tiddlywebplugins<span style="color: #666666">.</span>status<span style="color: #666666">.</span>_gather_data <span style="color: #666666">=</span> _status_gather_data
-</pre></div>
+</code></pre></div>
 
 <p>The tweaks involved are:</p>
 
@@ -111,7 +112,7 @@ tiddlywebplugins<span style="color: #666666">.</span>status<span style="color: #
 </ul>
 
 <p>With that, we just need to create the store that will hold our data</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>twanager recipe default <span style="color: #BA2121">&lt;&lt;EOF</span>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>twanager recipe default <span style="color: #BA2121">&lt;&lt;EOF</span>
 <span style="color: #BA2121">desc: standard TiddlyWebWiki environment</span>
 <span style="color: #BA2121">policy: {&quot;read&quot;: [], &quot;create&quot;: [], &quot;manage&quot;: [&quot;R:ADMIN&quot;], &quot;accept&quot;: [], &quot;write&quot;: [&quot;R:ADMIN&quot;], &quot;owner&quot;: &quot;administrator&quot;, &quot;delete&quot;: [&quot;R:ADMIN&quot;]}</span>
 
@@ -121,11 +122,11 @@ tiddlywebplugins<span style="color: #666666">.</span>status<span style="color: #
 twanager bag default <span style="color: #BA2121">&lt;&lt;EOF</span>
 <span style="color: #BA2121">{&quot;policy&quot;: {&quot;read&quot;: [], &quot;create&quot;: [], &quot;manage&quot;: [&quot;R:ADMIN&quot;], &quot;accept&quot;: [], &quot;write&quot;: [], &quot;owner&quot;: &quot;administrator&quot;, &quot;delete&quot;: []}}</span>
 <span style="color: #BA2121">EOF</span>
-</pre></div>
+</code></pre></div>
 
 <p>Finally, we can start the TiddlyWeb server</p>
-<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>twanager server
-</pre></div>
+<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><code class="language-sh" data-lang="sh"><span></span>twanager server
+</code></pre></div>
 
 <h2 id="putting-it-all-together">Putting it all together</h2>
 
@@ -153,21 +154,13 @@ twanager bag default <span style="color: #BA2121">&lt;&lt;EOF</span>
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html';
-var disqus_title = 'TiddlyWiki in the Sky (or TiddlyWeb for TW5)';
-var disqus_identifier = 'cache/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -178,7 +171,7 @@ var disqus_identifier = 'cache/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 9 - 16
output/posts/transit-wand.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -88,21 +89,13 @@
 		</nav>
 	</aside>
 	<section class="comments">
-		<div id="disqus_thread"></div>
-<script type="text/javascript">
-var disqus_shortname = 'pleasantprog';
-var disqus_url = 'http:\/\/pleasantprogrammer.com\/posts\/transit-wand.html';
-var disqus_title = 'Transit Wand';
-var disqus_identifier = 'cache/posts/transit-wand.html';
-
-(function() {
-    var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
-    dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
-    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
-})();
+		<script
+	data-isso="https://isso.pleasantprogrammer.com/"
+	data-isso-require-author="true"
+	data-isso-vote="false"
+	src="https://isso.pleasantprogrammer.com/js/embed.min.js">
 </script>
-<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
-<a href="http://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
+<section id="isso-thread"></section>
 
 	</section>
 </article>
@@ -113,7 +106,7 @@ var disqus_identifier = 'cache/posts/transit-wand.html';
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>
 

+ 127 - 692
output/rss.xml

@@ -2,790 +2,225 @@
 <rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
   <channel>
     <title>Pleasant Programmer</title>
-    <link>http://pleasantprogrammer.com/rss.xml</link>
+    <link>https://pleasantprogrammer.com/</link>
     <description>Recent content on Pleasant Programmer</description>
     <generator>Hugo -- gohugo.io</generator>
     <language>en-us</language>
-    <lastBuildDate>Sun, 19 Nov 2017 22:00:00 +0800</lastBuildDate>
-    <atom:link href="http://pleasantprogrammer.com/rss.xml" rel="self" type="application/rss+xml" />
+    <lastBuildDate>Sat, 10 Feb 2018 16:47:55 +0900</lastBuildDate>
+    
+	<atom:link href="https://pleasantprogrammer.com/rss.xml" rel="self" type="application/rss+xml" />
+    
+    
+    <item>
+      <title>Projects</title>
+      <link>https://pleasantprogrammer.com/pages/projects.html</link>
+      <pubDate>Sat, 10 Feb 2018 16:47:55 +0900</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/pages/projects.html</guid>
+      <description>I&amp;rsquo;ve made a lot of things in my free time mostly to try out new web technologies. I&amp;rsquo;ve also made some non-web things as well, but those aren&amp;rsquo;t as easy to show off.
+Datalinks The Datalinks is a recreation of the in-game manual of Sid Meier&amp;rsquo;s Alpha Centauri. I really like the game, particularly how well the setting and atmosphere was done. The voice quotes whenever you discover a new technology were what really made the game for me and I&amp;rsquo;ve included those into the site.</description>
+    </item>
     
     <item>
       <title>Audventure</title>
-      <link>http://pleasantprogrammer.com/posts/audventure.html</link>
+      <link>https://pleasantprogrammer.com/posts/audventure.html</link>
       <pubDate>Sun, 19 Nov 2017 22:00:00 +0800</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/audventure.html</guid>
-      <description>
-
-&lt;p&gt;Sometime around 2013 I wrote a clone of the GBA game &lt;a href=&#34;https://www.nintendo.co.jp/n08/bit_g/&#34;&gt;bit Generations
-SoundVoyager&lt;/a&gt; called
-&lt;a href=&#34;https://audventure.pleasantprogrammer.com&#34;&gt;audventure&lt;/a&gt;. SoundVoyager is
-actually a collection of mini-games where sound is the main focus. You can
-actually play the game blind, and at some point, that&amp;rsquo;s pretty much what
-happens.&lt;/p&gt;
-
-&lt;h2 id=&#34;sound-catcher&#34;&gt;sound catcher&lt;/h2&gt;
-
-&lt;p&gt;The signature mini-game in SoundVoyager is sound catcher. In the mini-game, you
-can only move left and right at the bottom of the stage, while a &amp;ldquo;sound&amp;rdquo; falls
-from the top. Your goal is to catch the sound which is signified by a green dot.
-When you catch it, the sound or beat becomes part of the BGM and a new dot
-appears with a different sound.&lt;/p&gt;
-
-&lt;p&gt;You can of course use your eyes and move accordingly, but if you put on
-earphones, you can actually hear where the dot is, either on your left or right,
-with it getting louder as it gets close to you. As you collect more sounds, the
-dot gets more and more transparent. Eventually (and this is where it gets fun),
-you won&amp;rsquo;t be able to see the sounds anymore and will have to rely mostly on your
-ears.&lt;/p&gt;
-
-&lt;p&gt;You can see what the original game looks like in &lt;a href=&#34;https://www.youtube.com/watch?v=C12WRgfIOC8&#34;&gt;this
-video&lt;/a&gt; or you can play it under
-&lt;em&gt;sound safari&lt;/em&gt; in &lt;a href=&#34;https://audventure.pleasantprogrammer.com&#34;&gt;audventure&lt;/a&gt;.&lt;/p&gt;
-
-&lt;h2 id=&#34;webaudio-vs-flash&#34;&gt;WebAudio vs Flash&lt;/h2&gt;
-
-&lt;p&gt;At the time I wrote audventure, only Chrome supported WebAudio. Also, the API
-looked (and still looks) quite complicated. Flash on the other hand, was
-starting to die, but still well-supported so I went with that. For the most
-part, it worked okay though Chrome actually had timing issues when playing
-sounds. Now, it doesn&amp;rsquo;t work in any browser. I tried to debug the issues but
-ultimately ended up just rewriting it to use WebAudio instead.&lt;/p&gt;
-
-&lt;p&gt;For the game, I needed to simulate the source of the sound in 2D/3D space. Flash
-only really gives you stereo panning and volume control. With some maths, we can
-actually get an acceptable solution. Less importantly, I needed to be able to
-get frequency data of the currently playing &amp;ldquo;sound&amp;rdquo; to pulse the background. For
-this, I actually had to implement the feature in the Flash library I was using.&lt;/p&gt;
-
-&lt;p&gt;With WebAudio, spatial audio is already built-in and you can simply give it the
-coordinates of the sounds and the listener. There are some other options to
-tweak, but for the most part, no complex math is needed. Getting frequency data
-for a sound is also actually built-in and didn&amp;rsquo;t take too long to integrate.&lt;/p&gt;
-
-&lt;p&gt;Overall, I was impressed by how much you can do with WebAudio out-of-the-box. I
-kind of understand why it&amp;rsquo;s complicated, but there&amp;rsquo;s some simple functionality
-that I wish was included. For example, there is no API to pause and then resume
-playing an audio buffer. You have to manually save the elapsed time and play
-from there.&lt;/p&gt;
-
-&lt;h2 id=&#34;other-mini-games&#34;&gt;Other mini-games&lt;/h2&gt;
-
-&lt;p&gt;So far I&amp;rsquo;ve only actually implemented the sound catcher mini-game. There are
-around 4 different categories with slight variations in between.&lt;/p&gt;
-
-&lt;h3 id=&#34;sound-catcher-sound-slalom&#34;&gt;sound catcher / sound slalom&lt;/h3&gt;
-
-&lt;p&gt;I&amp;rsquo;ve explained sound catcher a while ago; sound slalom is a minor variation on
-that. Instead of waiting for the &amp;ldquo;sound&amp;rdquo; to reach you, you now have to guide
-yourself in between 2 &amp;ldquo;poles&amp;rdquo; of sound, as in &lt;a href=&#34;https://en.wikipedia.org/wiki/Slalom_skiing&#34;&gt;slalom
-skiing&lt;/a&gt;. But this time, you can
-also accelerate forward. The goal is to finish the course before the time runs
-out.&lt;/p&gt;
-
-&lt;h3 id=&#34;sound-drive-sound-chase&#34;&gt;sound drive / sound chase&lt;/h3&gt;
-
-&lt;p&gt;In sound drive, you&amp;rsquo;re driving against the flow on a 5 lane road. You have to
-avoid oncoming cars, trucks and animals until you reach the end. You&amp;rsquo;re allowed
-to change lanes and accelerate, and the game tracks your best time. Sound chase
-is pretty much the same, except you&amp;rsquo;re trying to catch up to a &amp;ldquo;sound&amp;rdquo;.&lt;/p&gt;
-
-&lt;h3 id=&#34;sound-cannon&#34;&gt;sound cannon&lt;/h3&gt;
-
-&lt;p&gt;In sound cannon, you&amp;rsquo;re immobile but can rotate within a 180 degree angle. Your
-goal is too shoot down &amp;ldquo;sounds&amp;rdquo; which are heading your way. If a sound reaches
-you, it&amp;rsquo;s game over. You win when you kill all the sounds.&lt;/p&gt;
-
-&lt;h3 id=&#34;sound-picker-sound-cock&#34;&gt;sound picker / sound cock&lt;/h3&gt;
-
-&lt;p&gt;In sound picker, you can move in a giant square field where various sounds are
-scattered around. Your goal is to pick up all the sounds within the time limit.
-Sound cock is similar, except the sounds are chickens and you have to chase them
-around.&lt;/p&gt;
-
-&lt;h2 id=&#34;source-code&#34;&gt;Source Code&lt;/h2&gt;
-
-&lt;p&gt;If you want to see the source code, you can check it out
-&lt;a href=&#34;https://git.pleasantprogrammer.com/games/audventure&#34;&gt;here&lt;/a&gt;. The sound files
-aren&amp;rsquo;t in the repo though, since I&amp;rsquo;m not quite sure about the licensing. If you
-want to contribute music or sound effects, I&amp;rsquo;d gladly appreciate it.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/audventure.html</guid>
+      <description>Sometime around 2013 I wrote a clone of the GBA game bit Generations SoundVoyager called audventure. SoundVoyager is actually a collection of mini-games where sound is the main focus. You can actually play the game blind, and at some point, that&amp;rsquo;s pretty much what happens.
+sound catcher The signature mini-game in SoundVoyager is sound catcher. In the mini-game, you can only move left and right at the bottom of the stage, while a &amp;ldquo;sound&amp;rdquo; falls from the top.</description>
     </item>
     
     <item>
       <title>OpenPrepPad</title>
-      <link>http://pleasantprogrammer.com/posts/openpreppad.html</link>
+      <link>https://pleasantprogrammer.com/posts/openpreppad.html</link>
       <pubDate>Sun, 15 Jan 2017 19:31:00 +0800</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/openpreppad.html</guid>
-      <description>
-
-&lt;p&gt;Smart electronics and IoT (Internet of Things) are all the rage these days. You
-have a lot of companies sprout up trying to make the next big thing, which also
-leads to a lot of failures big and small. Pebble, the maker of my smartwatch,
-got bought out by Fitbit recently. This left watch owners without any official
-support, but thankfully, community members &lt;a href=&#34;http://rebble.io/&#34;&gt;stepped up&lt;/a&gt; to continue
-maintaining it.&lt;/p&gt;
-
-&lt;p&gt;Another casualty of the IoT boom was the &lt;a href=&#34;http://theorangechef.com/&#34;&gt;Orange Chef&lt;/a&gt; &lt;a href=&#34;https://www.amazon.com/Orange-Chef-Smart-Scale-Silver/dp/B00KFW8L90&#34;&gt;Prep Pad&lt;/a&gt;. It&amp;rsquo;s a
-bluetooth connected weighing scale to make it easy to track your calories and
-carb/fat/protein intake. My dad bought it last year only to find out that the
-app was incredibly buggy. The search function doesn&amp;rsquo;t work which makes the whole
-thing practically useless. I also found out later that you can&amp;rsquo;t even download
-the app to use the scale anymore.&lt;/p&gt;
-
-&lt;p&gt;&lt;strong&gt;Note&lt;/strong&gt; I just found out as I was writing this post that it &lt;em&gt;may&lt;/em&gt; get supported
-by &lt;a href=&#34;http://www.prnewswire.com/news-releases/perfect-company-acquires-orange-chefs-prep-pad-related-ip-continues-momentum-in-the-connected-kitchen-300383178.html&#34;&gt;another company&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;So the app is useless, but at least you can use it as a scale, right?&lt;/p&gt;
-
-&lt;p&gt;&lt;img src=&#34;http://pleasantprogrammer.com/galleries/openpreppad/preppad.jpg&#34; alt=&#34;Prep Pad&#34; /&gt;&lt;/p&gt;
-
-&lt;p&gt;Nope. The device has no display whatsoever. The only controls on it are the
-on/off button and a green LED that isn&amp;rsquo;t even that useful at telling you whether
-it&amp;rsquo;s on or not. At this point, it&amp;rsquo;s just a giant paperweight.&lt;/p&gt;
-
-&lt;h2 id=&#34;reverse-engineering&#34;&gt;Reverse Engineering&lt;/h2&gt;
-
-&lt;p&gt;Since I essentially had nothing to lose, I tried poking at the thing to figure
-out how it works. I didn&amp;rsquo;t really have experience with bluetooth besides trying
-to get my bluetooth mouse connected on Linux. The main thing I used then was
-&lt;code&gt;bluetoothctl&lt;/code&gt; which is essentially a CLI for managing bluetooth devices so I
-started there.&lt;/p&gt;
-
-&lt;p&gt;I started up &lt;code&gt;bluetoothctl&lt;/code&gt; and turned on the Prep Pad. And it showed up!&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[bluetooth]# power on
-[CHG] Controller ... Class: 0x00010c
-Changing power on succeeded
-[CHG] Controller ... Powered: yes
-[bluetooth]# scan on
-Discovery started
-[CHG] Device 1C:BA:8C:21:7C:BB RSSI: -51
-[CHG] Device 1C:BA:8C:21:7C:BB Name: CHSLEEV_00
-[CHG] Device 1C:BA:8C:21:7C:BB Alias: CHSLEEV_00
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;I then connected to it, which was surprisingly easy.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[bluetooth]# connect 1C:BA:8C:21:7C:BB
-Attempting to connect to 1C:BA:8C:21:7C:BB
-[CHG] Device 1C:BA:8C:21:7C:BB Connected: yes
-[CHG] Device 1C:BA:8C:21:7C:BB Name: CH BTScale_00
-[CHG] Device 1C:BA:8C:21:7C:BB Alias: CH BTScale_00
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Now normally, when you turn the device on, the green light flashes occasionally.
-Once I connected to it, the green light stayed on permanently. Clearly, I was
-making progress. A lot of services were also discovered but I had no idea what
-those things were at that point.&lt;/p&gt;
-
-&lt;p&gt;After a lot of poking around, I could check the general device information. You
-could get the hardware, software and firmware version. There&amp;rsquo;s also the device
-serial number which was nowhere on the actual physical device.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
-[CH BTScale_00:/service0010/char0017]# attribute-info
-Characteristic - Firmware Revision String
-	UUID: 00002a26-0000-1000-8000-00805f9b34fb
-	Service: /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010
-	Value: 0x31
-	Value: 0x2e
-	Value: 0x31
-	Value: 0x33
-	Value: 0x41
-	Value: 0x00
-	Flags: read
-[CH BTScale_00:/service0010/char0017]# read
-Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x31
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x2e
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x31
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x33
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x41
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0010/char0017 Value: 0x00
-  31 2e 31 33 41 00                                1.13A.
-[CH BTScale_00:/service0010/char0017]#
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;There was also a service which contained Accel Enable, Accel Range, Accel
-X-Coordinate, Accel Y-Coordinate, and Accel Z-Coordinate. I guess it stands for
-accelerometer, which is probably what it uses to weigh things.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
-[CH BTScale_00:/service0023/char0024/desc0026]# read
-Attempting to read /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x41
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x63
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x63
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x65
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x6c
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x20
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x45
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x6e
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x61
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x62
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x6c
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024/desc0026 Value: 0x65
-  41 63 63 65 6c 20 45 6e 61 62 6c 65              Accel Enable
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;I couldn&amp;rsquo;t read from any of the Accel Coordinates. It kept saying permission
-denied. I could however, notify on them. But that didn&amp;rsquo;t yield anything as well.
-What I &lt;em&gt;could&lt;/em&gt; read was Accel Enable, which was set to 00. I guess that means it
-was off. After writing 01 to Accel Enable, I found I could get values out of
-Accel X-Coordinate! Also, the green LED which was permanently on turned off.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;[CHSLEEV_00]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
-[CH BTScale_00:/service0023/char0024]# write 01
-Attempting to write /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char0024
-[CH BTScale_00:/service0023/char0024]# select-attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a
-[CH BTScale_00:/service0023/char002a]# notify on
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Notifying: yes
-Notify started
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x5b
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0xa3
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x02
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x00
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x55
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0xa3
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x02
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x00
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x59
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0xa3
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x02
-[CHG] Attribute /org/bluez/hci0/dev_1C_BA_8C_21_7C_BB/service0023/char002a Value: 0x00
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;I tried pressing the scale down a few times, and the values changed accordingly.
-Now, I just had to figure out how to convert the values into grams. It looked
-like the values were 32-bit integers sent as 4 bytes. In the above example it
-would be &lt;code&gt;0x0002a35b&lt;/code&gt;, &lt;code&gt;0x0002a355&lt;/code&gt;, &lt;code&gt;0x0002a359&lt;/code&gt; or 172891, 172855, 172899. The
-values also decrease as you exert more effort on the scale. So assuming you take
-the initial value as &lt;em&gt;tare&lt;/em&gt;, you simply subtract any succeeding value from that
-&lt;em&gt;tare&lt;/em&gt; and you get the &amp;ldquo;weight&amp;rdquo;.&lt;/p&gt;
-
-&lt;p&gt;The values I got didn&amp;rsquo;t seem to be in grams though. After weighing some things
-on an actual scale and comparing the values I got, I found I can just divide the
-values by 14 and get something in grams. That 14 is entirely a magic number
-though and I have no idea whether other Prep Pad&amp;rsquo;s would have the same constant.&lt;/p&gt;
-
-&lt;h2 id=&#34;openpreppad&#34;&gt;OpenPrepPad&lt;/h2&gt;
-
-&lt;p&gt;With all that figured out, I went ahead and made a &lt;a href=&#34;https://github.com/thatsmydoing/openpreppad&#34;&gt;simple CLI application&lt;/a&gt;
-to interface with the Prep Pad. Ironically, node was the simplest thing I found
-that had &lt;a href=&#34;https://github.com/sandeepmistry/noble&#34;&gt;nice bluetooth library support&lt;/a&gt; so that&amp;rsquo;s what I wrote it in. I
-also added most of the technical details in the README for that as well.&lt;/p&gt;
-
-&lt;p&gt;While this is all well and cool, I doubt the intersection of Linux users and
-people who &lt;s&gt;got ripped off&lt;/s&gt; bought the Prep Pad is anyone besides me. In
-light of that, I&amp;rsquo;m in the process of making a React Native version of the app,
-but that&amp;rsquo;s still a work in progress. Who knows, if the new owners of Prep Pad
-are good, I might not even need to finish it.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/openpreppad.html</guid>
+      <description>Smart electronics and IoT (Internet of Things) are all the rage these days. You have a lot of companies sprout up trying to make the next big thing, which also leads to a lot of failures big and small. Pebble, the maker of my smartwatch, got bought out by Fitbit recently. This left watch owners without any official support, but thankfully, community members stepped up to continue maintaining it.</description>
     </item>
     
     <item>
       <title>Haproxy Charset</title>
-      <link>http://pleasantprogrammer.com/posts/haproxy-charset.html</link>
+      <link>https://pleasantprogrammer.com/posts/haproxy-charset.html</link>
       <pubDate>Fri, 24 Jun 2016 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/haproxy-charset.html</guid>
-      <description>&lt;p&gt;A common problem we encounter is for things like &lt;em&gt;ñ&lt;/em&gt; not showing up correctly. This actually caused &lt;a href=&#34;http://www.rappler.com/nation/politics/elections/2016/132894-human-error-hash-election-results-code-mismatch&#34;&gt;some issues&lt;/a&gt; in the recent Philippine elections, but this isn&amp;rsquo;t about hash codes or anything like that.&lt;/p&gt;
-
-&lt;p&gt;By default, we use UTF-8 for text storage and rendering. A problem is that browsers don&amp;rsquo;t assume UTF-8 as the default and you need to have either a &lt;code&gt;&amp;lt;meta charset=&amp;quot;utf-8&amp;quot; /&amp;gt;&lt;/code&gt; in the HTML or &lt;code&gt;Content-Type: text/html; charset=utf-8&lt;/code&gt; in the headers. A few of our services don&amp;rsquo;t set the &lt;code&gt;Content-Type&lt;/code&gt; with the &lt;code&gt;charset=utf-8&lt;/code&gt; part so you&amp;rsquo;d get piñata instead of piñata.&lt;/p&gt;
-
-&lt;p&gt;Being lazy, we usually just correct this at the reverse proxy side. It&amp;rsquo;s trivial to do in nginx. You just need to add &lt;code&gt;charset utf-8;&lt;/code&gt; to your configuration and you&amp;rsquo;re good. For haproxy though, I couldn&amp;rsquo;t readily find a solution for it and had to go through the docs to see what I could do.&lt;/p&gt;
-
-&lt;p&gt;After a bit of experimenting, I had success with this:&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;# set content-type to utf-8 if not already
-acl has_charset hdr_sub(content-type) -i charset=
-rspirep (Content-Type.*) \1;\ charset=utf-8 unless has_charset
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;This is probably not the best way to do it. Arguably, we should just fix our services to have the correct &lt;code&gt;Content-Type&lt;/code&gt; in the first place, but I can do that some other time.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/haproxy-charset.html</guid>
+      <description>A common problem we encounter is for things like ñ not showing up correctly. This actually caused some issues in the recent Philippine elections, but this isn&amp;rsquo;t about hash codes or anything like that.
+By default, we use UTF-8 for text storage and rendering. A problem is that browsers don&amp;rsquo;t assume UTF-8 as the default and you need to have either a &amp;lt;meta charset=&amp;quot;utf-8&amp;quot; /&amp;gt; in the HTML or Content-Type: text/html; charset=utf-8 in the headers.</description>
     </item>
     
     <item>
       <title>Cloudflare Shenanigans</title>
-      <link>http://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</link>
+      <link>https://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</link>
       <pubDate>Fri, 25 Dec 2015 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</guid>
-      <description>&lt;p&gt;An old client of ours managed to convince a telco to zero-rate the data for their app. In order to whitelist it though, we needed to use plain HTTP for domain whitelisting. For HTTPS, they can only whitelist by IP address. Like any good developer, we were using HTTPS. Also, like any good developer, we put our server behind Cloudflare.&lt;/p&gt;
-
-&lt;p&gt;Now the problem is that Cloudflare can put you behind &lt;a href=&#34;https://www.cloudflare.com/ips/&#34;&gt;any IP they own&lt;/a&gt;, which is a huge range. There&amp;rsquo;s no guarantee that the IP we have now is going to be the same later on. So we did the reasonable thing and asked them to whitelist all of the Cloudflare IPs. And the telco agreed! We were in total disbelief when that happened. But hey, if life gives you free internet, you take it.&lt;/p&gt;
-
-&lt;p&gt;We never actually empirically tested whether other sites hosted on Cloudflare were also actually zero-rated. But I like to think that we saved a lot of people on their data costs from browsing Reddit and 4chan. But alas, good things must come to an end.&lt;/p&gt;
-
-&lt;p&gt;A few months after we started beta testing the app, Cloudflare added more IPs to their range. Unfortunately, our server got moved to those new IPs which were not whitelisted yet. Apparently, the telco whitelisting process was incredibly convoluted and time consuming. Our client didn&amp;rsquo;t want to bother asking them to whitelist more IPs. We also tried asking Cloudflare to move us back to the original IP range, but they could only do that if we were in their enterprise tier. We couldn&amp;rsquo;t really afford that, so we looked for other options.&lt;/p&gt;
-
-&lt;p&gt;Since Cloudflare was essentially just a giant reverse proxy, theoretically there should be no distinction between one IP address from another. The specific IP we get is probably just for load balancing. So we tried accessing the IPs in the range directly and just setting the Host header and it worked! But we get SSL errors because the IP itself doesn&amp;rsquo;t have its own certificate.&lt;/p&gt;
-
-&lt;p&gt;After more testing, we figured out that you could actually use any Cloudflare backed domain so long as we properly set the Host header. We just needed to find one still in the old range. Coincidentally, 4chan.org was. Which led to this wonderful commit&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;commit 123456789abcdef
-Author: ~~~~~~
-Date:   ~~~~~~
-
-    4chan hack
-
-&lt;span style=&#34;color: #000080; font-weight: bold&#34;&gt;diff --git a/src/com/client/common/Util.java b/src/com/client/common/Util.java&lt;/span&gt;
-&lt;span style=&#34;color: #A00000&#34;&gt;--- a/src/com/client/common/Util.java&lt;/span&gt;
-&lt;span style=&#34;color: #00A000&#34;&gt;+++ b/src/com/client/common/Util.java&lt;/span&gt;
-&lt;span style=&#34;color: #800080; font-weight: bold&#34;&gt;@@ -210,7 +210,8 @@ public class Util {&lt;/span&gt;
-        }
-
-        public static String getServerAddress(Context context) {
-&lt;span style=&#34;color: #A00000&#34;&gt;-               String address = &amp;quot;https://backend.client.com&amp;quot;;&lt;/span&gt;
-&lt;span style=&#34;color: #00A000&#34;&gt;+               // String address = &amp;quot;https://backend.client.com&amp;quot;;&lt;/span&gt;
-&lt;span style=&#34;color: #00A000&#34;&gt;+               String address = &amp;quot;https://4chan.org&amp;quot;;&lt;/span&gt;
-                if(!isDebug(context)) return address;
-                try {
-&lt;span style=&#34;color: #000080; font-weight: bold&#34;&gt;diff --git a/src/com/client/common/logging/APIClient.java b/src/com/client/common/logging/APIClient.java&lt;/span&gt;
-&lt;span style=&#34;color: #A00000&#34;&gt;--- a/src/com/client/common/logging/APIClient.java&lt;/span&gt;
-&lt;span style=&#34;color: #00A000&#34;&gt;+++ b/src/com/client/common/logging/APIClient.java&lt;/span&gt;
-&lt;span style=&#34;color: #800080; font-weight: bold&#34;&gt;@@ -101,6 +101,7 @@ public class APIClient {&lt;/span&gt;
-        private HttpResponse postInternal(String url, List&amp;lt;NameValuePair&amp;gt; data, boolean forRegistration) throws ClientProtocolException, IOException {
-                HttpPost request = new HttpPost(Util.getServerAddress(mContext)+&amp;quot;/api/&amp;quot;+url);
-                request.setHeader(&amp;quot;X-API-VERSION&amp;quot;, apiVersion);
-&lt;span style=&#34;color: #00A000&#34;&gt;+               request.setHeader(&amp;quot;Host&amp;quot;, &amp;quot;backend.client.com&amp;quot;);&lt;/span&gt;
-
-                if(data == null) {
-                        data = new ArrayList&amp;lt;NameValuePair&amp;gt;();
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Eventually, we did decide to just abandon Cloudflare for the server. We probably weren&amp;rsquo;t going to be the target of a DDOS or anything. This also allowed us to do more secure things like pinning the server certificate in the application itself. Clearly, this is what we should have just done in the first place, but at the time we just wanted a stopgap solution.&lt;/p&gt;
-
-&lt;p&gt;I just still find it funny we were making people&amp;rsquo;s phones go to 4chan.org everyday for more than a year.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</guid>
+      <description>An old client of ours managed to convince a telco to zero-rate the data for their app. In order to whitelist it though, we needed to use plain HTTP for domain whitelisting. For HTTPS, they can only whitelist by IP address. Like any good developer, we were using HTTPS. Also, like any good developer, we put our server behind Cloudflare.
+Now the problem is that Cloudflare can put you behind any IP they own, which is a huge range.</description>
     </item>
     
     <item>
       <title>TiddlyWiki in the Sky (or TiddlyWeb for TW5)</title>
-      <link>http://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</link>
+      <link>https://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</link>
       <pubDate>Thu, 24 Dec 2015 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</guid>
-      <description>
-
-&lt;p&gt;I&amp;rsquo;ve always liked &lt;a href=&#34;http://tiddlywiki.com&#34;&gt;TiddlyWiki&lt;/a&gt;. Back when it first came out, it was really amazing. A wiki all in one file, that worked in the browser. It didn&amp;rsquo;t need a backend, it would just save itself as an all new HTML file with all your posts inside. I&amp;rsquo;ve used it a lot over the years, as a personal wiki/journal and a class notebook. I even had a blog with it at one point using one of the server-side forks.&lt;/p&gt;
-
-&lt;p&gt;Now, there&amp;rsquo;s TiddlyWiki5 which is a rewrite of the original TiddlyWiki that looks a whole lot snazzier, and I assume has better architecture overall. It also has experimental support for all the server-side platforms (particularly TiddlyWeb) that have cropped up.&lt;/p&gt;
-
-&lt;p&gt;If you&amp;rsquo;re just looking for a simple server setup for TiddlyWiki5, it has native support for that on its own. There&amp;rsquo;s plenty of documentation on the site. But if you&amp;rsquo;re looking for more advanced features (like storing your posts in git or a database), then you&amp;rsquo;ll need to use it with TiddlyWeb. The problem is that most of the documentation for TiddlyWeb still refers to the old TiddlyWiki.&lt;/p&gt;
-
-&lt;p&gt;To support TiddlyWiki5, we&amp;rsquo;ll need a version of the wiki which has the TiddlyWeb plugin already installed and configured. After that, some tweaking is necessary to get TiddlyWeb to provide what the wiki requires.&lt;/p&gt;
-
-&lt;h2 id=&#34;setting-up-tiddlywiki&#34;&gt;Setting Up TiddlyWiki&lt;/h2&gt;
-
-&lt;p&gt;TiddlyWiki5 provides a command line tool via &lt;code&gt;npm&lt;/code&gt; that allows building custom versions of the wiki. In fact, it comes with templates, called &amp;ldquo;editions&amp;rdquo;, that we can use for our setup. Assuming you already have it installed, create the wiki using&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;tiddlywiki mywiki --init tw5tank          &lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# create wiki from template&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;This creates a wiki intended for use with &lt;a href=&#34;https://tank.peermore.com/&#34;&gt;Tank&lt;/a&gt;, which is built on top of TiddlyWeb. From here, you should look in &lt;code&gt;mywiki/tiddlers/system&lt;/code&gt; which contain the entries for &lt;code&gt;SiteTitle&lt;/code&gt;, &lt;code&gt;SiteSubtitle&lt;/code&gt;, &lt;code&gt;DefaultTiddlers&lt;/code&gt;, and &lt;code&gt;tiddlyweb-host&lt;/code&gt;. The first 3 should be configured however you want. These are necessary because they&amp;rsquo;re needed before the wiki can load them from the server. &lt;code&gt;tiddlyweb-host&lt;/code&gt; contains the location of the TiddlyWeb server, this should be &lt;code&gt;http://localhost:8080/&lt;/code&gt; if you&amp;rsquo;re just testing locally. With everything configured, you can build the new wiki by running&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;tiddlywiki mywiki --build
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;This will output the wiki to &lt;code&gt;mywiki/output/tw5tank.html&lt;/code&gt;. You can now serve it using your favorite local webserver, like &lt;code&gt;python -m http.server&lt;/code&gt;.&lt;/p&gt;
-
-&lt;h2 id=&#34;setting-up-tiddlyweb&#34;&gt;Setting Up TiddlyWeb&lt;/h2&gt;
-
-&lt;p&gt;The TiddlyWeb tutorial recommends using &lt;code&gt;tiddlywebwiki&lt;/code&gt; which has all the plugins setup for a nice wiki instance for the old TiddlyWiki. It has a lot of features that aren&amp;rsquo;t really needed, so we won&amp;rsquo;t go with that. So first, we&amp;rsquo;ll need to install TiddlyWeb and any plugins we might want to use.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;pip install tiddlyweb tiddlywebplugins.status tiddlywebplugins.cherrypy tiddlywebplugins.cors
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Next, we&amp;rsquo;ll need the tiddlyweb configuration in &lt;code&gt;tiddlywebconfig.py&lt;/code&gt;&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# A basic configuration.&lt;/span&gt;
-&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# `pydoc tiddlyweb.config` for details on configuration items.&lt;/span&gt;
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;import&lt;/span&gt; &lt;span style=&#34;color: #0000FF; font-weight: bold&#34;&gt;tiddlywebplugins.status&lt;/span&gt;
-
-config &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; {
-    &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;system_plugins&amp;#39;&lt;/span&gt;: [&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;tiddlywebplugins.status&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;tiddlywebplugins.cors&amp;#39;&lt;/span&gt;],
-    &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;secret&amp;#39;&lt;/span&gt;: &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;36c98d6d14618c79f0ed2d49cd1b9e272d8d4bd0&amp;#39;&lt;/span&gt;,
-    &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;wsgi_server&amp;#39;&lt;/span&gt;: &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;tiddlywebplugins.cherrypy&amp;#39;&lt;/span&gt;,
-    &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;cors.enable_non_simple&amp;#39;&lt;/span&gt;: &lt;span style=&#34;color: #008000&#34;&gt;True&lt;/span&gt;
-}
-
-original_gather_data &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; tiddlywebplugins&lt;span style=&#34;color: #666666&#34;&gt;.&lt;/span&gt;status&lt;span style=&#34;color: #666666&#34;&gt;.&lt;/span&gt;_gather_data
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;def&lt;/span&gt; &lt;span style=&#34;color: #0000FF&#34;&gt;_status_gather_data&lt;/span&gt;(environ):
-    data &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; original_gather_data(environ)
-    data[&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;space&amp;#39;&lt;/span&gt;] &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; {&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;recipe&amp;#39;&lt;/span&gt;: &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;default&amp;#39;&lt;/span&gt;}
-    &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;return&lt;/span&gt; data
-
-tiddlywebplugins&lt;span style=&#34;color: #666666&#34;&gt;.&lt;/span&gt;status&lt;span style=&#34;color: #666666&#34;&gt;.&lt;/span&gt;_gather_data &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; _status_gather_data
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;The tweaks involved are:&lt;/p&gt;
-
-&lt;ul&gt;
-&lt;li&gt;using the status plugin which the wiki requires&lt;/li&gt;
-&lt;li&gt;monkeypatching the status plugin for the wiki to use the correct &amp;ldquo;recipe&amp;rdquo;&lt;/li&gt;
-&lt;li&gt;using cherrypy server instead of the buggy default one&lt;/li&gt;
-&lt;li&gt;using cors since we&amp;rsquo;re not hosting the wiki itself on the same server&lt;/li&gt;
-&lt;/ul&gt;
-
-&lt;p&gt;With that, we just need to create the store that will hold our data&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;twanager recipe default &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;lt;&amp;lt;EOF&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;desc: standard TiddlyWebWiki environment&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;policy: {&amp;quot;read&amp;quot;: [], &amp;quot;create&amp;quot;: [], &amp;quot;manage&amp;quot;: [&amp;quot;R:ADMIN&amp;quot;], &amp;quot;accept&amp;quot;: [], &amp;quot;write&amp;quot;: [&amp;quot;R:ADMIN&amp;quot;], &amp;quot;owner&amp;quot;: &amp;quot;administrator&amp;quot;, &amp;quot;delete&amp;quot;: [&amp;quot;R:ADMIN&amp;quot;]}&lt;/span&gt;
-
-&lt;span style=&#34;color: #BA2121&#34;&gt;/bags/default/tiddlers&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;EOF&lt;/span&gt;
-
-twanager bag default &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;lt;&amp;lt;EOF&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;{&amp;quot;policy&amp;quot;: {&amp;quot;read&amp;quot;: [], &amp;quot;create&amp;quot;: [], &amp;quot;manage&amp;quot;: [&amp;quot;R:ADMIN&amp;quot;], &amp;quot;accept&amp;quot;: [], &amp;quot;write&amp;quot;: [], &amp;quot;owner&amp;quot;: &amp;quot;administrator&amp;quot;, &amp;quot;delete&amp;quot;: []}}&lt;/span&gt;
-&lt;span style=&#34;color: #BA2121&#34;&gt;EOF&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Finally, we can start the TiddlyWeb server&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;twanager server
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;h2 id=&#34;putting-it-all-together&#34;&gt;Putting it all together&lt;/h2&gt;
-
-&lt;p&gt;Once you have the TiddlyWeb server running, you can just go to wherever you&amp;rsquo;re hosting the wiki html and it should work. You can try creating some posts, and the check mark on the sidebar should be red for a while and then turn black. Once that&amp;rsquo;s done it&amp;rsquo;s saved. You can refresh your browser and your posts should still be there.&lt;/p&gt;
-
-&lt;p&gt;At this point, you can start customizing your TiddlyWeb instance, by changing your store to something like a database, or adding authorization. You can also tweak the server setup so you won&amp;rsquo;t need CORS anymore.&lt;/p&gt;
-
-&lt;p&gt;TiddlyWiki5 is still relatively new. I hope that eventually, support for server-side and the plugin ecosystem grows to be as great as the old TiddlyWiki.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</guid>
+      <description>I&amp;rsquo;ve always liked TiddlyWiki. Back when it first came out, it was really amazing. A wiki all in one file, that worked in the browser. It didn&amp;rsquo;t need a backend, it would just save itself as an all new HTML file with all your posts inside. I&amp;rsquo;ve used it a lot over the years, as a personal wiki/journal and a class notebook. I even had a blog with it at one point using one of the server-side forks.</description>
     </item>
     
     <item>
       <title>Is My Terminal Window Active?</title>
-      <link>http://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</link>
+      <link>https://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</link>
       <pubDate>Sun, 07 Jun 2015 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</guid>
-      <description>
-
-&lt;p&gt;I&amp;rsquo;ve been working in OSX for almost 3 years now, but I recently switched back to Linux because of all the problems people encountered with Yosemite. There are some things I missed from OSX though. One of which is &lt;a href=&#34;https://github.com/marzocchi/zsh-notify&#34;&gt;zsh-notify&lt;/a&gt;. It&amp;rsquo;s a zsh plugin that alerts you if your long-running task is complete, and whether it failed or not.&lt;/p&gt;
-
-&lt;p&gt;It&amp;rsquo;s pretty convenient when you&amp;rsquo;re compiling something and then go on to browse reddit while waiting. Usually, I spend too much time just reading and forget about the compilation entirely. With the plugin, I get the notification and maybe go back to work.&lt;/p&gt;
-
-&lt;p&gt;One nice feature it has is that if you&amp;rsquo;re currently looking at the terminal window of the job that just finished, it won&amp;rsquo;t notify you. It only notifies on windows that aren&amp;rsquo;t currently in focus. To do this, it has to actually talk to Terminal.app or iTerm2 to see if the window and tab are active.&lt;/p&gt;
-
-&lt;p&gt;This is alright in OSX since those 2 are the generally most used terminal emulators. On Linux though, everyone has their own favorite terminal. Given that, I figured I could probably rely on talking to X to see if the window is active instead of each single terminal emulator. X can&amp;rsquo;t tell if the tab is active though, but I don&amp;rsquo;t use tabs in my current setup so it should still be good.&lt;/p&gt;
-
-&lt;h2 id=&#34;xdotool&#34;&gt;xdotool&lt;/h2&gt;
-
-&lt;p&gt;&lt;a href=&#34;http://superuser.com/questions/382616/detecting-currently-active-window&#34;&gt;Preliminary research&lt;/a&gt; reveals that we can easily get what the active window is with xdotool. &lt;code&gt;xdotool getactivewindow&lt;/code&gt; gives us the X window id of the active one. Now all we need is a way to get the window id of the terminal we&amp;rsquo;re in.&lt;/p&gt;
-
-&lt;h2 id=&#34;first-attempt-windowid&#34;&gt;First Attempt: $WINDOWID&lt;/h2&gt;
-
-&lt;p&gt;Apparently, xterm and similar terminal emulators define an environment variable called &lt;code&gt;$WINDOWID&lt;/code&gt; with the window id of the terminal. Obviously, this is too good to be true. In xterm and konsole the &lt;code&gt;$WINDOWID&lt;/code&gt; was correct, but in VTE-based terminal emulators, &lt;code&gt;$WINDOWID&lt;/code&gt; had the wrong value. In terminology, it didn&amp;rsquo;t define &lt;code&gt;$WINDOWID&lt;/code&gt; altogether. So &lt;code&gt;$WINDOWID&lt;/code&gt; wasn&amp;rsquo;t going to work.&lt;/p&gt;
-
-&lt;h2 id=&#34;second-attempt-xdotool-search-magic&#34;&gt;Second Attempt: xdotool search $MAGIC&lt;/h2&gt;
-
-&lt;p&gt;My second idea was that you can use zsh to change the window title to a magic number and then just check if the active window is the same one as the window with the magic number. This sort of worked for most terminals, except konsole which does whatever it wants with the window title. There&amp;rsquo;s also the problem of some zsh configs automatically settings the window title to the current command.&lt;/p&gt;
-
-&lt;p&gt;In hindsight, I could probably have just done &lt;code&gt;xdotool search --name xdotool&lt;/code&gt; since in most cases, when you run the search, zsh or konsole will set the window name to the current command. Maybe that&amp;rsquo;s another option I can explore some day.&lt;/p&gt;
-
-&lt;h2 id=&#34;third-attempt-ppid&#34;&gt;Third Attempt: $PPID&lt;/h2&gt;
-
-&lt;p&gt;My third idea was another environment variable called &lt;code&gt;$PPID&lt;/code&gt;, which is the process id of the parent of the shell. As it happens, the parent is the window containing the zsh instance. This is actually pretty consistent across most terminals. The only problem was if you launched zsh from another shell since your new zsh&amp;rsquo;s parent will now be another zsh instance instead of an X window.&lt;/p&gt;
-
-&lt;p&gt;At first glance, launching zsh within zsh doesn&amp;rsquo;t seem like something most people would do, but this is what happens when you run screen or tmux. To work around this, we can actually just save the original &lt;code&gt;$PPID&lt;/code&gt; in a different variable and use that instead.&lt;/p&gt;
-
-&lt;p&gt;Now that we have the PID of the window from zsh, we can once again use xdotool to get the PID of the current active window with &lt;code&gt;xdotool getactivewindow getwindowpid&lt;/code&gt;. We just simply compare that with our &lt;code&gt;$PPID&lt;/code&gt; and we can tell if we&amp;rsquo;re in an active window or not. Overall, this approach worked surprisingly well so that&amp;rsquo;s the final solution I went with.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</guid>
+      <description>I&amp;rsquo;ve been working in OSX for almost 3 years now, but I recently switched back to Linux because of all the problems people encountered with Yosemite. There are some things I missed from OSX though. One of which is zsh-notify. It&amp;rsquo;s a zsh plugin that alerts you if your long-running task is complete, and whether it failed or not.
+It&amp;rsquo;s pretty convenient when you&amp;rsquo;re compiling something and then go on to browse reddit while waiting.</description>
     </item>
     
     <item>
       <title>Removing PLDTMyDSLBiz from the ZyXEL P-2612HNU</title>
-      <link>http://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</link>
+      <link>https://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</link>
       <pubDate>Wed, 27 Nov 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</guid>
-      <description>&lt;p&gt;I&amp;rsquo;ve always thought that people were just too lazy to change their SSIDs when I see &amp;ldquo;PLDTMyDSLBizCafeJapan&amp;rdquo;. It became apparent when we got our own PLDT line that it was because the bundled router/modem &lt;em&gt;does not&lt;/em&gt; allow you to remove the prefix.&lt;/p&gt;
-
-&lt;p&gt;This is not the kind of thing you expect as a business customer. Even for home customers, I feel it&amp;rsquo;s still a bit dishonest. I&amp;rsquo;d be fine if it was just the default SSID, but forcing people to have it as part of their SSID is like advertising that your company (I mean PLDT) is a douche.&lt;/p&gt;
-
-&lt;p&gt;Of course, we couldn&amp;rsquo;t just leave the SSID prefix there, so we tried a number of things to get rid of it. There are articles for removing it from the &lt;a href=&#34;http://www.phandroidinternet.com/2013/06/how-to-remove-on-wifi-name-or-ssid-on.html&#34;&gt;Prolink H5004N&lt;/a&gt; or the &lt;a href=&#34;http://www.symbianize.com/showthread.php?t=730091&#34;&gt;ZyXEL P-660HN-T1A&lt;/a&gt; but not for the one we got which was the ZyXEL P-2612HNU-F1F.&lt;/p&gt;
-
-&lt;p&gt;We did still try the firebug/inspector tricks, but it seems that there is a server-side check that adds in the &amp;ldquo;PLDTMyDSLBiz&amp;rdquo;. We tried a number of things, but the one that ultimately worked (and we had a good laugh about) was to backup the configuration, edit the dumped file and restore it.&lt;/p&gt;
-
-&lt;p&gt;The backup is actually just an XML file. You can search for SSID and change the parameter there. It&amp;rsquo;s a bit annoying because the router has to restart after restoring the configuration, but it works!&lt;/p&gt;
-
-&lt;p&gt;A minor note, the router doesn&amp;rsquo;t seem to support SSIDs with a comma (,) well. It just gets everything before the comma as the SSID for some reason.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</guid>
+      <description>I&amp;rsquo;ve always thought that people were just too lazy to change their SSIDs when I see &amp;ldquo;PLDTMyDSLBizCafeJapan&amp;rdquo;. It became apparent when we got our own PLDT line that it was because the bundled router/modem does not allow you to remove the prefix.
+This is not the kind of thing you expect as a business customer. Even for home customers, I feel it&amp;rsquo;s still a bit dishonest. I&amp;rsquo;d be fine if it was just the default SSID, but forcing people to have it as part of their SSID is like advertising that your company (I mean PLDT) is a douche.</description>
     </item>
     
     <item>
       <title>Console Keymap Switching</title>
-      <link>http://pleasantprogrammer.com/posts/console-keymap-switching.html</link>
+      <link>https://pleasantprogrammer.com/posts/console-keymap-switching.html</link>
       <pubDate>Tue, 29 Oct 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/console-keymap-switching.html</guid>
-      <description>&lt;p&gt;At the office, we have some people who use DVORAK. Normally, this isn&amp;rsquo;t a problem. To each his own after all. It does become a bit problematic though, when we&amp;rsquo;re dealing with the servers around the office.&lt;/p&gt;
-
-&lt;p&gt;We normally leave the servers on QWERTY. After all, most people start off as QWERTY typists and migrate to something else. That said, it&amp;rsquo;s apparently difficult to stay fluent in both. People tend to forget how to type in QWERTY once they learn DVORAK or something else. While it is true that they can just look a the keyboard while typing, my coworkers would prefer it to just be in DVORAK.&lt;/p&gt;
-
-&lt;p&gt;For the console, they&amp;rsquo;d typically do &lt;code&gt;sudo loadkeys dvorak&lt;/code&gt; after logging in. The problem with this is, after they logout, the keymapping is still on DVORAK. This has been quite annoying for a few times since I can&amp;rsquo;t even login to change the keymap. What I wanted was something like you get in the graphical login screens where you can pick your keymap before logging in. Apparently, there isn&amp;rsquo;t a readily available thing for the console.&lt;/p&gt;
-
-&lt;p&gt;I googled around for solutions and came across &lt;a href=&#34;http://superuser.com/questions/548234/how-can-i-easily-toggle-between-dvorak-and-qwerty-keyboard-layouts-from-a-linux&#34;&gt;a nice idea&lt;/a&gt;. You could alias &lt;code&gt;asdf&lt;/code&gt; to load the DVORAK mapping and &lt;code&gt;aoeu&lt;/code&gt; (the equivalent to asdf in DVORAK) to load the QWERTY mapping. This actually makes sense since you don&amp;rsquo;t really have to know where the letters are. The only problem is, you once again have to be logged in to change the key mappings.&lt;/p&gt;
-
-&lt;p&gt;After some further searching, I found &lt;a href=&#34;http://unix.stackexchange.com/questions/2884/toggle-between-dvorak-and-qwerty&#34;&gt;something close to what I wanted&lt;/a&gt;. Apparently, Alt+Up sends a KeyboardSignal keycode to the init process, which can act on that. It also works anywhere, even before being logged in. For SysVinit systems, you can just add a line to your inittab for a command to be run when Alt+Up is pressed.&lt;/p&gt;
-
-&lt;p&gt;In the office, however, we generally use Arch Linux which uses SystemD. But apparently, it also has a mechanism of accepting the Alt+Up press. It runs the kbrequest target whenever it gets the keypress. &lt;code&gt;kbrequest.target&lt;/code&gt; is normally aliased to run the rescue service though, so you have to manually create the file in &lt;code&gt;/etc/systemd/system/kbrequest.target&lt;/code&gt; and fill it with a description:&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;[Unit]&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;Description&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;kbrequest target&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;We can then add a service to be run whenever the target is called. Something like &lt;code&gt;/etc/systemd/system/keymap-switch.service&lt;/code&gt;:&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;[Unit]&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;Description&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;Keymap Switch Service&lt;/span&gt;
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;[Service]&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;Type&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;oneshot&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;ExecStart&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;/usr/local/bin/keymap-switch&lt;/span&gt;
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;[Install]&lt;/span&gt;
-&lt;span style=&#34;color: #7D9029&#34;&gt;WantedBy&lt;/span&gt;&lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;kbrequest.target&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;After enabling said service, we only need the actual keymap switcher, &lt;code&gt;/usr/local/bin/keymap-switch&lt;/code&gt;. The StackOverflow answer provides different ways of detecting the current keymap so we know which one to switch to. Since we&amp;rsquo;re using SystemD, we can use that instead for managing which keymap we&amp;rsquo;re actually using. It stores the current settings inside &lt;code&gt;/etc/vconsole.conf&lt;/code&gt;. We can also then switch keymaps by using &lt;code&gt;localectl set-keymap&lt;/code&gt;.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;#!/bin/sh&lt;/span&gt;
-&lt;span style=&#34;color: #008000&#34;&gt;source&lt;/span&gt; /etc/vconsole.conf
-
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;[&lt;/span&gt; &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;&lt;/span&gt;&lt;span style=&#34;color: #19177C&#34;&gt;$TERM&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;dumb&amp;quot;&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;]&lt;/span&gt;; &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;then&lt;/span&gt;
-  &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;[&lt;/span&gt; &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;&lt;/span&gt;&lt;span style=&#34;color: #19177C&#34;&gt;$KEYMAP&lt;/span&gt;&lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;quot;dvorak&amp;quot;&lt;/span&gt; &lt;span style=&#34;color: #666666&#34;&gt;]&lt;/span&gt;; &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;then&lt;/span&gt;
-    localectl set-keymap us
-  &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;else&lt;/span&gt;
-    localectl set-keymap dvorak
-  &lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;fi&lt;/span&gt;
-&lt;span style=&#34;color: #008000; font-weight: bold&#34;&gt;fi&lt;/span&gt;
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;After putting it all together, it works! We can switch keymaps on the fly by simply pressing Alt+Up.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/console-keymap-switching.html</guid>
+      <description>At the office, we have some people who use DVORAK. Normally, this isn&amp;rsquo;t a problem. To each his own after all. It does become a bit problematic though, when we&amp;rsquo;re dealing with the servers around the office.
+We normally leave the servers on QWERTY. After all, most people start off as QWERTY typists and migrate to something else. That said, it&amp;rsquo;s apparently difficult to stay fluent in both. People tend to forget how to type in QWERTY once they learn DVORAK or something else.</description>
     </item>
     
     <item>
       <title>Geocoding Services</title>
-      <link>http://pleasantprogrammer.com/posts/geocoding-services.html</link>
+      <link>https://pleasantprogrammer.com/posts/geocoding-services.html</link>
       <pubDate>Wed, 25 Sep 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/geocoding-services.html</guid>
-      <description>&lt;p&gt;A key component for any routing service is being able to do geocoding. Most people who are looking for routes most probably don&amp;rsquo;t know exactly where their start and end points are on the map. Even then, manually looking for a location on a map is a time-consuming task.&lt;/p&gt;
-
-&lt;p&gt;The gold standard for doing geocoding right now is Google Maps. It&amp;rsquo;s hard to find a better location search experience. If they actually provided routing for jeeps here in the Philippines, I imagine there wouldn&amp;rsquo;t be &lt;em&gt;that&lt;/em&gt; much you could do for the competition.&lt;/p&gt;
-
-&lt;p&gt;When the competition started though, I took it as a challenge to avoid Google Maps as much as possible. I wanted to see how much is currently possible with other options such as OpenStreetMap. In fact, OSM does have a geocoding service called &lt;a href=&#34;http://nominatim.openstreetmap.org&#34;&gt;Nominatim&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;Sadly, for a mapping app, what you want to do is not simply just geocoding. With geocoding, you take an address and turn it into coordinates. When you want to search for a place in a mapping app, you take part of an address, infer the rest of it, and give the user options to choose from.&lt;/p&gt;
-
-&lt;p&gt;Given a typical mapping app, you might type in &amp;ldquo;ateneo&amp;rdquo; and expect it to give you Ateneo de Manila University. With typical geocoding services like Nominatim or even Google&amp;rsquo;s &lt;a href=&#34;https://developers.google.com/maps/documentation/javascript/geocoding&#34;&gt;geocoding API&lt;/a&gt;, you probably won&amp;rsquo;t get any result for this. What you want to use is the &lt;a href=&#34;https://developers.google.com/maps/documentation/javascript/places&#34;&gt;Places API&lt;/a&gt; which provides an autocomplete search box. Using it, when you type in &amp;ldquo;ateneo&amp;rdquo;, it automatically suggests in the dropdown, &amp;ldquo;Ateneo de Manila University&amp;rdquo;.&lt;/p&gt;
-
-&lt;p&gt;A downside to using the Places API is that it&amp;rsquo;s against the terms of service to use it with something that isn&amp;rsquo;t Google Maps, which means no OpenStreetMap. If there were more time, writing your own autocompletion engine using OpenStreetMap&amp;rsquo;s data will probably be a better long term solution.&lt;/p&gt;
-
-&lt;p&gt;For now, since the competition&amp;rsquo;s deadline is just a few days away, I&amp;rsquo;ll be using Google Maps.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/geocoding-services.html</guid>
+      <description>A key component for any routing service is being able to do geocoding. Most people who are looking for routes most probably don&amp;rsquo;t know exactly where their start and end points are on the map. Even then, manually looking for a location on a map is a time-consuming task.
+The gold standard for doing geocoding right now is Google Maps. It&amp;rsquo;s hard to find a better location search experience. If they actually provided routing for jeeps here in the Philippines, I imagine there wouldn&amp;rsquo;t be that much you could do for the competition.</description>
     </item>
     
     <item>
       <title>Jeep and Bus Schedules</title>
-      <link>http://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</link>
+      <link>https://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</link>
       <pubDate>Sun, 28 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</guid>
-      <description>&lt;p&gt;Wouldn&amp;rsquo;t it be wonderful if there were no buses or jeepneys in the Philippines over the weekends? It would truly be a cyclist&amp;rsquo;s paradise. Imagine biking along EDSA, normally that would be a death sentence, but according to the GTFS data, you shouldn&amp;rsquo;t worry. I can assure you, it&amp;rsquo;s still a death sentence.&lt;/p&gt;
-
-&lt;p&gt;The GTFS spec defines 2 ways of statically specifying trip schedules. You can define the exact times that a service will arrive at a stop. You can also specify between what times the service is active and how often a new bus or jeep leaves the first stop. You also define which days those rules apply. You could say every MWF, the bus operates from 9:00AM to 9:00PM and every TTH, the bus services from 3:00AM to 11:00PM.&lt;/p&gt;
-
-&lt;p&gt;This should be sufficient in theory, but real world conditions like traffic or the weather could throw the schedules off. To solve this, there&amp;rsquo;s another spec, GTFS-realtime. This allows transit agencies to push temporary schedule updates and service announcements.&lt;/p&gt;
-
-&lt;p&gt;Like much everything else about the Philippine transit system, there aren&amp;rsquo;t really any &amp;ldquo;schedules&amp;rdquo; to speak of. It&amp;rsquo;s generally whenever the buses or jeeps feel like it. So we have no static schedules. We don&amp;rsquo;t have a central agency or the tracking technology to make it feasible to push updates via GTFS-RT.&lt;/p&gt;
-
-&lt;p&gt;Ideally, we shouldn&amp;rsquo;t bother inputting the schedule information into GTFS. Only the route data is really important for jeeps and buses. However, the schedule information is required in the GTFS, and routing apps wouldn&amp;rsquo;t work without it. So we have to add a reasonable trip schedule for jeeps and buses.&lt;/p&gt;
-
-&lt;p&gt;The current GTFS data does define these trip schedules. We assume that jeeps and buses operate between 6:00AM and 11:00PM and a new jeep passes by every 10 minutes. Also, jeeps and buses are defined to only operate on weekdays.&lt;/p&gt;
-
-&lt;p&gt;While there might be jeeps who change routes or don&amp;rsquo;t operate on weekends, I&amp;rsquo;m pretty sure that jeeps and buses run on weekends. We&amp;rsquo;ll have to fix it ourselves temporarily since there&amp;rsquo;s no central GTFS feed yet.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# 724594 seems to be the service id used by jeeps and buses&lt;/span&gt;
-sed -i .bak &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;/^724594/ s/0,0/1,1/&amp;#39;&lt;/span&gt; calendar.txt
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Another thing we could do is to adjust the time between buses, although the improvement is arguable. With the current 10 minutes between jeeps, it might provide some routes a significant advantage just because the timing is right. So you might get differing route suggestions depending on what time you planned the route. This makes sense when you&amp;rsquo;re sure what the times are, so you can minimize the wait, but with jeeps, you never really know how long the wait will actually be.&lt;/p&gt;
-
-&lt;p&gt;If we set the frequency to one minute, it &lt;em&gt;might&lt;/em&gt; give better routes by eliminating the timing issue. Or not, it&amp;rsquo;s kind of hard to tell.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&#34;color: #408080; font-style: italic&#34;&gt;# jeep and bus route ids tend to start with 72&lt;/span&gt;
-sed -i .bak &lt;span style=&#34;color: #BA2121&#34;&gt;&amp;#39;/^72/ s/,600/,60/&amp;#39;&lt;/span&gt; frequencies.txt
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Overall, the problems we&amp;rsquo;re having is a symptom of the mismatch between our transit system and the GTFS. It would be great if our transit system gets better and we don&amp;rsquo;t need to do hackish things for it to fit the GTFS, but that&amp;rsquo;s still a dream. For now, all we can really do is fit a triangle into a square hole.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</guid>
+      <description>Wouldn&amp;rsquo;t it be wonderful if there were no buses or jeepneys in the Philippines over the weekends? It would truly be a cyclist&amp;rsquo;s paradise. Imagine biking along EDSA, normally that would be a death sentence, but according to the GTFS data, you shouldn&amp;rsquo;t worry. I can assure you, it&amp;rsquo;s still a death sentence.
+The GTFS spec defines 2 ways of statically specifying trip schedules. You can define the exact times that a service will arrive at a stop.</description>
     </item>
     
     <item>
       <title>Highways in OTP</title>
-      <link>http://pleasantprogrammer.com/posts/highways-in-otp.html</link>
+      <link>https://pleasantprogrammer.com/posts/highways-in-otp.html</link>
       <pubDate>Wed, 24 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/highways-in-otp.html</guid>
-      <description>&lt;p&gt;One of the weird things that happens with OTP is sometimes it gives absurdly roundabout routes. Here is OTP&amp;rsquo;s suggested route for walking from UP to Ateneo:&lt;/p&gt;
-
-&lt;p&gt;&lt;img src=&#34;../galleries/transit/otproundabout.png&#34; alt=&#34;Roundabout route from UP to Ateneo&#34; /&gt;&lt;/p&gt;
-
-&lt;p&gt;This is just so hilariously wrong. It&amp;rsquo;s much simpler to just walk along Katipunan Avenue.&lt;/p&gt;
-
-&lt;p&gt;OTP couldn&amp;rsquo;t possibly be that dumb though, so there must be something we&amp;rsquo;re doing wrong. If you notice, Katipunan Avenue is colored red compared to the other streets. OTP seems to be avoiding any path that goes along Katipunan Avenue. The problem might have something to do with the &amp;ldquo;road type&amp;rdquo; designated to Katipunan.&lt;/p&gt;
-
-&lt;p&gt;Apparently, by default OTP will consider roads of type &lt;code&gt;trunk&lt;/code&gt; to be non-walkable and non-bikable. This is documented in the &lt;a href=&#34;http://wiki.openstreetmap.org/wiki/OpenTripPlanner&#34;&gt;OpenStreetMap wiki&lt;/a&gt; and the &lt;a href=&#34;https://github.com/openplans/OpenTripPlanner/wiki/GraphBuilder#permissions-and-bicycle-safety&#34;&gt;OTP wiki&lt;/a&gt; as well. There are actually multiple ways to go about this then. The first solution that came to mind was to just edit the original OSM XML file.&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;sed -i .bak s/trunk/primary/g manila.osm
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;And rebuild the graph. It doesn&amp;rsquo;t really matter much because the OSM data isn&amp;rsquo;t used to render the maps. It&amp;rsquo;s just used to build the routing data. This is actually what I did for &lt;a href=&#34;http://maps.pleasantprogrammer.com&#34;&gt;maps.pleasantprogrammer.com&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;It&amp;rsquo;s also possible to set the default way properties in OTP. Instead of disallowing walking and biking on &lt;code&gt;highway=trunk&lt;/code&gt; we could allow that. This is not much better than the &lt;code&gt;sed&lt;/code&gt; solution though. It&amp;rsquo;s better since you keep the weighting done by OTP, but you&amp;rsquo;re still saying that all trunks are walkable which might not be the case.&lt;/p&gt;
-
-&lt;p&gt;The most correct way to actually fix this is to go through each of the trunks and specifying &lt;code&gt;foot=yes&lt;/code&gt; and &lt;code&gt;bicycle=yes&lt;/code&gt; for those trunks that are actually walkable. You could either do this locally with the dumped data, or contribute it directly to OSM. I&amp;rsquo;m not sure on the particulars with updating OSM though.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/highways-in-otp.html</guid>
+      <description>One of the weird things that happens with OTP is sometimes it gives absurdly roundabout routes. Here is OTP&amp;rsquo;s suggested route for walking from UP to Ateneo:
+This is just so hilariously wrong. It&amp;rsquo;s much simpler to just walk along Katipunan Avenue.
+OTP couldn&amp;rsquo;t possibly be that dumb though, so there must be something we&amp;rsquo;re doing wrong. If you notice, Katipunan Avenue is colored red compared to the other streets. OTP seems to be avoiding any path that goes along Katipunan Avenue.</description>
     </item>
     
     <item>
       <title>Elevation Data in OTP</title>
-      <link>http://pleasantprogrammer.com/posts/elevation-data-in-otp.html</link>
+      <link>https://pleasantprogrammer.com/posts/elevation-data-in-otp.html</link>
       <pubDate>Tue, 23 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/elevation-data-in-otp.html</guid>
-      <description>&lt;p&gt;&lt;img src=&#34;../galleries/transit/otpelevation.png&#34; alt=&#34;OpenTripPlanner showing elevation data&#34; /&gt;&lt;/p&gt;
-
-&lt;p&gt;One thing I hadn&amp;rsquo;t tested out last time was OTP&amp;rsquo;s support for elevation data. It makes use of this by showing the elevation you have to traverse while walking along the suggested route. It can also take it into account when suggesting bike routes.&lt;/p&gt;
-
-&lt;p&gt;The &lt;a href=&#34;https://github.com/openplans/OpenTripPlanner/wiki/FiveMinutes&#34;&gt;5 minute tutorial&lt;/a&gt; actually discusses the elevation data briefly, but a more in-depth thing you can look at is the &lt;a href=&#34;https://github.com/openplans/OpenTripPlanner/wiki/GraphBuilder#elevation-data&#34;&gt;GraphBuilder documentation&lt;/a&gt;. It suggests using the ASTER dataset which is free but requires registration. I just opted to use the SRTM data available from the &lt;a href=&#34;http://www.philgis.org/freegisdata.htm&#34;&gt;PhilGIS website&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;I don&amp;rsquo;t know about the ASTER dataset, but the PhilGIS data was in the ERDAS img format. OTP only supports GeoTIFF so there was a need to convert it beforehand. You can use &lt;a href=&#34;http://www.gdal.org/&#34;&gt;GDAL&lt;/a&gt; for this. You&amp;rsquo;d just then run,&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;gdal_translate srtm41_90m_phl.img phil.tiff
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;Afterwards, it&amp;rsquo;s just a matter of following the OTP instructions on using a local elevation dataset. The process actually doubled the size of the generated Graph.obj so it might not be ideal if you&amp;rsquo;re running on limited RAM.&lt;/p&gt;
-
-&lt;p&gt;I&amp;rsquo;ve actually hosted a &lt;a href=&#34;http://maps.pleasantprogrammer.com&#34;&gt;working example&lt;/a&gt;. It&amp;rsquo;s pretty much at the limits of the RAM so it might be slow and unreliable, but you can test it out just for fun. Please don&amp;rsquo;t abuse it though.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/elevation-data-in-otp.html</guid>
+      <description>One thing I hadn&amp;rsquo;t tested out last time was OTP&amp;rsquo;s support for elevation data. It makes use of this by showing the elevation you have to traverse while walking along the suggested route. It can also take it into account when suggesting bike routes.
+The 5 minute tutorial actually discusses the elevation data briefly, but a more in-depth thing you can look at is the GraphBuilder documentation. It suggests using the ASTER dataset which is free but requires registration.</description>
     </item>
     
     <item>
       <title>GraphServer</title>
-      <link>http://pleasantprogrammer.com/posts/graphserver.html</link>
+      <link>https://pleasantprogrammer.com/posts/graphserver.html</link>
       <pubDate>Tue, 23 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/graphserver.html</guid>
-      <description>&lt;p&gt;Link: &lt;a href=&#34;http://graphserver.github.io/graphserver/&#34;&gt;http://graphserver.github.io/graphserver/&lt;/a&gt;&lt;/p&gt;
-
-&lt;p&gt;One other routing webapp I saw was GraphServer. It&amp;rsquo;s actually more of a general purpose Graph library which supports GTFS and OSM data than an actual dedicated routing software like OpenTripPlanner. It&amp;rsquo;s also based off python and C instead of Java, so it feels a lot less heavy.&lt;/p&gt;
-
-&lt;p&gt;The instructions on the website are already pretty good. There are just some minor errors with it. Where it says &lt;code&gt;gs_gtfsdb_build&lt;/code&gt;, you should actually use &lt;code&gt;gs_gtfsdb_compile&lt;/code&gt;. Also, when running &lt;code&gt;gs_osmdb_compile&lt;/code&gt; you might need to use &lt;code&gt;-t&lt;/code&gt; for tolerant in case you follow the instructions on chopping up the original OSM data.&lt;/p&gt;
-
-&lt;p&gt;A nice suggestion from the GraphServer instructions was to crop the OSM data to minimize the graph size. This is actually quite helpful if you downloaded the entire Philippine OSM dump. It reduced the original 900MB file to 135MB which was a lot more workable. I did hit a problem with their instructions though. The linked version of osmosis is an old one, which doesn&amp;rsquo;t support 64-bit ids. The &lt;a href=&#34;http://wiki.openstreetmap.org/wiki/Osmosis&#34;&gt;latest version of Osmosis&lt;/a&gt; easily did the job though.&lt;/p&gt;
-
-&lt;p&gt;The actual routing though, was not exactly good. I only tried one route which should normally take 1-2 transfers, it suggested a route which involved 4+ transfers. It also didn&amp;rsquo;t provide any alternate routes aside from that one. I&amp;rsquo;m not sure if it&amp;rsquo;s a limitation of the provided routeserver, but I didn&amp;rsquo;t bother checking if it supported parameters which might provide better routes.&lt;/p&gt;
-
-&lt;p&gt;I think graphserver could be useful, but it seems more involved than say OpenTripPlanner. There do seem to be people who use graphserver for their routing apps, but for the bounds of the contest, or just as a side project, it might require too much effort.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/graphserver.html</guid>
+      <description>Link: http://graphserver.github.io/graphserver/
+One other routing webapp I saw was GraphServer. It&amp;rsquo;s actually more of a general purpose Graph library which supports GTFS and OSM data than an actual dedicated routing software like OpenTripPlanner. It&amp;rsquo;s also based off python and C instead of Java, so it feels a lot less heavy.
+The instructions on the website are already pretty good. There are just some minor errors with it. Where it says gs_gtfsdb_build, you should actually use gs_gtfsdb_compile.</description>
     </item>
     
     <item>
       <title>Transit Wand</title>
-      <link>http://pleasantprogrammer.com/posts/transit-wand.html</link>
+      <link>https://pleasantprogrammer.com/posts/transit-wand.html</link>
       <pubDate>Mon, 15 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/transit-wand.html</guid>
-      <description>&lt;p&gt;Link: &lt;a href=&#34;https://play.google.com/store/apps/details?id=com.conveyal.transitwand&#34;&gt;http://transitwand.com&lt;/a&gt;&lt;/p&gt;
-
-&lt;p&gt;Overall, this was the simplest of the &lt;a href=&#34;http://philippine-transit.hackathome.com/use-this-code/&#34;&gt;open-source transit tools&lt;/a&gt; to actually get up and running. There&amp;rsquo;s already a deployed instance of the server, and you can easily download the phone app via the &lt;a href=&#34;https://play.google.com/store/apps/details?id=com.conveyal.transitwand&#34;&gt;Play Store&lt;/a&gt;. Even running the server by yourself didn&amp;rsquo;t have any of the hiccups I had with GTFS Editor.&lt;/p&gt;
-
-&lt;p&gt;The phone app is actually quite simple. It allows you to capture a trip, which will record your GPS coordinates as you ride public transit. It also allows you to mark points of the trip where you stop and also how long the stop took. Lastly, it allows you to record embarking and disembarking passengers which is potentially useful for ridership data.&lt;/p&gt;
-
-&lt;p&gt;After doing a capture session, you can review the data on the phone. It will plot out the route on a map, with markers for the stops. You then either delete the data if it looks wrong, or you can upload it to the Transit Wand server. Uploading involves registering an account, but it&amp;rsquo;s free and you don&amp;rsquo;t even actually need to put in a username or anything. It simply registers the phone&amp;rsquo;s IMEI on the server and gives you a 6-digit identifier.&lt;/p&gt;
-
-&lt;p&gt;You can then use the 6-digit identifier to view the data on Transit Wand&amp;rsquo;s server, which is good since uploading any data automatically deletes it from the phone. There really isn&amp;rsquo;t much else you can do with it though. It just allows you to view the data, and export it as a &lt;a href=&#34;https://en.wikipedia.org/wiki/Shapefile&#34;&gt;Shapefile&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;As is, this is purely a data collection client-server app. Barring looking at the database, there is no way to get a list of phones which have collected data. Only the person who initiated the data collection knows the 6-digit code to view their data. There&amp;rsquo;s also no way to extract the ridership information from the server yet. This isn&amp;rsquo;t to say that the data won&amp;rsquo;t eventually go public though.&lt;/p&gt;
-
-&lt;p&gt;An interesting thing you &lt;em&gt;can&lt;/em&gt; do with the Transit Wand data is import it into GTFS Editor to make a new route. You don&amp;rsquo;t even have to manually download and upload the data. Just type in your 6-digit identifier and it will give you a list of routes you&amp;rsquo;ve captured via Transit Wand. This is wonderful as you get all the stop data, as well as the shape of the route.&lt;/p&gt;
-
-&lt;p&gt;I imagine these two tools were how the DOTC came up with all the GTFS data we have now. What I don&amp;rsquo;t understand is why the shape data isn&amp;rsquo;t present. Importing from Transit Wand already gets you shape data. There are even facilities to edit the shape within the editor if clean up is necessary. The only problem I saw was the fact that you can&amp;rsquo;t easily move stops, you have to input coordinates to change the position.&lt;/p&gt;
-
-&lt;p&gt;It &lt;em&gt;might&lt;/em&gt; also be possible that when the DOTC was still collecting the data, the route collection or editing features weren&amp;rsquo;t present yet. That would just be lame and depressing though.&lt;/p&gt;
-
-&lt;p&gt;Overall, Transit Wand does what it&amp;rsquo;s supposed to do. You collect data, and then upload it to a server. There is a lot of room for improvement though. It would be nice to have a better API that allows access to more of the data. Building in analysis tools for the ridership data might also be a welcome thing. I imagine it would also be great if you could encourage people to use the app and upload their own trips.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/transit-wand.html</guid>
+      <description>Link: http://transitwand.com
+Overall, this was the simplest of the open-source transit tools to actually get up and running. There&amp;rsquo;s already a deployed instance of the server, and you can easily download the phone app via the Play Store. Even running the server by yourself didn&amp;rsquo;t have any of the hiccups I had with GTFS Editor.
+The phone app is actually quite simple. It allows you to capture a trip, which will record your GPS coordinates as you ride public transit.</description>
     </item>
     
     <item>
       <title>Fare Data</title>
-      <link>http://pleasantprogrammer.com/posts/fare-data.html</link>
+      <link>https://pleasantprogrammer.com/posts/fare-data.html</link>
       <pubDate>Sat, 13 Jul 2013 00:00:00 +0000</pubDate>
       
-      <guid>http://pleasantprogrammer.com/posts/fare-data.html</guid>
-      <description>
-
-&lt;p&gt;As part of the data released by the DOTC, we also have the &lt;a href=&#34;http://philippine-transit.hackathome.com/dataset-philippines-transit-information-service-gtfs/&#34;&gt;fare matrix&lt;/a&gt; for aircon buses, ordinary buses and jeeps. All as wonderful images. The data is also actually available from the &lt;a href=&#34;http://ltfrb.gov.ph/main/farerates&#34;&gt;LTFRB website&lt;/a&gt;. Generally, the fare scheme is represented as &amp;ldquo;pay &lt;em&gt;X&lt;/em&gt; pesos for the first &lt;em&gt;Y&lt;/em&gt; kilometers, pay &lt;em&gt;Z&lt;/em&gt; for every succeeding kilometer.&amp;rdquo; Instead of a table, we can simply represent this as a formula instead,&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;base_fare + (distance - initial) * per_km
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;The relevant values for the three services are:&lt;/p&gt;
-
-&lt;table&gt;
-&lt;thead&gt;
-  &lt;tr&gt;
-    &lt;td&gt;type&lt;/td&gt;
-    &lt;td&gt;base_fare&lt;/td&gt;
-    &lt;td&gt;initial&lt;/td&gt;
-    &lt;td&gt;per_km&lt;/td&gt;
-  &lt;/tr&gt;
-&lt;/thead&gt;
-&lt;tbody&gt;
-  &lt;tr&gt;
-    &lt;td&gt;bus aircon&lt;/td&gt;
-    &lt;td&gt;12.00&lt;/td&gt;
-    &lt;td&gt;5 km&lt;/td&gt;
-    &lt;td&gt;2.20&lt;/td&gt;
-  &lt;/tr&gt;
-  &lt;tr&gt;
-    &lt;td&gt;bus ordinary&lt;/td&gt;
-    &lt;td&gt;10.00&lt;/td&gt;
-    &lt;td&gt;5 km&lt;/td&gt;
-    &lt;td&gt;1.85&lt;/td&gt;
-  &lt;/tr&gt;
-  &lt;tr&gt;
-    &lt;td&gt;jeep aircon&lt;/td&gt;
-    &lt;td&gt;8.00&lt;/td&gt;
-    &lt;td&gt;4 km&lt;/td&gt;
-    &lt;td&gt;1.40&lt;/td&gt;
-  &lt;/tr&gt;
-&lt;/tbody&gt;
-&lt;/table&gt;
-
-&lt;p&gt;It isn&amp;rsquo;t as simple as that though. Fares are also rounded to the nearest 25 centavos. So we&amp;rsquo;d need to round them off correctly. This can be achieved by doing,&lt;/p&gt;
-&lt;div class=&#34;highlight&#34; style=&#34;background: #f8f8f8&#34;&gt;&lt;pre style=&#34;line-height: 125%&#34;&gt;&lt;span&gt;&lt;/span&gt;round(calculated_fare * 4.0)/4.0
-&lt;/pre&gt;&lt;/div&gt;
-
-&lt;p&gt;There&amp;rsquo;s also the discounted fare for students, senior citizens and persons with disability. They get 20% off the fare (prior to rounding) and the resulting fare is rounded off as well.&lt;/p&gt;
-
-&lt;p&gt;Doing just this, we actually do get the same results as the fare matrices in the image for the most part. There are some discrepancies with the discounted jeep fares. I&amp;rsquo;ve tried to resolve it by tweaking around with the formulas, but it really doesn&amp;rsquo;t make sense in any way. I presume these were manually adjusted for one reason or another.&lt;/p&gt;
-
-&lt;p&gt;Here&amp;rsquo;s a &lt;a href=&#34;../uploads/farematrix.rb&#34;&gt;script&lt;/a&gt; that generates CSVs of all the three fare matrices. If you&amp;rsquo;re too lazy to run it, here are links to the &lt;a href=&#34;../uploads/pub_aircon.csv&#34;&gt;aircon bus&lt;/a&gt;, &lt;a href=&#34;../uploads/pub_ordinary.csv&#34;&gt;ordinary bus&lt;/a&gt; and &lt;a href=&#34;../uploads/puj.csv&#34;&gt;jeep&lt;/a&gt; fare matrices.&lt;/p&gt;
-
-&lt;h3 id=&#34;gtfs-compatibility&#34;&gt;GTFS compatibility&lt;/h3&gt;
-
-&lt;p&gt;As is, the provided GTFS data does not have any fare data. I imagine this is because the existing spec doesn&amp;rsquo;t have good support for distance-based fares like we have in the Philippines. Judging from the &lt;a href=&#34;https://code.google.com/p/googletransitdatafeed/wiki/FareExamples&#34;&gt;fare examples&lt;/a&gt;, the only reasonable way we could implement distance-based fares is following example 6. This would involve setting a fare for each possible pair of stops based on the distance between them. This isn&amp;rsquo;t exactly ideal. In fact, the people originally working on the DOTC project have voiced &lt;a href=&#34;https://groups.google.com/forum/#!topic/gtfs-fare-wg/V63xRSnQJGw&#34;&gt;issues&lt;/a&gt; and made &lt;a href=&#34;https://groups.google.com/forum/#!msg/gtfs-changes/uybrAokZ9Cg/rqlzXdMypUgJ&#34;&gt;proposals&lt;/a&gt; for having distance-based fares included into GTFS.&lt;/p&gt;
-
-&lt;p&gt;Apparently, public transit fares are a really complicated thing. You have fares based on distance, number of stops passed through, and transfers which may or may not cost extra. Not only that, you might have discounted fares, or first-class vs economy fares. The community will want to get it right before it&amp;rsquo;s formally included in the spec. You can see the current state of the consolidated &lt;a href=&#34;https://docs.google.com/document/d/1mK3--o5g4-3cCXaqmch92U63JTwChh0L2VCmcDViIlM/edit&#34;&gt;GTFS fare proposal here&lt;/a&gt;.&lt;/p&gt;
-
-&lt;p&gt;Even in it&amp;rsquo;s proposal form though, we might have hope of being able to see these being used. There&amp;rsquo;s currently a &lt;a href=&#34;https://github.com/OneBusAway/onebusaway-gtfs-modules/pull/30&#34;&gt;pull request&lt;/a&gt; for supporting the distance-based fare scheme into the OneBusAway libraries. The libraries actually used by GTFS Editor and OpenTripPlanner for working with GTFS data.&lt;/p&gt;
-
-&lt;h3 id=&#34;remaining-problems&#34;&gt;Remaining Problems&lt;/h3&gt;
-
-&lt;p&gt;Given all that, it would probably still be a long way before this allows us to make a really good routing app. We still don&amp;rsquo;t have shape data, so the distance estimates would really be rough estimates at best. There&amp;rsquo;s no support for rounding to the nearest centavo. I realize that&amp;rsquo;s just nitpicking, but if we want something truly polished, even that has to be taken care of.&lt;/p&gt;
-
-&lt;p&gt;We also don&amp;rsquo;t know if the jeeps or buses strictly follow the distance-based scheme. After all, if you can get on and off anywhere, you can&amp;rsquo;t really measure distance that exactly. I assume they generally work off the notion of &amp;ldquo;zones&amp;rdquo; than actual distance travelled. In that sense, they work more similarly to the LRT which has fares based on how many stops you pass. For jeeps and buses, your fare is probably based more on how many &amp;ldquo;zones&amp;rdquo; you pass through.&lt;/p&gt;
-
-&lt;h3 id=&#34;conclusion&#34;&gt;Conclusion&lt;/h3&gt;
-
-&lt;p&gt;Philip, a co-worker of mine at By Implication, had suggested that we might want to use a different model than what the GTFS proposes. I have to agree with him. At this point, the GTFS doesn&amp;rsquo;t really fit with our system. But I do think that open data and standards are great. In fact, I applaud the developers who made proposals for the fare system, as those are great first steps towards making the GTFS a more universal standard.&lt;/p&gt;
-
-&lt;p&gt;Side note: I&amp;rsquo;d also actually really like to hear about the DOTC developers&amp;rsquo; experience with the project. It would be nice if they had a devblog.&lt;/p&gt;
-</description>
+      <guid>https://pleasantprogrammer.com/posts/fare-data.html</guid>
+      <description>As part of the data released by the DOTC, we also have the fare matrix for aircon buses, ordinary buses and jeeps. All as wonderful images. The data is also actually available from the LTFRB website. Generally, the fare scheme is represented as &amp;ldquo;pay X pesos for the first Y kilometers, pay Z for every succeeding kilometer.&amp;rdquo; Instead of a table, we can simply represent this as a formula instead,</description>
+    </item>
+    
+    <item>
+      <title>GTFS Editor</title>
+      <link>https://pleasantprogrammer.com/posts/gtfs-editor.html</link>
+      <pubDate>Wed, 10 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/gtfs-editor.html</guid>
+      <description>Link: https://github.com/conveyal/gtfs-editor
+TL;DR they really meant under development
+When I first saw the source of GTFS Editor, I was ecstatic. They used Play framework!!! Not only that, they&amp;rsquo;re targeting PostgreSQL as the main database. Those are our favorite tools for building webapps at By Implication. I was a bit sad though, when I saw it was on the 1.x release of Play though. I did have some experience with that release, but not as much compared to 2.</description>
+    </item>
+    
+    <item>
+      <title>One Bus (or maybe Jeep) Away</title>
+      <link>https://pleasantprogrammer.com/posts/one-bus-or-maybe-jeep-away.html</link>
+      <pubDate>Tue, 09 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/one-bus-or-maybe-jeep-away.html</guid>
+      <description>Link: http://onebusaway.org/
+TL;DR no routing; useless in Philippines
+OneBusAway is a transit information app. It provides data on what bus stops are near you, which buses pass by. You can also get schedules and the route of a particular bus given the number. It can also provide realtime updates like how many minutes until the next bus arrives. It does not, however, provide routing. There is no support for providing directions to get from point A to point B.</description>
+    </item>
+    
+    <item>
+      <title>Open Trip Planner</title>
+      <link>https://pleasantprogrammer.com/posts/open-trip-planner.html</link>
+      <pubDate>Tue, 09 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/open-trip-planner.html</guid>
+      <description>Link: http://www.opentripplanner.org
+TL;DR routes pretty well; data might cause weird issues
+OpenTripPlanner, as the name implies, is a routing app. Given point A and point B, it can provide possible routes by taking transit, riding a bike, or a mix of both. You can also specify options on how much walking you&amp;rsquo;re willing to do or if you prefer fewer transfers over trip time. It could be a good competitor to the transit directions of Google Maps.</description>
+    </item>
+    
+    <item>
+      <title>Jeepney and Bus Routes</title>
+      <link>https://pleasantprogrammer.com/posts/jeepney-and-bus-routes.html</link>
+      <pubDate>Sun, 07 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/jeepney-and-bus-routes.html</guid>
+      <description>In the last post, I talked about how we now have data about jeepney and bus routes in the Philippines. The data is actually in the GTFS format, which is the format the Google Maps consumes transit data. Apparently, the government will be submitting the GTFS data later this year. Transit directions for Metro Manila in Google Maps would be wonderful. That said, it definitely raises the bar for the app challenge people.</description>
+    </item>
+    
+    <item>
+      <title>Philippine Transit App Challenge</title>
+      <link>https://pleasantprogrammer.com/posts/philippine-transit-app-challenge.html</link>
+      <pubDate>Sun, 07 Jul 2013 00:00:00 +0000</pubDate>
+      
+      <guid>https://pleasantprogrammer.com/posts/philippine-transit-app-challenge.html</guid>
+      <description>Last week, the DOTC launched the Philippine Transit App Challenge. It&amp;rsquo;s a competition to build something great using the newly available 1) jeepney/bus/rail routes and 2) traffic incident data in Metro Manila and Cebu.
+I&amp;rsquo;m actually quite excited about this as it&amp;rsquo;s not everyday our government does wonderful things. Many people have been waiting for this kind of data to be available. Before, the only way to figure out which jeeps to ride to get from A to B is by asking other people.</description>
     </item>
     
   </channel>

+ 49 - 36
output/sitemap.xml

@@ -1,185 +1,198 @@
 <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
-<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
+<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
+  xmlns:xhtml="http://www.w3.org/1999/xhtml">
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/audventure.html</loc>
+    <loc>https://pleasantprogrammer.com/pages/projects.html</loc>
+    <lastmod>2018-02-10T16:47:55+09:00</lastmod>
+  </url>
+  
+  <url>
+    <loc>https://pleasantprogrammer.com/posts/audventure.html</loc>
     <lastmod>2017-11-19T22:00:00+08:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/openpreppad.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/openpreppad.html</loc>
     <lastmod>2017-01-15T19:31:00+08:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/haproxy-charset.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/haproxy-charset.html</loc>
     <lastmod>2016-06-24T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/cloudflare-shenanigans.html</loc>
     <lastmod>2015-12-25T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/tiddlywiki-in-the-sky-or-tiddlyweb-for-tw5.html</loc>
     <lastmod>2015-12-24T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/is-my-terminal-window-active.html</loc>
     <lastmod>2015-06-07T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/removing-pldtmydslbiz-from-the-zyxel-p-2612hnu.html</loc>
     <lastmod>2013-11-27T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/console-keymap-switching.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/console-keymap-switching.html</loc>
     <lastmod>2013-10-29T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/geocoding-services.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/geocoding-services.html</loc>
     <lastmod>2013-09-25T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/jeep-and-bus-schedules.html</loc>
     <lastmod>2013-07-28T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/highways-in-otp.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/highways-in-otp.html</loc>
     <lastmod>2013-07-24T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/elevation-data-in-otp.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/elevation-data-in-otp.html</loc>
     <lastmod>2013-07-23T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/graphserver.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/graphserver.html</loc>
     <lastmod>2013-07-23T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/transit-wand.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/transit-wand.html</loc>
     <lastmod>2013-07-15T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/fare-data.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/fare-data.html</loc>
     <lastmod>2013-07-13T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/gtfs-editor.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/gtfs-editor.html</loc>
     <lastmod>2013-07-10T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/one-bus-or-maybe-jeep-away.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/one-bus-or-maybe-jeep-away.html</loc>
     <lastmod>2013-07-09T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/open-trip-planner.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/open-trip-planner.html</loc>
     <lastmod>2013-07-09T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/jeepney-and-bus-routes.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/jeepney-and-bus-routes.html</loc>
     <lastmod>2013-07-07T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts/philippine-transit-app-challenge.html</loc>
+    <loc>https://pleasantprogrammer.com/posts/philippine-transit-app-challenge.html</loc>
     <lastmod>2013-07-07T00:00:00+00:00</lastmod>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/bluetooth.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/bluetooth.html</loc>
     <lastmod>2017-01-15T19:31:00+08:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/cloudflare.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/cloudflare.html</loc>
     <lastmod>2015-12-25T00:00:00+00:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/games.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/games.html</loc>
     <lastmod>2017-11-19T22:00:00+08:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/haproxy.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/haproxy.html</loc>
     <lastmod>2016-06-24T00:00:00+00:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/hardware.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/hardware.html</loc>
     <lastmod>2017-01-15T19:31:00+08:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/lets-debug.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/lets-debug.html</loc>
     <lastmod>2013-07-10T00:00:00+00:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/philippine-transit-app.html</loc>
+    <loc>https://pleasantprogrammer.com/pages.html</loc>
+    <lastmod>2018-02-10T16:47:55+09:00</lastmod>
+    <priority>0</priority>
+  </url>
+  
+  <url>
+    <loc>https://pleasantprogrammer.com/tags/philippine-transit-app.html</loc>
     <lastmod>2013-09-25T00:00:00+00:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/</loc>
-    <lastmod>2017-11-19T22:00:00+08:00</lastmod>
+    <loc>https://pleasantprogrammer.com/</loc>
+    <lastmod>2018-02-10T16:47:55+09:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/posts.html</loc>
+    <loc>https://pleasantprogrammer.com/posts.html</loc>
     <lastmod>2017-11-19T22:00:00+08:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/programming.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/programming.html</loc>
     <lastmod>2017-11-19T22:00:00+08:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/sysadmin.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/sysadmin.html</loc>
     <lastmod>2016-06-24T00:00:00+00:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/systemd.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/systemd.html</loc>
     <lastmod>2013-10-29T00:00:00+00:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags.html</loc>
+    <loc>https://pleasantprogrammer.com/tags.html</loc>
+    <lastmod>2017-01-15T19:31:00+08:00</lastmod>
     <priority>0</priority>
   </url>
   
   <url>
-    <loc>http://pleasantprogrammer.com/tags/tiddlywiki.html</loc>
+    <loc>https://pleasantprogrammer.com/tags/tiddlywiki.html</loc>
     <lastmod>2015-12-24T00:00:00+00:00</lastmod>
     <priority>0</priority>
   </url>

+ 3 - 2
output/tags.html

@@ -2,7 +2,7 @@
 <html lang="en-us">
 <head>
 	<meta charset="utf-8">
-	<meta name="generator" content="Hugo 0.18.1" />
+	<meta name="generator" content="Hugo 0.36" />
 	<meta name="viewport" content="width=device-width, initial-scale=1">
 	<link rel="stylesheet" href="/assets/css/theme.css">
 	<link rel="alternate" href="/rss.xml" type="application/rss+xml" title="Pleasant Programmer">
@@ -23,6 +23,7 @@
 				<li class="twitter">
 					<a href="http://twitter.com/pleasantprog">@pleasantprog</a>
 				</li>
+				<li><a href="/pages/projects.html">projects</a></li>
 				<li><a href="/posts.html">archives</a></li>
 				<li><a href="/tags.html">tags</a></li>
 				<li><a href="/rss.xml">rss</a></li>
@@ -72,7 +73,7 @@
 		<p>
 		<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/deed.en_US">
 			<img alt="CC-BY-SA" style="border-width:0" src="https://licensebuttons.net/l/by-sa/3.0/80x15.png">
-		</a> &copy; 2017 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
+		</a> &copy; 2018 Thomas Dy - Powered by <a href="http://gohugo.io">Hugo</a></p>
 	</footer>
 </div>