A good bargain

I bought a HP Laserjet 1300 yesterday for $4 at a yardsale and it works perfectly. The cartridge does not seem empty at all.


The "Fix Arch" game

I have this idea.

The idea is to create an Arch Linux image that is deliberately broken perhaps even horribly broken, that users can play with in VirtualBox/Qemu/Usb flash drive. It will be (an educational) game where the user needs to fix several severe problems with Arch and will get a score of how fast he/she solves these problems.

The game might consist of:

1. A script that checks the status of the Arch installation, which the users can run to see if they have corrected an error.
2. A log that logs all the actions done by the user.
3. Some kind of scoring system that generates a score based on number of actions taken and amount of time to full system recovery.

Any inputs are welcome.


Using Dina as a console font

A month ago or so I thought of using Dina as a console (no X) font and looked into if this was possible. I found out that it was.

Here is what you need:
Dina-font (fon file)

Download and extract Dina.zip.
Run the following in the directory where you extracted Dina.zip:
$> fon2fnts Dina.fon
Which will extract the fnt’s from the fon package. Now you’ll need to convert one of the fnt’s to a psf which is what is used in the console:
$> fnt2psf Dina_8.fnt Dina-8.psf
Now copy the resulting Dina-8.psf to /usr/share/kbd/consolefonts/ and close down X.

Test out the font with $> setfont Dina-8

Here is the result:

As you can see it’s not perfect since the converted Dina font can’t handle box drawing glyphs. My best guess is that it is an unicode problem. Haven’t figured that one out yet.


Create an extremely simple battery monitor for dzen2.

I have this really simple bash/dzen2 script I’d like to share. It basically displays how much battery there is left as a dzen2 bar.

So here is the script:

# A very simple battery monitor script.
current=`grep remaining /proc/acpi/battery/BAT0/state | awk {'print $3'}`
full=`grep full /proc/acpi/battery/BAT0/info | awk {'print $4'}`
percent=`echo "($current*100)/$full" | bc`
echo $percent | gdbar -ss 1 -h 10 -w 90 -fg 'orange' -bg '#222222' | dzen2 -p 3 -w 90 -h 10 -x 1188 -y 18

I have placed this script in ~/bin and bound it to +b in my xmonad.hs.

Here is how it looks:

My Computing History

I’ve been brought up with computers. I remember in the mid eighties when my dad one day had this very big metal box with him home from his job. It was in fact the legendary IBM 5160 with had a 8086 CPU, 10 MB’s of hard drive space, 640kb’s ram, and the amazing clock freq at 5 mhz. I remember this computer being very expensive – about $10.000 IIRC.

I remember playing Digger, Larry, Kings Quest and Styx and generally spending a lot of time in the basement and having a great time. Larry learned me a lot of the English language especially interesting words like prophylactics, prostitute, liquor, and STD.

In the early nineties I lost interest in PC’s since I got an Amiga 500. What a great machine that was. I never got a harddrive for it, so it was mainly used for gaming and creating music with ProTracker. The music part did not go to well, so most of the time was used to play RPG’s like Champions of Krynn, EOB 1+2 and Black Crypt.

In the late nineties I got a bamboo PC with a 486 50 Mhz CPU, 8 Mbs of ram and about 60 Mbs of HD. It ran Windows 95 and was mainly used for school work and (you guessed right) gaming. I used this piece of sh*tty hardware for too many years until it finally buckled and I did not own a PC for several years.

Fast forward to the end of my studies at the university. I was writing my thesis on Cronenberg and Marshall McLuhan on a old Acer Laptop, which was really slow and I thought I needed to somehow speed it up and be more productive and Linux would be obvious choice. This thought was actually procrastination in disguise as it turned out. In the next four months I went through a throng of distros (including DSL, BLAG, Zenwalk, Xubuntu and Puppy Linux) and not really producing any text. Most of them did work fine, but were sort of unintuitive when handling software installation. I was bitten by the Linux bug, but I had to finish my thesis, so I went back to TinyXP for while to do so.

After finishing my studies I was without a job and what better way to spend your time than to tinker with Linux? During this phase was when I found Arch. Arch was pretty hard to install at first and it took a very long time, probably because I did not read the documentation properly which led me to use the throttled Arch ftp as my repository. Once I got through these hurdles I began exploring WM’s in the approximate following order: xfce, fluxbox, openbox, dwm, awesome, XMonad. I now use XMonad full time and struggling to learn Haskell so I can fully comprehend what goes on in xmonad.hs, but it is not a chore – IT’S FUN.

This is also where I got acquainted with LaTeX and I wrote all my job applications in TeX. (If anyone needs a good template for a job application please drop me a note)

All these applications produced in TeX payed of and I now work in one of the largest IT Companies in my country and I’ve been offered a trainee position in our Unix department when there is an opening. So my interest in Linux has given me a lot. The joy of computing, a job (and a possible future working with Unix) and of course Arch Linux.