A few quick command-line tips and tricks

I’ll probably be updating this blog a bit less the coming week as I’m about to leave for a short trip to belgium, where I grew up.

Of course I’ll be visiting my parents and a few friends, but this Wednesday I’ll also have the pleasure to see the one and only Richard Stallman deliver a lecture about the free software philosophy in Gent. This will be my first time seeing RMS in person and I’m quite excited!

I wasn’t so sure what to put here for a quick post before I go, but I thought I’d just share a few quick tips and tricks for users and lovers of the command-line! For most of you, this will be old news, but I’m sure there are lots of people out there for whom any of these quick tips would be a revelation and/or a huge productivity boost. It’s unlikely that I will reach those guys and gals through this modest blog of mine, but let me give it a try anyhow!

I’ll probably do more of these posts later, this is just a small taste of what’s to come! Read on for the first tips!

Read More

Linting code with Neovim and Neomake - ESLint edition


Ten days ago, I wrote about how I set up the Neomake plugin for Neovim and how I linted my JavaScript code using the JSCS linter.

While that worked alright for me, I kept running into weird bugs where JSCS would tell me there was a problem with my code, but the error message would simply display as “undefined”. I didn’t have the time to figure out what exactly was wrong, so I ended up switching to ESLint instead and it’s been smooth sailing ever since. I’ll explain how to set it up in this post.

Read More

hexo-easy-edit 1.2.0 : pages, cleanup & rename

So I pushed another minor version (quickly followed by a patch) to my little hexo-easy-edit plugin.

npm install --save hexo-easy-edit to install it.

npm update hexo-easy-edit to update if you already had a previous version installed.

I’ve noticed people are actually starting to use it, so in the off-chance people will visit this blog to see what changed, here’s what’s new:

Read More

Simple promise example

I generally know what promises are about and have found them to be very convenient on multiple occasions (at least, more so than traditional callbacks). However, for me and undoubtedly for many others, the true nature of the promise still kind of eludes me.

I’m pretty busy nowadays working my way through You Don’t Know JS, building a landing page for this site and hacking on a bunch of other small projects. But I really wanted to get a more theoretical understanding of them now rather than later, rather than just slightly modifying existing code and hoping I understood it somewhat correctly.

So I did what probably every budding and experienced developer does in this kind of situation: I read the MDN article on promises.

Read More

hexo-easy-edit 1.1.0: colors, drafts and dates

I just pushed an update to my hexo plugin. Changes:

  • Menu output now displays the title instead of the slug. Extra information like published status, date and folder has been added as well for convenience.
  • Output is now color coded.
  • Support added for filtering on before-date (-b, --before), after-date (-a, --after) and published status (-d, --draft).
  • Internals have been promisified for much easier reading :-)
  • Various little tweaks to make command line editing of your hexo blog posts more convenient.
hexo-easy-edit 1.1.0 screenshot

Still on my todo-list for this project:

  • Turn simple title regexing into fuzzy search.
  • Add a remove command.
  • Improve the publish command.