First impressions of Hugo

Hugo is great

Fast, instant refresh, markdown, templates, layouts and great configuration.

What more can we ask for?

I would say more clear guidelines on how to deal with Hugo themes.

Beginner’s difficulties with Hugo themes

The docs describe a sample quickstart site with a predefined theme. If we follow, we’re easily good to go with a new site. Yet, probably we would like to use a different theme.

So we go to and find a lovely one. I’m using the Jane theme from xianmin.

Google Play Services 10002 Error

The following post may be helpful to resolve the 10002 RESULT_SIGN_IN_FAILED error.

If you have changed or pre-installed your development machine and have installed a fresh Android Studio version, you’ll have a new debug.keystore created by the Android Studio installation.

The apps that are started directly from the IDE during development will no longer be signed with keys registered with Google Play Services. This is no issue if the app doesn’t use Google Play Services like Sign-in, Leaderboards or Achievements, but if it does, these functionalities will no longer work and you may get the 10002 RESULT_SIGN_IN_FAILED error.

Enable Shift+Numpad Navigation for Ubuntu 18.04

Open terminal and execute the following command.

setxkbmap -option 'numpad:microsoft'

Other helpful shortcuts are Ctrl+Alt+Arrow when you want to navigate back or forth after peeking into function defintions and going back to previous functions. In Ubuntu 18.04 by default these shortcuts are taken by the system. To make them available for use in text editors, use the following commands.

gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-left "[]"
gsettings set org.gnome.desktop.wm.keybindings switch-to-workspace-right "[]"

Clean Ubuntu Boot Partition

First check the kernel version, so we won’t delete the kernel image in use:

uname -r

List installed kernels:

dpkg --list 'linux-image*' | grep ^ii

Delete unnecessary kernels (replace the VERSION with kernel that should be removed):

sudo apt-get remove linux-image-VERSION

After old kernels are removed, you can remove packages that are not used anymore:

sudo apt-get autoremove

Finally update grub kernel list:

sudo update-grub

Go composite variant type for JSON marshal

Implement a custom Variant type that can hold either string or int while satisfying the JSON Marshaler and Unmarshaler interfaces to support correct encoding/decoding of the values.

NPM/Yarn 404 Error when Building Docker Image

Sometimes the following error appears on Ubuntu Linux when building docker images for nodejs projects and the project includes privately scoped node packages.

An unexpected error occurred: Request failed "404 Not Found"

Initial workaround

The initial naive workaround we used was to manually change our DNS entry in /etc/resolv.conf to point to the local gateway.



Then manually stop the systemd-resolved service.

sudo service systemd-resolved stop

How to build the Golang Bitcoin Node for Windows 10 (btcd)

The latest btcd release build is from 2015. There is a nice description how to build it for Linux/Mac, but for Windows it’s suggested to download the latest binaries, which are 626 commits behind master as of February 2018. Fortunately, with Golang we can easily build binaries for Windows, and we can follow the steps of the Linux build process. The only issue I faced was a problem in the Glide dependency manager and that’s how this little post was born.

Update Go version on Linux

1. Download the latest (or desired) Go version


2. Remove old installation

sudo rm -rf /usr/local/go

3. Extract archive into /usr/local/go

sudo tar -C /usr/local -xzf go-archive-filename.tar.gz

4. Test if everything is OK

go version

Clean up disk space taken by Docker

Show disk space used by docker images, containers and volumes.

$ docker system df

TYPE                TOTAL               ACTIVE              SIZE                RECLAIMABLE
Images              5                   5                   1.722GB             784.5MB (45%)
Containers          5                   0                   78.12MB             78.12MB (100%)
Local Volumes       4                   4                   231.5MB             0B (0%)
Build Cache         0                   0                   0B                  0B

The docker prune command may be used with some docker objects like images, containers and volumes to free unused disk space.

Free space used by containers.

docker container prune

Free space used by volumes.

docker volume prune

In addition, you can use the docker system prune command to clean up multiple types of objects at once.

docker system prune -af