September 15, 2018
Tags: book, review

Recently I have read a wonderful The Slight Edge: Turning Simple Disciplines into Massive Success and Happiness by Jeff Olson. (I thank drets very much for this suggestion.)

I like this book so much that I recommend it to everyone. (I even did “sell” it to my friends five times in a single day.) I see it as a pre-requisite reading for all other self-improvement books and here is why.

Continue reading...

November 30, 2015
Tags: bkernel, rust, osdev

TL;DR I’m writing an operating system in Rust and here is my status and impressions after a month of development.

I’ve been developing embedded operating systems for living for a couple of years now. And… I got tired of work, all the bureaucracy, hard to debug issues, a zillion of low-level details; I wasn’t even sure I want to continue work in the field, so I started a side project. It may come as a surprise I started yet another operating system when the same thing led me to this. Well, it’s not same; I’m building a new operating system to experiment, and this refuels me with the passion to the field.

Here are my progress and some impressions of Rust after a month of development (the code is here).

Continue reading...

September 5, 2015
Tags: haskell, strings

The goal of this blog post is to ease the confusion of Haskell string types. I assume you already know what String is, so I’ll only cover the difference between string types and help to build intuition on what type you should choose for the task in hand.

Continue reading...

August 2, 2015
Tags: haskell

In this post, I’ll try to give some intuition behind IO in Haskell for people who know what command pattern is, without explaining what M-word or do-notation is.

Continue reading...

March 26, 2015
Tags: git

At work, we use a rebase-based git workflow to keep master history plain along with gerrit to track multiple versions of the same commit and code review. This implies doing a lot of commit juggling including fetching individual commits from gerrit, checking out back and forth, rebasing and cherry-picking. I found myself in the detached HEAD state pretty often. I used to create a new branch or force update old one and checkout on it. Then I gradually started to do a part of work in detached HEAD and then realized these branches only hinder me in most cases; so now before beginning work on a new feature I’m not creating a new branch but rather checking out straight into detached HEAD.

I know this may be a unidiomatic git, but that’s how things work for me. Even though I work with detached HEAD, most commands here are equally useful with branches. You can also adopt working in detached HEAD with you current workflow (e.g. work in detached HEAD only for small tasks).

Continue reading...

December 31, 2014
Tags: haskell

I’ve signed for the Haskell-cafe mailing list to learn something new a day ago. The first letter I received was asking which defaulting proposals are actively pursued. I’d knew nothing about defaulting and why it should be improved, so that’s what I learned today.

Continue reading...

October 28, 2014
Tags: Java, obfuscation, ProGuard

ProGuard is a free tool for shrinking, optimizing and obfuscating jar files. I’ve used it at work to protect a commercial application from decompilation, especially critical algorithms. (Unlike machine code, Java bytecode is easy to decompile.)

Here I’ll try to describe how I did that.

Continue reading...

October 26, 2014
Tags: make

Make is a simple and powerful tool for automatically building any files out of others. However, some programmers experience issues writing makefiles and reinvent things without knowing some basic Make things.

Continue reading...

May 6, 2014
Tags: cron, popup, tips

A long time ago, I had read a book The Pragmatic Programmer: From Journeyman to Master (if someone didn’t read it yet, I highly recommend it). This book is a collection of extremely useful tips for programmers. But this post is not about the book.

Recently I decided to revisit these tips again; and found that I don’t remember some of them. So that, I decided to create something that will regularly remind me of them. The best choice was on-screen popups showing one tip at a time.

Continue reading...

April 22, 2014
Tags: pattern

During the study of the Boost library, I’ve stumbled on Proactor pattern. This is a design pattern intended to handle I/O operations asynchronously, but let’s describe other alternatives first.

Massive web servers should serve a lot of active connections in a short period of time; so, it’s important to do this most effectively with a less overhead.

Several well-known methods exist:

  • Synchronous
  • Synchronous Multi-threading
  • Asynchronous

Let’s describe them in order.

Continue reading...

April 21, 2014
Tags: awesome, fix, skype

By default, Skype behaves strangely under awesome wm. For example, view profile window is so small that even name isn’t displayed.

Continue reading...

April 7, 2014
Tags: autocomplete, clang, UltiSnips, Vim, YouCompleteMe

I’ve used the clang_complete plugin to autocomplete my C code for five months… until YouCompleteMe caught my eye. And now I feel that would stay with it indefinitely.

Quick overview

YouCompleteMe (YCM) is a fast, as-you-type code completion engine for Vim. It combines and prioritizes the output from several sources:

  • An identifier-based engine that works with every programming language;
  • A semantic, Clang-based engine that provides native semantic code completion for C/C++/Objective-C/Objective-C++ (from now on referred to as “the C-family languages”);
  • A Jedi-based completion engine for Python;
  • An OmniSharp-based completion engine for C#
  • An omnifunc-based completer that uses data from Vim’s omnicomplete system to provide semantic completions for many other languages (Ruby, PHP, etc.).

Continue reading...

April 2, 2014
Tags: C, clang, Vim

I’m an embedded operating system developer and I do all my development tasks solely in the terminal.

The primary tool, which helps me to accomplish this, is Vim. Today, I will describe how to turn Vim into a powerful IDE for C/C++ projects. I will not recommend you any plugin for project management since vanilla Vim already has all the power to cope with this task.

Despite the fact that I use Vim as a C IDE, the part of following recommendations are pretty general and may be applied to any kind of project.

Continue reading...