Website Logo. Upload to /source/logo.png ; disable in /source/_includes/logo.html

Dimitris Tsironis

Writing about world and technical stuff

Lockr v0.5.0 Released

Few months ago, I have written a prototype of a library to use localStorage more efficiently. In the meantime, I totally forgot about it until I started writing the v2.0.0 of the BugSense JavaScript SDK.

So I started development for bugsense.js and I run into the same issues using the native localStorage API. I needed something modular, lightweight and with a very small bytesize.

And then it came to me. I had already written most of the library, although it needed some work to be combat-ready.

Eventually, I designed the API wrapper very much influenced by the node_redis client. I wrote some specs for it, make sure everything is working as it should and here it is.

It’s a very early version, but I do want to keep it that simple in the future, maybe with some extra features.

I would love your feedback to make it more awesome and to have more stuff in v1.0.0. Give it some love or fork it to make it better!

Enjoyable Javascript

The first handshake

When I started learning the building elements of the Web, I had the impression that Javascript is that hefty, untamable beast that nobody really understands, a language so wicked that noone really wants to write it anyway, although it’s inevitable.

Let’s get this out of the way. Javascript is not an inherently bad language. Its notoriety originates mainly on some crappy browser and DOM APIs, bad implementations of specs and the general ambiguity that reigns in the Browser Vendors Land. Yes, it is a stil very immature language but that doesn’t mean it’s not powerful enough.

Getting more intimate

For people that aren’t very familiar with it, writing Javascript is just a matter of registering some jQuery events which control animations. Writing webapps in Javascript puts you in a completely different state in which you need to write modular, maintanable and testable code. You have to organize your code efficiently in order to avoid having a “spaghetti code” codebase.

When I joined BugSense, I immediately started to put all of the above principles in practice. Backbone.js isn’t opinionated enough to force me to structure or code in some particular pattern, so I was starting anew. Coming from a more opinionated background, in which I had a basic code structure already layed out, I was kinda freaked out.

It turns out that taking key decisions about my project on my own is one of the best things that I learned while writing Javascript.

Javascript is flexible

One of the wow moments I had with Javascript, was the ability to easily do evaluations, one-liners (almost LISPy things) without having to bleed through my ears. Events, closures, functional js, being able to do this…

X ? doSomething() : doSomethingElse()

…made me fall in love with it after a while.

Building a decent workflow

I think this point is true for every language. You should try moving things out of your way, optimizing your everyday work, organizing your project’s structure as well as possible and having repetitive tasks done automatically. It should be just you and the language, nothing more. Especially for Javascript you should try having multiple files and concatenating or minifying them with Grunt.

Getting serious

If you’re in a state that you want to take it to the next level, then I think you should try strict mode. Just put use 'strict'; at the top of your js files. This have will help you write more consistent code across implementations and other things.

Most importantly, don’t hate Javascript, but instead you can try to get the most out of it. All languages and tools have their limitations after all.

The question is could you rise to the occassion?

Join the discussion on Hacker News!

Is Kindle Paperwhite Really Worth It?

I’ve been using Kindles for almost two years. My first Kindle was a 4th generation Kindle (not the touch one). Since then, ebooks for me was just a thing from a science fiction articles, just like flying cars. It was technically plausible but couldn’t see it replacing paper books anytime soon. News flash, I was wrong. So when the new Kindle Paperwhite came out a few months ago, I decided to upgrade my Kindle to a new Kindle Paperwhite. I did long the touchscreen which makes everything so much easier and I ordered it from Amazon.

First things first

It’s been two months since it arrived. It is always surprising to see how minimal the packaging that Amazon chose for Kindle is. One thing that I noticed is that they didn’t include a USB adapter, just the cable. I wasn’t bummed because I never really used the USB adapter with my old Kindle. I boot it for the first time, logged in with my Amazon account and boom, everything was there.

Screen got a lot better

I contemplated that the great success of Kindle was the lack of illuminated screen. The look and feel of physical paper of my old Kindle was quite useful for well lit rooms, but it still had some glowing issues, especially when you read books on your bed with a single source of light. Kindle Paperwhite has a very dimable front-lit screen which is actually is perfect for every situation. You can read in a dark room without having your eyes being tortured, you can read on sunlight or in metro without any difficulty at all.

