diff options
Diffstat (limited to 'source')
48 files changed, 59 insertions, 153 deletions
diff --git a/source/blog/2014-10-20-hello-octopress.md b/source/blog/2014-10-20-hello-octopress.md index d359f401..733bb963 100644 --- a/source/blog/2014-10-20-hello-octopress.md +++ b/source/blog/2014-10-20-hello-octopress.md @@ -1,9 +1,7 @@ --- -layout: post title: "Hello, Octopress!" date: 2014-10-20 16:53:00 -0700 -comments: true -categories: +date-display: October 20, 2014 --- This post marks my transition from Tumblr to Octopress & GitHub Pages. @@ -20,7 +18,7 @@ Speaking of the last point, I've always been envious of the beautiful code block (Let me give it a try first.) -``` C hello.c +``` C #include <stdio.h> int main(int argc, char **argv) { @@ -32,4 +30,6 @@ Gorgeous. I'll get to the theme customization later. I'm actually busy as crazy Before I close this post, let me also try to embed a random gist I authored yesterday (for brewing): +``` {% gist 828fd00bdecd6611cf40 brew.sh %} +``` diff --git a/source/blog/2014-10-20-help-mou-hit-1-dot-0.md b/source/blog/2014-10-20-help-mou-hit-1-dot-0.md index 22587df4..4f7e4cd6 100644 --- a/source/blog/2014-10-20-help-mou-hit-1-dot-0.md +++ b/source/blog/2014-10-20-help-mou-hit-1-dot-0.md @@ -1,13 +1,11 @@ --- -layout: post title: "Help Mou hit 1.0" date: 2014-10-20 17:37:45 -0700 -comments: true -categories: +date-display: October 20, 2014 --- Quick call for [Mou 1.0 fundraiser](https://www.indiegogo.com/projects/mou-1-0-markdown-editor-on-os-x-for-you) on Indiegogo. At the time of writing, it has raised $6,178/$20,000, and has 39 days to go (with 21 already passed). I'm actually writing this post in Mou right now. It's far less powerful than Emacs, but when I want preview-on-the-fly, Mou is the Markdown editor to go. Right now it's far from perfect; for instance, GFM fenced blocks (now included in [CommonMark](http://commonmark.org)) are not supported, so you get nonsense preview when your code block is fenced rather than indented. (Of course, Mou is even less suitable for editing an Octopress post due to the yaml metadata upfront, but that's not a big deal.) -Let's hope for Mou hitting the 1.0 mark.
\ No newline at end of file +Let's hope for Mou hitting the 1.0 mark. diff --git a/source/blog/2014-10-21-get-rolling.md b/source/blog/2014-10-21-get-rolling.md index bf8f040e..d0dd4c48 100644 --- a/source/blog/2014-10-21-get-rolling.md +++ b/source/blog/2014-10-21-get-rolling.md @@ -1,9 +1,7 @@ --- -layout: post title: "Get rolling" date: 2014-10-21 11:40:14 -0700 -comments: true -categories: +date-display: October 21, 2014 --- Yesterday, on an internet forum, I saw someone’s signature, which translates to diff --git a/source/blog/2014-10-23-ripping-copy-protected-dvd-with-mpv.md b/source/blog/2014-10-23-ripping-copy-protected-dvd-with-mpv.md index 4db51a86..6d1f983b 100644 --- a/source/blog/2014-10-23-ripping-copy-protected-dvd-with-mpv.md +++ b/source/blog/2014-10-23-ripping-copy-protected-dvd-with-mpv.md @@ -1,9 +1,7 @@ --- -layout: post title: "Ripping copy-protected DVD with mpv" date: 2014-10-23 20:03:22 -0700 -comments: true -categories: +date-display: October 23, 2014 --- **_11/02/2014 update:_** diff --git a/source/blog/2014-10-24-charles-munger-donated-$65m-to-kitp.md b/source/blog/2014-10-24-charles-munger-donated-$65m-to-kitp.md index 9c37b99e..88d7f7ef 100644 --- a/source/blog/2014-10-24-charles-munger-donated-$65m-to-kitp.md +++ b/source/blog/2014-10-24-charles-munger-donated-$65m-to-kitp.md @@ -1,9 +1,7 @@ --- -layout: post title: "Charles Munger donated $65M to KITP" date: 2014-10-24 16:41:36 -0700 -comments: true -categories: +date-display: October 24, 2014 --- Today's news has it that Charles Munger made a $65 million donation to KITP at UCSB. See for instance [this article](http://nyti.ms/1D4zg24) on NYT. Of course I didn't learn it from NYT (I'm generally sick of any news other than math, physics, or IT-related ones). I learned it from [Not Even Wrong](http://www.math.columbia.edu/~woit/wordpress/?p=7247) instead (of course I don't agree with Woit, but some of his links are nice). diff --git a/source/blog/2014-10-25-os-x-package-receipts.md b/source/blog/2014-10-25-os-x-package-receipts.md index a3695600..1c4ab434 100644 --- a/source/blog/2014-10-25-os-x-package-receipts.md +++ b/source/blog/2014-10-25-os-x-package-receipts.md @@ -1,9 +1,7 @@ --- -layout: post title: "OS X package receipts" date: 2014-10-25 13:26:02 -0700 -comments: true -categories: +date-display: October 25, 2014 --- I just learned something new. Whenever you install a `pkg` on OS X, OS X stores a receipt of what was installed in `/var/db/receipts` (I'm running OS X 10.9.5 at the time of writing), called a **bom** — bill of materials (I’d rather call it a manifest, whatever). This feature was introduced in NeXTSTEP. From `man 5 bom`: diff --git a/source/blog/2014-10-26-audio-cd-slash-dvd-to-iso-image-on-os-x.md b/source/blog/2014-10-26-audio-cd-slash-dvd-to-iso-image-on-os-x.md index 7ff57bc8..61504a15 100644 --- a/source/blog/2014-10-26-audio-cd-slash-dvd-to-iso-image-on-os-x.md +++ b/source/blog/2014-10-26-audio-cd-slash-dvd-to-iso-image-on-os-x.md @@ -1,9 +1,7 @@ --- -layout: post title: "Convert Audio CD/DVD to ISO image on OS X" date: 2014-10-26 23:29:47 -0700 -comments: true -categories: +date-display: October 26, 2014 --- **_11/02/2014 update:_** diff --git a/source/blog/2014-10-26-disk-visualizer-daisydisk.md b/source/blog/2014-10-26-disk-visualizer-daisydisk.md index 2de4201e..786f89b8 100644 --- a/source/blog/2014-10-26-disk-visualizer-daisydisk.md +++ b/source/blog/2014-10-26-disk-visualizer-daisydisk.md @@ -1,9 +1,7 @@ --- -layout: post title: "Disk visualizer: DaisyDisk" date: 2014-10-26 00:02:22 -0700 -comments: true -categories: +date-display: October 26, 2014 --- DaisyDisk is a pretty famous name. I’ve heard a lot that DaisyDisk is beautiful, but as a “power user” I always feel ashamed about using a disk analyzer or visualizer (although no one really cares). I’m pretty comfortable with doing most filesystem operations right in the shell, and for other tasks too tedious for the shell (like renaming a bunch of files with no obvious pattern), Finder (equipped with TotalFinder) works just fine. diff --git a/source/blog/2014-10-27-onedrive-goes-unlimited.md b/source/blog/2014-10-27-onedrive-goes-unlimited.md index 256b04e6..4c4cb64d 100644 --- a/source/blog/2014-10-27-onedrive-goes-unlimited.md +++ b/source/blog/2014-10-27-onedrive-goes-unlimited.md @@ -1,9 +1,7 @@ --- -layout: post title: "OneDrive goes unlimited" date: 2014-10-27 09:44:51 -0700 -comments: true -categories: +date-display: October 27, 2014 --- **10/28/2014 Update:** diff --git a/source/blog/2014-10-28-google-drive-no-selective-subfolder-sync.md b/source/blog/2014-10-28-google-drive-no-selective-subfolder-sync.md index 2383a0da..de219eaa 100644 --- a/source/blog/2014-10-28-google-drive-no-selective-subfolder-sync.md +++ b/source/blog/2014-10-28-google-drive-no-selective-subfolder-sync.md @@ -1,9 +1,7 @@ --- -layout: post title: "Google Drive — no selective subfolder sync?" date: 2014-10-28 20:49:24 -0700 -comments: true -categories: +date-display: October 28, 2014 --- Up to this point I've been using Google Drive as an online backup service, and uploads files mostly manually, although I do sync `~/img` with the client. diff --git a/source/blog/2014-10-28-mou-1-dot-0-fundraiser-goal-reached.md b/source/blog/2014-10-28-mou-1-dot-0-fundraiser-goal-reached.md index bec69ef7..ad28afdd 100644 --- a/source/blog/2014-10-28-mou-1-dot-0-fundraiser-goal-reached.md +++ b/source/blog/2014-10-28-mou-1-dot-0-fundraiser-goal-reached.md @@ -1,9 +1,7 @@ --- -layout: post title: "Mou 1.0 fundraiser: goal reached" date: 2014-10-28 01:57:06 -0700 -comments: true -categories: +date-display: October 28, 2014 --- A week ago I wrote a post [*Help Mou hit 1.0*](blog/2014/10/20/help-mou-hit-1-dot-0/). Today, I'm delighted to find out that Mou has reached its goal, $20,000, half way into the fundraiser. diff --git a/source/blog/2014-10-29-fun.md b/source/blog/2014-10-29-fun.md index ce32a9b0..961de1ad 100644 --- a/source/blog/2014-10-29-fun.md +++ b/source/blog/2014-10-29-fun.md @@ -1,9 +1,7 @@ --- -layout: post title: "Fun" date: 2014-10-29 11:26:29 -0700 -comments: true -categories: +date-display: October 29, 2014 --- This happened in yesterday's Math 210A lecture. diff --git a/source/blog/2014-11-02-vobcopy-dvdbackup-etc.md b/source/blog/2014-11-02-vobcopy-dvdbackup-etc.md index b8690912..0bb4b94f 100644 --- a/source/blog/2014-11-02-vobcopy-dvdbackup-etc.md +++ b/source/blog/2014-11-02-vobcopy-dvdbackup-etc.md @@ -1,9 +1,7 @@ --- -layout: post title: "vobcopy, dvdbackup, etc." date: 2014-11-02 15:06:07 -0800 -comments: true -categories: +date-display: November 2, 2014 --- A few days ago, I was cloning my entire Audio CD and DVD collection, and reported some of the findings in [this post](/blog/2014/10/26/audio-cd-slash-dvd-to-iso-image-on-os-x/). As said, the most important commands are diff --git a/source/blog/2014-11-05-apple-is-pushing-yosemite-hard.md b/source/blog/2014-11-05-apple-is-pushing-yosemite-hard.md index 0324c26c..3e2bf44b 100644 --- a/source/blog/2014-11-05-apple-is-pushing-yosemite-hard.md +++ b/source/blog/2014-11-05-apple-is-pushing-yosemite-hard.md @@ -1,9 +1,7 @@ --- -layout: post title: "Apple is pushing Yosemite hard" date: 2014-11-05 22:17:01 -0800 -comments: true -categories: +date-display: November 5, 2014 --- Apple is pushing Yosemite hard and secretly Yosemitizing things. iTunes was updated to its shiny new look on Mavericks, day one upon Yosemite launch. I liked it. The only problems I had with the new iTunes are: diff --git a/source/blog/2014-11-05-list-youtube-playlist-with-youtube-dl.md b/source/blog/2014-11-05-list-youtube-playlist-with-youtube-dl.md index a0d8af7b..59bd1002 100644 --- a/source/blog/2014-11-05-list-youtube-playlist-with-youtube-dl.md +++ b/source/blog/2014-11-05-list-youtube-playlist-with-youtube-dl.md @@ -1,9 +1,7 @@ --- -layout: post title: "List YouTube playlist with youtube-dl" date: 2014-11-05 10:37:58 -0800 -comments: true -categories: +date-display: November 5, 2014 --- Of course you are always welcome to use the [Google APIs Client Library for Python](https://developers.google.com/api-client-library/python/) to wrestle with YouTube, which is usually pretty simple. (As an added bonus, YouTube has some [nice runnable sample scripts](https://developers.google.com/youtube/v3/code_samples/) to get you started.) With the client library, listing videos in a YouTube playlist is a breeze. @@ -49,7 +47,7 @@ https://youtube.com/v/qyE7-auTIcc There you go, a list of URIs you can use. Of course you can put this in a script to save some typing: -```bash youtube-ls-playlist.sh https://gist.github.com/zmwangx/0245788475f963210ed9 Gist +```bash #!/usr/bin/env bash # Takes a YouTube URI to a playlist (fairly liberal, it's fine as long # as the playlist id can be extracted), and prints a list of URIs in a diff --git a/source/blog/2014-11-06-2014-nobel-prize-in-physics-led-lights-seriously.md b/source/blog/2014-11-06-2014-nobel-prize-in-physics-led-lights-seriously.md index f68ea55d..690fb119 100644 --- a/source/blog/2014-11-06-2014-nobel-prize-in-physics-led-lights-seriously.md +++ b/source/blog/2014-11-06-2014-nobel-prize-in-physics-led-lights-seriously.md @@ -1,9 +1,7 @@ --- -layout: post title: "2014 Nobel Prize in Physics — LED lights, seriously?" date: 2014-11-06 11:08:45 -0800 -comments: true -categories: +date-display: November 6, 2014 --- For some reason, I only learned about this year’s laureates today, through [the reference frame](http://motls.blogspot.com/2014/11/ex-employer-wont-meet-blue-led-nobel.html). The prize goes to the inventors of the LED. Not exciting at all, so I don’t care if I’m ever informed. (Lubos has a good point on why applied physics — well, let’s even widen the concept of applied physics a bit — should not surprise anyone when they appear in a Nobel Prize announcement: “After all, Alfred Nobel might have very well considered his dynamite to be a discovery in physics, too.”) diff --git a/source/blog/2014-11-07-interstellar.md b/source/blog/2014-11-07-interstellar.md index 8cd93b8f..3e3ebd68 100644 --- a/source/blog/2014-11-07-interstellar.md +++ b/source/blog/2014-11-07-interstellar.md @@ -1,9 +1,7 @@ --- -layout: post title: "Interstellar" date: 2014-11-07 23:56:31 -0800 -comments: true -categories: +date-display: November 7, 2014 --- Today (I mean November 7, 2014 — it’s technically November 8 at the time of writing) I saw [*Interstellar*](https://en.wikipedia.org/wiki/Interstellar_%28film%29) (IMAX digital) at AMC Mercado 20. I rarely go to movie theaters, less on the release day (film formats of *Interstellar* were released on November 5, and digital formats followed on November 7). However, reviews of it were positive (from the physics community), and I really need a way to release stress these days — I wasn’t in the right condition for months. So I figured I’d just spend an afternoon in front of the big screen. diff --git a/source/blog/2014-11-10-average-phone-plan-in-the-u-dot-s-costs-ten-time-as-much-as-that-in-the-u-dot-k.md b/source/blog/2014-11-10-average-phone-plan-in-the-u-dot-s-costs-ten-time-as-much-as-that-in-the-u-dot-k.md index 1bce5027..bf058474 100644 --- a/source/blog/2014-11-10-average-phone-plan-in-the-u-dot-s-costs-ten-time-as-much-as-that-in-the-u-dot-k.md +++ b/source/blog/2014-11-10-average-phone-plan-in-the-u-dot-s-costs-ten-time-as-much-as-that-in-the-u-dot-k.md @@ -1,9 +1,7 @@ --- -layout: post title: "Average phone plan in the U.S. costs ten time as much as that in the U.K." date: 2014-11-10 11:11:46 -0800 -comments: true -categories: +date-display: November 10, 2014 --- To quote [Opera News](http://blogs.opera.com/news/2014/11/mobile-data-anyway/), diff --git a/source/blog/2014-11-11-re-encoding-everything-for-iphone-6-plus.md b/source/blog/2014-11-11-re-encoding-everything-for-iphone-6-plus.md index 51d5ed37..966af625 100644 --- a/source/blog/2014-11-11-re-encoding-everything-for-iphone-6-plus.md +++ b/source/blog/2014-11-11-re-encoding-everything-for-iphone-6-plus.md @@ -1,8 +1,6 @@ --- -layout: post title: "Re-encoding everything for iPhone 6 Plus" date: 2014-11-11 13:31:25 -0800 -comments: true -categories: +date-display: November 11, 2014 --- AT&T finally delivered my iPhone 6 Plus (silver, 64 GB) after about fifty days since preorder… The 1080p Retina display is simply stunning. However, it turns out that my old videos don’t work so well on 6 Plus’s giant screen. My old mobile video collection was optimized for my 16 GB 4S, targeting the small screen and highly limited storage — you guessed it, they were resized to 960x540, and they looked great. But they’re not up to the task any more. 960x540 videos aren’t at all sharp on the stunning screen of 6 Plus, which is more than capable of handling 4x pixels. Therefore, I have no choice but to feed it more pixels. I’m left in a weird situation, where my 1080p desktop (or even HDTV) quality videos should fit the screen just fine, but H.264 profile stands in the way. iPhone 6 and 6 Plus are only capable of High Profile level 4.2, so anything encoded in level 5.1, for instance, needs to be re-encoded. Also there are still MPEG-2 and MPEG-4 videos out there (MPEG-4 should be obsolete by now, I assume, but some people still use it; and MPEG-2 is de facto in TV broadcasts), which have to be transcoded. Okay, it’s a daunting task to re-encode a fairly big collection, but I have to do it sooner or later. Presumably this weekend. I’ll also report whether 720p videos look sharp on the screen later. diff --git a/source/blog/2014-11-19-convolution-of-irreducible-characters.md b/source/blog/2014-11-19-convolution-of-irreducible-characters.md index f3f3207e..58a58925 100644 --- a/source/blog/2014-11-19-convolution-of-irreducible-characters.md +++ b/source/blog/2014-11-19-convolution-of-irreducible-characters.md @@ -1,9 +1,7 @@ --- -layout: post title: "Convolution of irreducible characters" date: 2014-11-19 20:40:37 -0800 -comments: true -categories: +date-display: November 19, 2014 --- __*TL; DR:* The actual PDF write-up is [here](https://dl.bintray.com/zmwangx/generic/20141119-convolution-of-irreducible-characters.pdf).__ diff --git a/source/blog/2014-11-20-dropbot-for-geeks(r).md b/source/blog/2014-11-20-dropbot-for-geeks(r).md index ad075302..e46ec401 100644 --- a/source/blog/2014-11-20-dropbot-for-geeks(r).md +++ b/source/blog/2014-11-20-dropbot-for-geeks(r).md @@ -1,9 +1,7 @@ --- -layout: post title: "Dropbot for Geeks®" date: 2014-11-20 09:48:15 -0800 -comments: true -categories: +date-display: November 20, 2014 --- I propose the following cloud storage and syncing service model of the future. I call it **Dropbot for Geeks®**, and it totally rules. It's designed for geeks who are tired of the highly limited, miserably unproductive traditional services (based on clicking around). It has the following features: diff --git a/source/blog/2014-11-24-iphone-photography-frustration.md b/source/blog/2014-11-24-iphone-photography-frustration.md index 1a375f25..c3a4858c 100644 --- a/source/blog/2014-11-24-iphone-photography-frustration.md +++ b/source/blog/2014-11-24-iphone-photography-frustration.md @@ -1,9 +1,7 @@ --- -layout: post title: "iPhone photography frustration" date: 2014-11-24 12:42:25 -0800 -comments: true -categories: +date-display: November 24, 2014 --- **TL; DR:** Jump to the paragraph “In the end…” diff --git a/source/blog/2014-11-24-why-i-abandoned-mathjax-and-fell-back-to-pdf.md b/source/blog/2014-11-24-why-i-abandoned-mathjax-and-fell-back-to-pdf.md index 10f105d8..2d2781e6 100644 --- a/source/blog/2014-11-24-why-i-abandoned-mathjax-and-fell-back-to-pdf.md +++ b/source/blog/2014-11-24-why-i-abandoned-mathjax-and-fell-back-to-pdf.md @@ -1,9 +1,7 @@ --- -layout: post title: "Why I abandoned MathJax and fell back to PDF" date: 2014-11-24 20:54:36 -0800 -comments: true -categories: +date-display: November 24, 2014 --- Recently I wrote an expository article, [*Convolution of irreducible characters*](/pdf/20141119-convolution-of-irreducible-characters.pdf), and posted it [here](/blog/2014/11/19/convolution-of-irreducible-characters/). At first I intended to use MathJax, but in the end I fell back to good ol' PDF. Here's why. diff --git a/source/blog/2014-11-25-i-got-16-gigs-of-ram.md b/source/blog/2014-11-25-i-got-16-gigs-of-ram.md index d55a642e..0ece218a 100644 --- a/source/blog/2014-11-25-i-got-16-gigs-of-ram.md +++ b/source/blog/2014-11-25-i-got-16-gigs-of-ram.md @@ -1,9 +1,7 @@ --- -layout: post title: "I got 16 gigs of RAM" date: 2014-11-25 16:28:30 -0800 -comments: true -categories: +date-display: November 25, 2014 --- Today I upgraded the RAM of my MacBook Pro mid-2012 to 2x8GB. I purchased the [Crucial 16GB Kit (8GBx2) DDR3/DDR3L 1600 MHz (PC3-12800) CL11 SODIMM 204-Pin 1.35V/1.5V Memory for Mac CT2K8G3S160BM](http://smile.amazon.com/dp/B008LTBJFW) from Amazon, which cose me $146.64 after tax. I followed the [official guide](http://support.apple.com/en-us/HT201165) as well as the [iFixit guide](https://www.ifixit.com/Guide/MacBook+Pro+13-Inch+Unibody+Mid+2012+RAM+Replacement/10374). To finish the job I needed a Phillips #00 screwdriver and a spudger, so I purchased the [spudger](https://www.ifixit.com/Store/Tools/Spudger/IF145-002) and the [54 bit driver kit](https://www.ifixit.com/Store/Tools/54-Bit-Driver-Kit/IF145-022-1) from iFixit. diff --git a/source/blog/2014-11-26-original-images-in-day-one-journal.md b/source/blog/2014-11-26-original-images-in-day-one-journal.md index c738699c..1ce7a5cc 100644 --- a/source/blog/2014-11-26-original-images-in-day-one-journal.md +++ b/source/blog/2014-11-26-original-images-in-day-one-journal.md @@ -1,9 +1,7 @@ --- -layout: post title: "Original images in Day One journal" date: 2014-11-26 00:22:16 -0800 -comments: true -categories: +date-display: November 26, 2014 --- **TL; DR:** Jump to the paragraph beginning with “workaround”. diff --git a/source/blog/2014-11-28-given-infinite-time.md b/source/blog/2014-11-28-given-infinite-time.md index 833b4de4..00c53eae 100644 --- a/source/blog/2014-11-28-given-infinite-time.md +++ b/source/blog/2014-11-28-given-infinite-time.md @@ -1,8 +1,6 @@ --- -layout: post title: "Given infinite time" date: 2014-11-28 00:18:19 -0800 -comments: true -categories: +date-display: November 28, 2014 --- Given infinite time. There's so much I can do *given infinite time*. I don't think I'll ever be bored. But sadly the time assigned to each human being is finite. Actually it's epsilon, epsilon approaching zero. Sadly. diff --git a/source/blog/2014-11-28-going-diceware.md b/source/blog/2014-11-28-going-diceware.md index e649f374..9f12d8d8 100644 --- a/source/blog/2014-11-28-going-diceware.md +++ b/source/blog/2014-11-28-going-diceware.md @@ -1,9 +1,7 @@ --- -layout: post title: "Going Diceware" date: 2014-11-28 19:05:59 -0800 -comments: true -categories: +date-display: November 28, 2014 --- Today I'm officially going [Diceware](http://world.std.com/~reinhold/diceware.html). I published my simple C implementation of diceware on [GitHub](https://github.com/zmwangx/diceware). diff --git a/source/blog/2014-11-30-opera-style-advanced-keyboard-shortcuts-in-safari.md b/source/blog/2014-11-30-opera-style-advanced-keyboard-shortcuts-in-safari.md index f76879f3..448fc331 100644 --- a/source/blog/2014-11-30-opera-style-advanced-keyboard-shortcuts-in-safari.md +++ b/source/blog/2014-11-30-opera-style-advanced-keyboard-shortcuts-in-safari.md @@ -1,9 +1,7 @@ --- -layout: post title: "Opera-style advanced keyboard shortcuts in Safari" date: 2014-11-30 17:20:20 -0800 -comments: true -categories: +date-display: November 30, 2014 --- I've been using the Chromuim Opera for a long time, after Chrome's design went unbearably ugly around v32 (IIRC Opera stable channel was on v19 when I switched, which was released on January 28, 2014). From then on, Opera's [advanced keyboard shortcuts](http://help.opera.com/opera/Mac/1583/en/fasterBrowsing.html#advanced) has become an integral part of my browsing habit. In particular, the following are especially handy for me: @@ -18,7 +16,7 @@ I've been using the Chromuim Opera for a long time, after Chrome's design went u Lately, with the Yosemite release, Safari has become a much more competitive browser. I won't say why, and I admit that it has major missing features that still prevents it from becoming my default — but I have to say I’m gradually moving more of more of my browsing, especially reading, to Safari. It would be nice if I could carry my power user shortcuts with me. Fortunately, this is possible. Just modify the plist in the following way: -```bash safari-advanced-keyboard-shortcuts.sh +```bash #!/usr/bin/env bash defaults write com.apple.Safari NSUserKeyEquivalents '{ "Actual Size"="6"; diff --git a/source/blog/2014-12-05-distraction-free-writing.md b/source/blog/2014-12-05-distraction-free-writing.md index 122f6fc2..80a46284 100644 --- a/source/blog/2014-12-05-distraction-free-writing.md +++ b/source/blog/2014-12-05-distraction-free-writing.md @@ -1,9 +1,7 @@ --- -layout: post title: "Distraction free writing" date: 2014-12-05 21:09:10 -0800 -comments: true -categories: +date-display: December 5, 2014 --- This is not the first time that a distraction free writing app is featured on the Mac App Store. This time the candidate is [Desk](https://itunes.apple.com/us/app/desk/id915839505?mt=12). The official website is [here](http://desk.pm), but licensing is MAS-exclusive. The icon looks like this: diff --git a/source/blog/2014-12-05-python-3-and-unicode.md b/source/blog/2014-12-05-python-3-and-unicode.md index d7d871d8..eb596956 100644 --- a/source/blog/2014-12-05-python-3-and-unicode.md +++ b/source/blog/2014-12-05-python-3-and-unicode.md @@ -1,8 +1,6 @@ --- -layout: post title: "Python 3 and Unicode" date: 2014-12-05 15:01:54 -0800 -comments: true -categories: +date-display: December 5, 2014 --- I never realized that in Python 3 Unicode is the default; in particular, `str` in Python 3 is practically equivalent to `unicode` in Python 2. This might be the *one thing* that convince me to migrate. `str.encode()`, `str.decode()`, `unicode.encode()`, `unicode.decode()`, etc. are so confusing that I'm never 100% sure what I'm doing (only-occasionally-used-but-unavoidable-and-worst-of-all-very-confusing "features" are nightmares). diff --git a/source/blog/2014-12-10-omnifocus-change-sync-behavior-mac-and-ios.md b/source/blog/2014-12-10-omnifocus-change-sync-behavior-mac-and-ios.md index 4ee29d57..ab0a3d30 100644 --- a/source/blog/2014-12-10-omnifocus-change-sync-behavior-mac-and-ios.md +++ b/source/blog/2014-12-10-omnifocus-change-sync-behavior-mac-and-ios.md @@ -1,9 +1,7 @@ --- -layout: post title: "OmniFocus: change sync behavior, Mac and iOS" date: 2014-12-10 22:45:34 -0800 -comments: true -categories: +date-display: December 10, 2014 --- On OS X, the following URIs are relevant: diff --git a/source/blog/2014-12-13-the-mac-like-evernote.md b/source/blog/2014-12-13-the-mac-like-evernote.md index 7eacfad3..5109e795 100644 --- a/source/blog/2014-12-13-the-mac-like-evernote.md +++ b/source/blog/2014-12-13-the-mac-like-evernote.md @@ -1,9 +1,7 @@ --- -layout: post title: "The Mac-like Evernote" date: 2014-12-13 21:47:31 -0800 -comments: true -categories: +date-display: December 13, 2014 --- Once in a while (maybe a year, maybe several months — not set in stone), I give big name free services not in use a chance to convince me. Evernote is one such service. The interface used to look very cheap and cluttered. I hated it. However, this time I'm sold. Now everything Evernote, from its Mac app to its iOS app to its web design to its physical products, looks distinctively Mac-like. (I use Mac-like to refer to Apple's design philosophy, including iOS. Well, I guess the Android and Windows apps aren't Mac-like.) I mean, just look at the screenshots: diff --git a/source/blog/2014-12-14-speeding-up-emacs-with-emacsclient.md b/source/blog/2014-12-14-speeding-up-emacs-with-emacsclient.md index f82f63cf..7d01cc9f 100644 --- a/source/blog/2014-12-14-speeding-up-emacs-with-emacsclient.md +++ b/source/blog/2014-12-14-speeding-up-emacs-with-emacsclient.md @@ -1,9 +1,7 @@ --- -layout: post title: "Speeding up Emacs with emacsclient" date: 2014-12-14 10:06:02 -0800 -comments: true -categories: +date-display: December 14, 2014 --- Emacs is notorious for its loading time. For me, this is especially annoying when I'm editing LaTeX files — AUCTeX takes about five seconds to load, and once I exit Emacs (especially after a quick edit), all that work is wasted, and next time I want to do some quick editing with that same LaTeX file — sorry, another five seconds. @@ -13,7 +11,7 @@ This problem can be solved by "using that same Emacs", i.e., running Emacs in se Note that `emacsclient` requires a filename, so my script prompts for one if `$1` is empty. -``` bash emc +``` bash #!/usr/bin/env bash if [[ -n $1 ]]; then file=$1 diff --git a/source/blog/2014-12-14-the-google-chrome-comic-a-classic.md b/source/blog/2014-12-14-the-google-chrome-comic-a-classic.md index b1fe01b5..7129f647 100644 --- a/source/blog/2014-12-14-the-google-chrome-comic-a-classic.md +++ b/source/blog/2014-12-14-the-google-chrome-comic-a-classic.md @@ -1,9 +1,7 @@ --- -layout: post title: "The Google Chrome Comic — A classic" date: 2014-12-14 17:42:55 -0800 -comments: true -categories: +date-display: December 14, 2014 --- I was cleaning up my Opera bookmarks just now — I'm semi-officially leaving Opera for Safari. Of course, Safari still can't handle everything (e.g., Adblock Plus is still not so good on Safari, YouTubeCenter lags behind and I don't bother to compile myself — yes, I have a certificate, and some power user features simply don't exist), so I'm still going to Opera/Opera beta/Chrome/Firefox for certain tasks. But Safari is very nice. For the first time. diff --git a/source/blog/2014-12-19-app-suggestion-dropzone-3.md b/source/blog/2014-12-19-app-suggestion-dropzone-3.md index 340828a5..5a31218e 100644 --- a/source/blog/2014-12-19-app-suggestion-dropzone-3.md +++ b/source/blog/2014-12-19-app-suggestion-dropzone-3.md @@ -1,9 +1,7 @@ --- -layout: post title: "App suggestion: Dropzone 3" date: 2014-12-19 14:08:57 -0800 -comments: true -categories: +date-display: December 19, 2014 --- I recently tried and purchased [Dropzone 3](https://aptonic.com/dropzone3/). See a list of features on the linked official website. In short, Dropzone 3 provides an intermediate zone for drag-n-drop. You can use it as a stash (called "Drop Bar" — stacking is available), use it as a shortcut by putting frequently used folders and applications there, or trigger actions by dropping. There are a dozen builtin actions and [an additional list of readily available actions](https://aptonic.com/dropzone3/actions/), covering common web drives, SNS and file sharing sites. **Better yet, you can develop your custom actions with the easy-to-use [Ruby API](https://github.com/aptonic/dropzone3-actions/blob/master/README.md#dzalerttitle-message).** For instance, I wrote a simple Google Translate action, `Google Translate.dzbundle` ([link](https://gist.github.com/zmwangx/b27f106a8ba47468a43d)), based on [translate-shell](https://github.com/soimort/translate-shell). (You know, it's Ruby, so calling external commands and concatenating strings feel at home, as if you are coding in Perl or directly in shell; unlike Python, where you at least need to `import subprocess` then `subprocess.check_output` to get the output of an external command, and have to use a bunch of stupid `+`'s to get your goddamn message to print.) diff --git a/source/blog/2014-12-22-10k-images-on-imgur.md b/source/blog/2014-12-22-10k-images-on-imgur.md index a9a96bde..5a4f6343 100644 --- a/source/blog/2014-12-22-10k-images-on-imgur.md +++ b/source/blog/2014-12-22-10k-images-on-imgur.md @@ -1,8 +1,6 @@ --- -layout: post title: "10k images on imgur" date: 2014-12-22 12:42:16 -0800 -comments: true -categories: +date-display: December 22, 2014 --- I happened to check my imgur account just now (haven't been to the web interface for ages), and you know what, I have uploaded 10,744 images since I created the account in February this year! (I've been using imgur for longer than that; previously I uploaded images anonymously.) Most of the 10k images were uploaded via scripts using the API. This again demonstrates the importance of a good API — without the imgur API I wouldn't have been able to upload hundreds of images with a few keystrokes all in a snap, and getting links would be a huge pain in the ass. There are myriad image hosting services out there, but imgur rules 'em all, thanks to its decent API (and also its good CDN and direct image links, of course). diff --git a/source/blog/2014-12-23-mpv-launcher.md b/source/blog/2014-12-23-mpv-launcher.md index 1bb85b50..fcc3f390 100644 --- a/source/blog/2014-12-23-mpv-launcher.md +++ b/source/blog/2014-12-23-mpv-launcher.md @@ -1,9 +1,7 @@ --- -layout: post title: "mpv launcher" date: 2014-12-23 00:51:05 -0800 -comments: true -categories: +date-display: December 23, 2014 --- **_04/06/2015 update:_** diff --git a/source/blog/2015-01-01-os-x-system-ruby-encoding-annoyance.md b/source/blog/2015-01-01-os-x-system-ruby-encoding-annoyance.md index 2bef694d..d27b0507 100644 --- a/source/blog/2015-01-01-os-x-system-ruby-encoding-annoyance.md +++ b/source/blog/2015-01-01-os-x-system-ruby-encoding-annoyance.md @@ -1,15 +1,13 @@ --- -layout: post title: "OS X system ruby encoding annoyance" date: 2015-01-01 22:49:39 -0800 -comments: true -categories: +date-display: January 1, 2015 --- I've been using RVM (with fairly up-to-date Rubies) and pry since my day one with Ruby (well, almost), so it actually surprises me today when I found out by chance how poorly the system Ruby behaves when it comes to encoding. The major annoyance with the current system Ruby (2.0.0p481) is that it can't convert `UTF8-MAC` to `UTF-8` (namely, NFD to NFC, as far as I can tell), at least not with Korean characters. Consider the following script: -```ruby utf8-mac.rb +```ruby # coding: utf-8 require 'hex_string' str = "에이핑크" diff --git a/source/blog/2015-01-10-fonts-why-chinese-web-design-is-hard.md b/source/blog/2015-01-10-fonts-why-chinese-web-design-is-hard.md index 7d6e5ee8..d8788913 100644 --- a/source/blog/2015-01-10-fonts-why-chinese-web-design-is-hard.md +++ b/source/blog/2015-01-10-fonts-why-chinese-web-design-is-hard.md @@ -1,9 +1,7 @@ --- -layout: post title: "Fonts: why Chinese web design is hard" date: 2015-01-10 09:30:02 -0800 -comments: true -categories: +date-display: January 10, 2015 --- For years I've been complaining about Chinese websites' horrendous designs. Yesterday I tried to translate one of my simple project websites to Chinese, and finally realized that web design for the Chinese language is no simple task — much harder than for English. The problem is fonts. This might not be the only problem (and cannot take blame for all the horrendous designs), but it certainly seems to be a roadblock. diff --git a/source/blog/2015-01-21-web-design-microsoft-vs-apple.md b/source/blog/2015-01-21-web-design-microsoft-vs-apple.md index 5f8cb833..7ffd6c1d 100644 --- a/source/blog/2015-01-21-web-design-microsoft-vs-apple.md +++ b/source/blog/2015-01-21-web-design-microsoft-vs-apple.md @@ -1,9 +1,7 @@ --- -layout: post title: "Web design: Microsoft vs Apple" date: 2015-01-21 16:30:51 -0800 -comments: true -categories: +date-display: January 21, 2015 --- I just had a look at Ars's live blog on today's Windows 10 Event to acquire a sense of where Windows is heading. There's not much to report. Safari rip-off (Microsoft's new Spartan — wait, is this name also inspired by Safari? — features reading mode and offline reading list, Safari's killer features) aside, the focus seems to be virtual assistant, PC-tablet-phone integration, and gaming, none of which I'm interested in. The hologram thing does look cool, but putting the hype aside, I doubt if it will be really useful for the masses (except probably in gaming, one of my most despised applications of computing). I'm not a visionary so maybe I'm underestimating this. diff --git a/source/blog/2015-02-10-monitor-progress-of-your-unix-pipes-with-pv.md b/source/blog/2015-02-10-monitor-progress-of-your-unix-pipes-with-pv.md index 2f58e884..5bee4641 100644 --- a/source/blog/2015-02-10-monitor-progress-of-your-unix-pipes-with-pv.md +++ b/source/blog/2015-02-10-monitor-progress-of-your-unix-pipes-with-pv.md @@ -1,9 +1,7 @@ --- -layout: post title: "Monitor progress of your Unix pipes with pv" date: 2015-02-10 02:18:30 -0800 -comments: true -categories: +date-display: February 10, 2015 --- Recently I found a very useful utility called `pv` (for "pipe viewer"). [Here](http://www.ivarch.com/programs/pv.shtml) is its home page, and it can be easily installed with `brew`. According to its man page, @@ -19,7 +17,7 @@ Why is it useful? Well, pretty obvious if you are in the right audience. For me, For the record, here's the current version of my ruby script that attaches the first seven digits of the SHA-1 digests of the given files to their filenames: -```ruby 7sha1 +```ruby #!/usr/bin/env ruby require 'fileutils' diff --git a/source/blog/2015-02-17-microsoft-is-getting-cool-but-not-its-website.md b/source/blog/2015-02-17-microsoft-is-getting-cool-but-not-its-website.md index 7342568d..fbd587de 100644 --- a/source/blog/2015-02-17-microsoft-is-getting-cool-but-not-its-website.md +++ b/source/blog/2015-02-17-microsoft-is-getting-cool-but-not-its-website.md @@ -1,9 +1,7 @@ --- -layout: post title: "Microsoft is getting cool (but not its website)" date: 2015-02-17 18:57:19 -0800 -comments: true -categories: +date-display: February 17, 2015 --- Microsoft is getting kind of cool. For instance, open sourcing .NET last year caused quite a buzz. Ars has a good piece about this: [Microsoft’s continuing efforts to be cool](http://arstechnica.com/information-technology/2015/02/microsofts-continuing-efforts-to-be-cool/). diff --git a/source/blog/2015-02-20-my-dock-and-updated-omnifocus.md b/source/blog/2015-02-20-my-dock-and-updated-omnifocus.md index 690b83e1..431bbfbc 100644 --- a/source/blog/2015-02-20-my-dock-and-updated-omnifocus.md +++ b/source/blog/2015-02-20-my-dock-and-updated-omnifocus.md @@ -1,9 +1,7 @@ --- -layout: post title: "My dock and updated OmniFocus" date: 2015-02-20 16:16:10 -0800 -comments: true -categories: +date-display: February 20, 2015 --- > Simplicity is the ultimate sophistication. diff --git a/source/blog/2015-02-21-all-is-not-lost.md b/source/blog/2015-02-21-all-is-not-lost.md index 75c1ede2..25aa8d42 100644 --- a/source/blog/2015-02-21-all-is-not-lost.md +++ b/source/blog/2015-02-21-all-is-not-lost.md @@ -1,9 +1,7 @@ --- -layout: post title: "All is not lost" date: 2015-02-21 17:12:32 -0800 -comments: true -categories: +date-display: February 21, 2015 --- Lubos Motl always attacks the Many-Worlds Interpretation as if it is on the same level as anti-scientific claims. He even went on to attack Hugh Everett (the guy who first formulated this interpretation) personally; *ad hominem* is of course typical Motl shit, and I don't bother to find those posts. Anyway, here's yet another one: [Many worlds: a Rozali-Carroll exchange](http://motls.blogspot.com/2015/02/many-worlds-rozali-carroll-exchange.html). diff --git a/source/blog/2015-02-24-the-new-onedrive-api.md b/source/blog/2015-02-24-the-new-onedrive-api.md index 28067c36..1ef5bc58 100644 --- a/source/blog/2015-02-24-the-new-onedrive-api.md +++ b/source/blog/2015-02-24-the-new-onedrive-api.md @@ -1,9 +1,7 @@ --- -layout: post title: "The new OneDrive API" date: 2015-02-24 18:31:19 -0800 -comments: true -categories: +date-display: February 24, 2015 --- Microsoft released the new OneDrive API today. See the blog post announcement [here](https://blog.onedrive.com/the-new-onedrive-api/). One highlight is that [large file upload](http://onedrive.github.io/items/upload_large_files.htm) is now officially supported. Previously, large file upload was handled with a semi-official API using the BITS protocol; the only documentation was a [gist](https://gist.github.com/rgregg/37ba8929768a62131e85). Now it is handled through standard HTTP `POST`. With this major release, there's likely a lot of work to be done with [python-onedrive](https://github.com/mk-fg/python-onedrive). I have opened an issue: `mk-fg/python-onedrive#52` — [New OneDrive API support](https://github.com/mk-fg/python-onedrive/issues/52). diff --git a/source/blog/2015-03-22-back-up-os-x-app-icons.md b/source/blog/2015-03-22-back-up-os-x-app-icons.md index 7f9eec4b..53c73b06 100644 --- a/source/blog/2015-03-22-back-up-os-x-app-icons.md +++ b/source/blog/2015-03-22-back-up-os-x-app-icons.md @@ -1,15 +1,13 @@ --- -layout: post title: "Back up OS X app icons" date: 2015-03-22 16:58:50 -0700 -comments: true -categories: +date-display: March 22, 2015 --- OS X application icons are valuable assets, and it's interesting to see how they evolve over time. This is especially the case when we upgraded to OS X 10.10 Yosemite, when Apple and many design-aware third party developers overhauled (mainly flattened) their icons. However, we lose all the old icons when we do a major OS upgrade. Technically they still live in Time Machine backups, but those are a pain to pull out. Therefore, I wrote a script just now to back up app icons of all applications living in `/Applications` (including those symlinked to `/Applications`, e.g., apps installed through `brew cask`) and its level-one subdirectories, and `/System/Library/CoreServices` (for `Finder.app` and such). Here's the script: -```bash backup-app-icons +```bash #!/usr/bin/env bash function app_version { diff --git a/source/blog/2015-04-26-using-python-3-with-emacs-jedi.md b/source/blog/2015-04-26-using-python-3-with-emacs-jedi.md index 5a6f12ea..e65f92a2 100644 --- a/source/blog/2015-04-26-using-python-3-with-emacs-jedi.md +++ b/source/blog/2015-04-26-using-python-3-with-emacs-jedi.md @@ -1,9 +1,7 @@ --- -layout: post title: "Using Python 3 with Emacs Jedi" date: 2015-04-26 21:19:14 -0700 -comments: true -categories: +date-display: April 26, 2015 --- Recently I'm working on [a hobby project in Python](https://github.com/zmwangx/storyboard), which means editing Python source files a lot. I've been using [Emacs Jedi](https://github.com/tkf/emacs-jedi) for almost as long as I've been writing Python, and it has been pretty helpful at completing away long names. diff --git a/source/blog/2015-05-03-why-oh-my-zsh-is-completely-broken.md b/source/blog/2015-05-03-why-oh-my-zsh-is-completely-broken.md index 3d682897..eb576efc 100644 --- a/source/blog/2015-05-03-why-oh-my-zsh-is-completely-broken.md +++ b/source/blog/2015-05-03-why-oh-my-zsh-is-completely-broken.md @@ -1,9 +1,7 @@ --- -layout: post title: "Why Oh My Zsh is completely broken" date: 2015-05-03 17:15:49 -0700 -comments: true -categories: +date-display: May 3, 2015 --- Today I moved from [Oh My Zsh](https://github.com/robbyrussell/oh-my-zsh) from [Prezto](https://github.com/sorin-ionescu/prezto), after using Oh My Zsh for about three years since 2012. I'll try to shed some light on the reasons in this post. @@ -25,7 +23,7 @@ Wait, why do I see `bzr.zsh`, `git.zsh`, and even `nvm.zsh` in the core lib? The Meanwhile, Prezto does it right. Prezto is highly modular, with the `pmodload` function defined in [`init.zsh`](https://github.com/sorin-ionescu/prezto/blob/08676a273eba1781ddcb63c4f89cfff9bd62eac4/init.zsh) to load modules. That's about the entirety of Prezto's core; everything else are in optional [modules](https://github.com/sorin-ionescu/prezto/blob/08676a273eba1781ddcb63c4f89cfff9bd62eac4/modules), including essential configs like `editor` (ZLE configs), `completion`, and `prompt`. Note that module loading order matters in some cases, but still, working with Prezto's modular structure is a joy. Apart from `init.zsh` and `modules/`, Prezto repo does contain a [`runcoms`](https://github.com/sorin-ionescu/prezto/tree/08676a273eba1781ddcb63c4f89cfff9bd62eac4/runcoms) directory with the rc files, but those are just recommendations that one may disregard. In fact, there are a total of eight lines related to Prezto in my `.zshrc`, and nowhere else (note that I only switched to Prezto today, so this freshly baked `.zshrc` is subject to change): -```sh Excerpt of .zshrc +```sh # prezto zstyle ':prezto:*:*' color 'yes' zstyle ':prezto:environment:termcap' color 'no' # disable coloring of less, which is insanely ugly |