Installing Debian Testing

After my previous post about why I chose Debian Testing as my current distribution, I wanted to share how I installed and configured Debian Testing. So that somebody out there looking for a guide to install their own Debian rolling system, will have at least a starting point.

Before I proceed with the post, please know that although I am a long time Linux user, with Debian, I just started my journey a couple of months back. And by no mean I am a seasoned Debian user. So whatever steps I am going to list in this post are the ones that I thought would be best suited for my requirement when I installed it on my system.

[Read more]

My Rolling Debian System

A few weeks back, I switched my home laptop to Debian and I wanted to write about my reasons behind choosing Debian and my experience with it for the first few days. But before I dive into that, here's a little background about myself. I have been using Ubuntu and later Xubuntu at home and later at office on my Desktop and on my Laptop for more than 7 years now and on the server front, I have worked on both Redhat/Centos and Ubuntu based systems. So I am not new to Linux at all.

[Read more]

VLC Player not playing nice with Radeon?

If you are on Ubuntu 16.04 using radeon open source driver for your graphics card and having issues with playing mp4 or mkv files with VLC media player then read on. If you are not sure what graphics driver is in use in your system, paste the below line in Terminal.

lspci -v -s lspci | awk '/VGA/{print $1}'

And check for the below line in the output:

Kernel driver in use: radeon<br />

The issue occurs as soon as you open a media file of type mkv or mp4 with VLC media player. Immediately after opening, it crashes silently. But if you check the /var/log/syslog, you should be able to see segmentation fault messages.

[Read more]

Higher Order Functions in Java?

Higher order functions are those functions that can return functions as their results. The returned function can then be invoked in the same way as you would invoke a normal function. In programming languages like Python, where functional programming is treated as a first class citizen, you can easily define higher order function like this.

def adder(a):
 def add(b):
  return a + b
 return add
add_with_5 = adder(5)
final_value = add_with_5(1)

Java on the other hand introduced functional programming in version 1.8. The support is still very primitive and it does not allow one to create higher order functions that return functions.

[Read more]

Inconsistent space width across editors

I had a weird problem today when my perfectly indented code comments from Vi editor were looking like a mess in Geany.

The pound signs were all out of line though they look perfectly aligned when opened in Vi editor. Initially I thought that it was a problem with the tab settings in Geany. But after tweaking some of the tab settings did not produce any result, I noticed that spaces in Geany were having lesser width compared to other characters, which was the root of the problems. I found that the font that I was using in Geany was not fixed width. And for that I should use Mono variation of the fonts. So I changed the font setting in Edit > Preference > Interface > Fonts > Editor to below:

[Read more]