Screen resolution have increaded as well. With the previous Kindle I found myself prefering a larger font because resolution it wasn’t that great. The Paperwhite is a huge improvement. Make no mistake though. It’s not totally perfect but it doesn’t get in your way which is good.

Better hardware & software

It’s time for some geekiness! A faster processor which actually means it can render better images and you read comics better now. Also, it has an updated software which is nice, books appear with thumbnails if you want to and it offers a better Kindle Store experience as well.

Another feature that I use really often is “Send to Kindle”. There are some plugins for Firefox and Chrome that can format an web article in a small ebook and ship it over to your Kindle. It’s almost a one-click process and then the article gets synced in your Kindle.


There is only one way to describe the battery life of Kindles. It is simple one of the most power efficient devices ever built. A nice change from modern electronic devices for sure. I charged it only once since I got it (no joke) and I have still more than 60% battery in my charge (I’m using it every day since I got it). It is the kind of device that you’re taking with half-charged battery over a long trip and you don’t really notice. It’s the device you should take on an enlighting 2-month trip to India without worrying about your battery life. It’s the opposite of modern smartphones.

Reading programming books

As a result of increasing resolution, font rendering got a lot better. Reading programming books is very fluent although I still prefer having a printed book for this kind of subjects. It’s easier to go back and forth, take notes etc. So yeah, although Kindle ebooks for programming are totally readable, it’s not my favorite way of reading programming books. But some the Kindle editions of these books are a lot cheaper (also you don’t pay the shipping fees).


The best thing about Paperwhite is that it made me read a whole lot more. I read every day while commuting to work or relaxing at home. I throw it in my backpack and I’m ready to go and I don’t need to worry about recharging or updating content that often. Hell! I use it more than my smartphone in an everyday basis.

Kindle is invaluable for me. It is the perfecy bond of technology and literature, the easiest way to read a book, it has a great battery life and doesn’t get in your way. You can buy a book wherever you are and start reading it few moments later. I don’t think it gets better than that.

It really is the best device money can by. Period.

Join the discussion on HackerNews

Edit: HN discussion that the Paperwhite is indeed a front-lit screen, not a back-lit one. Corrections were made.


In the quest for the perfect conf

In my previous post, I wrote about my experience switching to Vim. After getting familiar with using Vim, I started to search on ways to improve my workflow. At the time, I was using Janus build and I have to say, I didn’t enjoy it too much. So I had two choices; the first was to start off and build my own Vim configuration from the ground up and the second was to find a “pret-a-porter” solution. I chose the latter and head to Github to start the quest of finding the perfect Vim configuration. I had already excluded Janus because way too complicated to mess around with and it’s pretty heavy as well. Then, I remembered about Subvim which is a great effort to emulate Sublime Text 2 in a Vim environment. That didn’t suit me as well, found it to be heavy and just not my taste.

The Holy Grail

And then I remembered about maximum awesome, made with love by Square and decided to install it right away to test it out. And boy, it is good! First of all, the installation process is simple, painless and quick. I fired up my MacVim and tried it out. My first impression was that it felt agile, looked beautiful but lacked some functionality that I’ve been used from my previous configurations.

Almost right away, I decided to fork it and made my changes available for all and also, have them backed up in Github (just in case).

A minimal Vim configuration

And that’s how (maximum-awesome)2 was born, humbly named after his great ancestor!

Right away, I had some issues with the status line, so initially I went with Powerline and minibufexplorer, but after a while I switched to the vim-airline which does both things (and which I love). Also, around that time I started using Jellybeans colorscheme. Made some other changes in the vimrc and I was pretty happy with my setup.

Maximum Awesome Squared animation

Ubuntu support?

Ok, maximum awesome is built for Mac OS X, but I didn’t see any valid reasons why it couldn’t play on Ubuntu as well. And also, I really, really needed my config in my Ubuntu desktop as well. So, I made the decision to hack the original Rakefile in order to made it work nicely with Ubuntu. Although I’m not that happy with the quality of the new version, I made it work. Maybe some time in the future I’ll do some optimisation.

Customize it!

The great advantage with the maximum-awesome is that you can easily hack it, change it, make it unique. I was familiar with the code in about thirty minutes or so. If you want to change the plugins, just edit the .gitmodules file and run rake. Make your personal changes (changes that will only be interesting to you, that is) in the vimrc.local file. The script will download the new plugins and everything else should be taken care of by Pathogen.

