April 29, 2020

Tiling Images With Imagemagick

While writing this post about installing KVM and virt-manager, I wanted to show multiple steps of a process by capturing the window for each screen. Getting the images was quite simple, but including them one by one in a blog post seemed a bit tedious, even though there were only 5 images. Especially given that including images in markdown seems… impossible ! I knew about imagemagick before, but had never really used it, or went to see into the documentation. Read more

April 26, 2020

Renaming files in Vim: A Vimscript experiment

I took an attempt at creating a Vimscript function to rename a file with a simple command. It was not that hard, but there are a few tricks that you need to learn to get started writing Vimscript. Let’s first look at the full code for the function, with a mapping to <leader>fr function! s:RenameCurrentFile( newName ) let l:file = expand('%') let l:currentFilePath = expand('%:p:h') let l:newFile = l:currentFilePath . '/' . Read more

April 19, 2020

Installing and running libvirt and virt-manager

I wanted to start using Vagrant, to create a virtual machine that would allow me to test different ArchLinux install scripts, window manager settings, etc… without messing up my machine. That would make me start by loading the archlinux/archlinux box with the libvirt integration, which needed me to install libvirt. I wanted to use KVM as an hypervisor for that, so I needed to install QEMU for it, since KVM is a special operating mode of QEMU. Read more

April 11, 2020

Download Torrents From the CLI

I wanted to download the ArchLinux ISO image from here. It is advised to download it using torrent. We’ll be using aria2 for this. I am running Arch, so to install aria2 pacman -S aria2 To start the download, just run: aria2c <torrent or magnet link> That’s it. Once the download is complete, the file(s) will be in your current directory. There are other options to manage torrents from the command line, such as: Read more

March 21, 2019

My simplified development workflow in Go

Using tests during development to keep you code tidy As I was working on a project, while developing a new function, I noticed that I was modifying some existing code to be able to test it. Doing it this way seemed like a very bad idea, so I looked for a better way to do it. But let’s start an insanely simple example, to clarify what I’m saying. We start with a basic program, an extraString function and a main. Read more

Copyright Marin Gilles 2019-2022