Dev Log


Tech blog by Rok Povšič

Setting up a static-site blog on GitHub pages on a custom domain, with comments

This blog is built using a static-site generator named Pelican. It converts the posts you write in Markdown directly to HTML files, which happens on your machine at "compile-time". This means there's no dynamic page generation on each HTTP request, which is fine (even preferred) for a blog-like website. Pelican is written in Python and using it feels Pythonic (it uses configuration-as-code) which is great for any hardcore Pythonista. I've just recently also added a commenting system and will explain here what the blog's components are.

Continue reading

How to upgrade Postgres on Ubuntu 16.04

This is a guide on how to upgrade Postgres. The commands below will install a new Postgres 9.6 instance, migrate all the data, and afterwards uninstall the old Postgres 9.5 instance.

Continue reading

A list of useful Git commands

Here's a list of Git commands that solve specific problems I encounter sometimes. I find these commands very useful, although I may not use them every day, which means I will tend to forget them and have to re-find them again and again. I'm storing them here for easy access. Maybe somebody's going to find them useful too.

Continue reading

A continuous integration guide for .NET with GitLab CI

Here, I describe the process of setting up continuous integration (CI) for a C# project that is hosted on GitLab.

Continue reading

Which language to use with TWS API (Interactive Brokers API)?

Interactive Brokers has an API called TWS API which you can use to programmatically execute trades, poll current/historical market data, get account info, open positions, etc. Official bindings for several programming languages exist, namely: C#, Java, C++, VB, and Python. All the TWS API functionality is supported in all of those programming languages. Which language should you choose for your trading program?

Continue reading

What is the chance of losing money in the stock market?

The first step of achieving good returns in the stock market is not losing money. What is the percentage chance of losing money in the stock market?

Continue reading

A short guide for new VIM users

VIM is a text editor that makes writing code MUCH more enjoyable. After using it for a long time it's almost hard to believe how people can write code without it. It's like driving a new BMW opposed to an old Peugeot. Everything is just smooth and fast. And unlike BMW, it's free! Watching another programmer write code without using VIM is almost like watching someone type using two fingers (one with each hand). You just want to say: give me the keyboard, I'll do it for you.

Continue reading

Keyboard tricks to write code faster

Using any keyboard layout other than English may be less optimal for programming, at least that was my experience when compared to using Slovenian and German keyboard layouts to write code. Switching to the English layout made a great difference for me. It's simply faster to reach commonly used characters such as []{};:,@""<>= compared some (maybe all) other layouts. I've trained myself to always use English keyboard when programming and when writing in English language in general (such as now).

Continue reading

Using PyCharm without a mouse

I've been always fan of minimizing mouse/touchpad usage when programming. There is a certain kind of satisfaction when you are able to do everything with the keyboard. You get the feeling of being agile, swift. It's a sign of mastery. There's no unnecessary movement and unnecessary time and muscle power spent. Watching another programmer use their keyboard solely and be fast doing it makes you respect them more. Watching them grab the mouse a lot and wait for them to find the mouse cursor is sometimes even a little painful.

Continue reading

How to fix mouse offset bug in VMWare Workstation under Windows 8.1 host

There’s a bug in mouse behavior that happened to me in VMWare Workstation under Windows 8.1 host with Ubuntu 14.04 as client. When hovering mouse over something and/or selecting something by dragging, the mouse moved it’s position by some offset.

Continue reading

Page 1 / 2