Future plans

Full Ubuntu/Debian support

There are some things that are very sloppy about the rakefile, I plan on making some optimizations and also, finding a way to offer greater support for Ubuntu/Debian systems but also, other Linux distros as well.

Better installation experience in both platforms

Currently, the implementation of the installation plugin is not that elegant and I want to encourage the customization and make it as easy and seamless as possible.

Better handling of Git submodules (plugins)

The downloaded plugins in the vim/bundle folder shouldn’t be added in the repo, instead they should be just local copies and everything should be handled through the .gitmodules file. I plan on improving that.

Improve Vim performance

Sometimes, MacVim and Vim feels heavy, especially after some hours of usage. I plan on making make it faster and less heavyweight (or at least, investigate why)


(maximum-awesome)2 is just my take on the original project. If you like it, fork it and let’s make it better!

Join the discussion on HackerNews

Vim: From N00b to Meh

I grew up in a fairly technical family; my parents have both programming background. Heck! my mother programs in vi until this day and I was always aware of this obscure thing, called Vim. But three years ago, when I decided it was time to move from the (then popular) Notepad++, I came across Sublime Text 2. At the time, it was still in beta version, but it was apparent to me that it was a completely different experience than the old Notepad++. The vast choice of plugins, the dark theme, the performance of the whole application was a no-brainer for me. I fell in love with it at first sight, I adopted it as my default editor and it served me well for almost three years across Windows, Linux & Mac.

A few months ago, I joined BugSense as a front-end engineer. Most guys at BugSense use Sublime Text, so I was right at home. But there is a guy (@alexkompotis) who is using MacVim. I was immediately intrigued by it and quite interested to see his workflow. The main question that came in my mind, it was how the heck did he manage to work everyday in that obscure, mystical and old fashioned editor. Sublime Text 2 is, I thought at the time, far more superior in terms of usability.

It was then that I decided to give it a try. Of course, I had already open vim in my terminal but avoided it in a regular basis. This time I was really psyched about it; I borrowed @alexkompotis’s custom configuration and fired up my engines. But, I failed big time. The truth is that at this point I had a very beefed up Sublime Text configuration. I rushed my workflow change and I wasn’t patient enough to laern Vim.

The Vim philoshopy

Then I came across this awesome game, Vim Adventures that sets to teach you the Vim philosophy while having fun. It was a good experience but I did get bored after some days. I learned so much about Vim while playing and I was already “getting” the Vim way of thinking. After that, I read the classic book Practical Vim, which expanded my knowledge at how Vim is working. It turned out that all this time, I was forcing myself in the opposite direction than Vim dictates; Vim’s normal mode is in fact a command mode (duh!) and the insert mode is, well, for inserting text. The self-evidence of the previous statement is actually the whole point of Vim philosophy.

Take it easy, continue your work, learn in the process

Then one day, I decided to make the switch to Vim. I have tried for a week or so the command mode of Sublime Text and I found it very limiting and unusable in general. I chose the Janus build to get started with and read this very helpful article which in a nutshell says “take it easy and you’ll get there”. Start with soft settings, enable mouse, enable arrow navigation and try a configuration that doesn’t alienate you. Then gradually, learn new tricks and adopt your workflow over time.

Finally, I made it! It’s been more than two months now and I never looked back. I haven’t opened Sublime Text since the first week of my switch and I’m getting progressively better. Now, I’m using an opinionated version of Square’s maximum-awesome project that I called it maximum-awesome-squared for obvious reasons :)

But more of that in my next post.

Join the discussion on HackerNews

Mercurial's Perfect Setup [Part. I]

I’ve been using Mercurial every day, since I joined BugSense a few months ago. At the time, I was an advanced Git user and it took me a while to understand what exactly is Mercurial’s philosophy and adapt my workflow to the new system.

So, I spent a good amount of time to finetune my configuration and find the perfect setup for my Mercurial workflow. I use a handful of already built-in (but not enabled by default) extensions, some external extensions and some custom aliases to facilitate some more complex tasks.

As of this writing, the hg --version is 2.6. If you haven’t update it yet, please do since some the following extensions are available only in newer versions of Mercurial.


I think the feature of git that I really missed is rebase. Mercurial’s rebase is not as hardcore as Git’s rebase but it does the work done. You can enable it in your ~/.hgrc file.

rebase =

I mainly use rebase for fetching commits from the upstream repository (Bitbucket, self-hosted hg, you name it). This is a very basic usage of rebase extension and it actually does have a lot more built-in functions but I don’t really need them in my current workflow.

$ hg pull --rebase

This is very useful in my case because it solves Mercurial’s serious flaw (in my opinion) with continuous merges, that litter repo’s history with useless merge commits.


This is an awesome extension by Steve Losh, that allows you to display all the useful info about the Mercurial current repo in your terminal.

Steve has an excellent documentation about installing and getting started with this extension but also, has written a blog about his zsh setup, including several details about hg-prompt .


Graphlog is a built-in extension for Mercurial, which is the equivalent of git log --graph and it formats the output as a graph representing the revision history using ASCII characters to the left of the log, quoting extension’s description.

In order to use it just enable it in your ~/.hgrc config file and your good to go.

graphlog =

You can use it by typing the following in your terminal:

$ hg log -G
# or
$ hg glog

Personally, I use it via an alias, just a shorthand to make it more accessible, nothing fancy at all. It still accepts all the options of glog.

lg = glog

hg blame

One other Git command that Mercurial really needs is the git blame. This one isn’t exactly what you might think, it’s just for finding in which commit or changeset a line was added or last modified. It’s pretty handy as the time goes by and chances are you have forgotten what you have written a few months ago.

So the solution I found on Stack Overflow was using the annotate command with a few arguments. I took this and after I added my preferred arguments I create an alias in order to create hg blame.

Here is the code for this alias:

blame = annotate --user -c

Now, you can just type the following and you will be greeted with a nice output showing user and changeset number next to each line.

$ hg blame <path-to-file>

Combine that with grep or ack and you have a power tool in your hands!

$ hg blame <path-to-file> | grep "some words"


Very nice and handy plugin to add less-like functionality for commands that have huge outputs, eg. log, diff etc.

It’s easy to setup and already included with Mercurial.

pager = LESS='FSRX' less
attend = cat, diff, glog, log, incoming, outgoing, lg, show, lg

The end

I will come back with a second part, covering the rest of the plugins I’m using.

Head over to Hacker News for the discussion

Why Open-source Really Matters?

This is one of these endless battles in the history of humanity. Open-source vs. proprietary software; is one of the most vibrant disputes of all time. I tell you, it’s not an easy one and being a part of tech community, you feel obligated to choose a side from early on, as everyone is taking a stand on this subject (though it’s not required after all).

Love at first sight

I was always fascinated by the fact that you can find so many free things on Internet and that you can legally use and build upon. My first introduction to Linux was love at first sight and it’s been a while since then. I had a crappy desktop for six years that almost from the first day, didn’t bend to my will and I spent most of time trying to make Windows XP work as they supposed to. One day, I had enough with it and I installed Ubuntu 7.04 from a magazine CD, in order to test Linux.

I still remember that feeling that I can bypass everything proprietary and I actually don’t have to pay to make my computer work. I was using something cool that a common person, like me and you, have built in his free time. And it was really that faster than Windows. And that’s because, open-source software is the lovechild of developers - for most of us, it’s our hobby and you can tell from the quality of most open-source projects. Open-source is powered by love.

Discovering a new world

Until that moment, I though that software was a black-box that I would never able to learn, build or mess around with. It was destined only for highly-skilled human beings. Yes, I was playing games, using programs and Windows operating system itself, but I hand’t figure out what’s going on underneath it, it was like a cool magic trick. The command line was just a historical evidence of how the computers used to look like in the past.

Years later and probably because I messed around with Linux for a few years, I got better with computers. It started being my thing. I was tearing apart hardware for fun and learning some simple HTML and I wouldn’t never get better into it, if it wasn’t for open-source.

You see, the good thing with web technologies is that you have an extremely big amount for examples and implementations to copy and learn from. Just go to your favourite webpage and view the source. It’s there waiting for you to copy it, modify it, learn by its mistakes.

The web is completely open-source, you can literally see everything on a page.

Then, a couple years ago, I discover Github and weirdly enough, later I started using git. Initially, I was thinking Github was just a cool site with projects, but, oh! I tell you. It’s more than that. People don’t always understand why Github is so popular and useful for the tech community. And yes, I would say that Github could be useful, not only for programmers, but non-technical people as well.

For me, it’s the perfect collaboration tool. You can mess with code, make changes and send it to project’s owner for him to decide if he wants to make your chances a part of his project. But you have total freedom to do so and as a matter of fact you’re encouraged to.

Also, knowing that you’re code is public and everyone could take a look at it, forces you to become better and refine your work. Even more, it lets other people find your mistakes, propose improvements, solve bugs and help you make your software better.

But it’s not all about developing great software. Everyone needs to understand that open-source is the stepping stone of modern technology; Nasa, IBM, Apple, RedHat, Google, Facebook, Github, universities are using open-software or earn their living for open-source. Even Microsoft does! It’s one of the biggest markets out there. I know it’s counterintuitive to say that can actually earn more by giving away free stuff, but it’s kind of true.

So, next time you’re searching on Google for a nice restaurant, commenting on photo on Facebook, checking you phone for email, even driving your car, just think that you’re using Linux or some other form of open-source software.

Yeap. It’s that important.

Making Engaging Presentations

A brief intro

Many of my friends, being developers like me, have trouble when it comes down to design some basic stuff and that’s completely normal. Developers, although they create beautiful & elegant stuff, they don’t particularly like drawing lines and colours to compose something.

I’m one of those people that lies somewhere between; I have an excellent grasp of design, as well as a strong technical background. I like the idea of expressing my thoughts and put other people in a certain mood through design. And it’s essential, especially in our days, that the common user is used to high design standards.

So, there will be some time in everybody’s life that you’ll have to confront this untameable beast called PowerPoint or Keynote or whatever. But, mainly, as most things in the football we call Earth, is not about the tool you use, but how you use it. So, I thought it would be helpful if I shared some thoughts on this one.

1. Decide the theme of your presentation

Every presentation have a theme and your design should follow the theme closely without being on top of it. Content is the king, as they say. And your design should be in context. Imagine if you’re doing a technical presentation and you’re using a children’s party preset from PowerPoint. Hideous choice indeed!

2. Typefaces matter

It’s easier than ever to find a good quality typeface online. You should search something that will be in harmony with the theme of your presentation. For example, if you’re presenting about a cutting-edge technology, you don’t want to use neither a serif font nor a curly/hipster font. You should probably go with a modern, yet serious sans-serif font.

3. Colours is the single most important thing of design

Colours say more for you and your story than you would imagine. You should carefully use a colour palette, from sites like Colour Lovers, Dribbble etc. Just a tip here: not all palettes work well for a presentation. Firstly, some palettes have too much contrast you’ll end up tiring your viewers' eyes. Also, chances are that you’re going to present in a shitty projector that doesn’t care about what colour profiles you have in your computer. And as Yoda says:

“Wise with your colours choices, you should be. Herh, herh, herh”.

I mean, he’s Yoda! He should know better than any of us!

4. Use HUGE font sizes

You don’t want to start presenting and all you hear from your audience is “we can’t see your slides, maaaan. You’re lame!! Booh!”. Audiences tend to be harsh with presenters and for that, you have to facilitate things for them as much as possible. So you should multiply your normal font size times three. For example, normal text size should be around 30 points, and title 60 or 90 points. But I personally use different font sizes in each presentation, as the design changes. You can also use font sizes to emphasise some text you want to be “boom! in their faces”.

5. Find beautiful images on Flickr

Another nice trick you can do is to use wonderful images that describe or have something to do with your content. Flickr is full of great looking photographs and some of that are under Creative Commons license which means you can use it, well, almost for anything, depending what the author indicates.

6. 100-words paragraphs are no good!

Last but least, I beg you! Don’t put your entire talk in your slides. It is maybe the most common mistake I see in people’s presentations. They most likely write what they have to tell in their presentation and then, they just read it out loud to their audience. It’s boring and you’ll end up awkward as hell, reading your own words. Instead, you should use small, comprehensive titles with a small, more analytical subtitle. And that’s about it. Also, unordered lists are a great way to summarise your slide content and also, have a flow to use while you’re presenting.

So, how can you get started? You should definitely check out the following links

  1. Zach Holman’s presentations
  2. You suck at PowerPoint
  3. Check other presentations
  4. Colour Lovers
  5. Dribbble

The Modern Education Paradigm

Education on the 21th century

I’ve been always been an keen observer of human behaviour and while being a member of the academic community, is kind of inevitable not to identify some interesting facts about our educational system and how that’s being formed about our own behaviours.

First, I came to the following conclusion when I was in the second year of my studies and all I was hearing from freshmen students was how the professors didn’t pay attention to them exclusively or care if they were clear enough for the students. Actually, what the freshmen wanted, was to get consumed knowledge without hassling to actually learn it. Somewhat like the fast-food drive-ins. Looking back to that attitude, it certainly reminds me how school works: the teacher has to teach you some stuff and consequentially, you have to absorb as much as you can, without having the option or a state of mind to question that information.

An education system specifically designed many, many years ago is merely competent today

And as Sir Ken Robinson correctly claims, that happened because this is a educational system designed specifically for the needs of Industrial Revolution. Most of the info we get today from schools and universities is seriously outdated and perhaps, flawed. Now, this educational system is quite resistive and narrow-minded. It has all kinds of mechanisms to ensure that the content of courses will be in the standards of the government - and that’s about it. You can’t go further than that.

An outdated education

The above educational system is based on the premise that your success in life depends directly with a graduate or master’s degree. Thus, you have to obey to their guidelines. This doesn’t fit me personally, I can’t be easily be constrained, at least not without a cause that actually makes sense.

On the other hand, even since I got to know the web, I found a great pleasure learning new things, not by reading old textbooks, but by cross-checking as many references I could possibly find. You can actually develop a theory of mind on your own, by reading and researching hundreds of sources. You don’t have to be constrained to a single textbook anymore.

Be your own teacher

But unfortunately, that’s something is not taught in school. Every now and then, some friend asks me about something and I pretty much enjoy sending him/her a link from Let me Google that for you. It’s hilarious! But seriously, Google can find you every piece of information with a few keystrokes; isn’t that amazing? Instead of using only your own mind, you can use other’s thoughts and outcomes to enrich your own knowledge.

If your plan is to be a tech person, you’re in more luck than everybody else. The web is always full of tech articles, tutorials and also, some fun ways on learning new things.

The future is here

The past few years, websites like Codecademy, CodeSchool, Coursera, Udacity have made the learning process so accessible that you can go to class drinking cocoa from your favourite mug in your pyjamas while relaxing in your bed listening your favourite jazz album.

When I was starting to mess around with the web, almost 5 years ago, all that were only in science fictions articles. I had to learn the hard way, which eventually wasn’t so bad, but it sure wasn’t the most efficient way. Now they’re here, you can create a free account and start hacking on stuff.

Bottom line, while a degree is still irreplaceable for everyone’s future, you can now get your life in your hands and actually do something. Learn new stuff, explore on your own and don’t wait to learn mechanically. I’m looking forward to see what the future educational systems will look like. Hope they will rock this world.

Hardcore Forking Action

Sexism, tech conferences & Twitter hatred

Few days ago, a bad situation happened at PyCon. Reportedly, some developers were making some forking jokes and Adria Richards, a (ex) Sendgrid-employed developer evangelist was offended by these jokes. She talked about feminism and stuff like that.

First of all, I don’t understand how that sexual joke is specifically addressed in women. Last time I checked, sexual intercourse didn’t require exclusively women to be a thing. So, I guess this may be as insulting for a guy as it is for a girl. In my point of view, that’s the whole point of feminism. We’re equal. Otherwise, it’s just favouritism.

Ok, I get it. Tech industry is dominated by males. But that doesn’t mean that we are more sexist than males in other industries. Personally, I have no problem accepting that a woman can kick my ass in any of my skills. And I know for sure that many women actually exactly that.

But the main point I want to make is that it’s just a mother-flipping joke. There’s something more important than the urge to politically correct every single conference, TV show, work environment etc. It’s called humour and knowing when to chillax and just enjoy yourself.

Hardcore Forking action

And as a matter of facts, the “fork you” joke is pretty common. Github made a bold move and implemented it in the user interface, when you’re forking a repo.

Why do we tend to overcomplicate things?