|  About Me  |  Blogs  |  Photos  |  Publications  |  Resume  | 

Archive for August, 2005

Bash Completion in Gentoo

Tuesday, August 30th, 2005

In Gentoo, bash-completion is not enabled by default, so for each package compiled with bash-completion support, we need to manually enable it for completion. Here’re the relevant steps and tools to manage bash-completion.

$ emerge bash-completion eselect

Activate bash-completion in bashrc:

[[ -f /etc/profile.d/bash-completion ]] && source /etc/profile.d/bash-completion

Add to USE flag, so packages can be compiled with bash-completion [...]

Software Suspend2

Friday, August 26th, 2005

$ emerge -av suspend2-sources hibernate-script

This will install a gentoo kernel source with the software suspend2 patches. Configure the new kernel with the following options:

$ cd /usr/src; ln -s linux-2.6.12-suspend2-r6/ linux; cd linux
$ make menuconfig
Power management options (ACPI, APM) —>
[*] Power Management support
Software Suspend []
Software Suspend 2 —>
[...]

Dealing with cue files

Friday, August 19th, 2005

Here’s a good thread on dealing with cue files. I had a cue file which contains a kvcd image. I tried cdemu, bchunk, bin2iso and nothing worked. I was mostly getting ioctl: LOOP_CLR_FD: Device or resource busy when I tried to mount the image.

In the end, vcdgear was what worked for me, it could [...]

Gentoo Network Detection

Wednesday, August 17th, 2005

I have three network possibilities at boot time: ethernet, wireless at work & wireless at home. Here’s my setup to detect and bring up the right configuration.

First we try to detect if ethernet is connected before we bring up the interface. We use mii-tool to give us the link status of an interface. If [...]

exiftran in Gentoo

Tuesday, August 16th, 2005

exiftran is a command line utility to transform jpeg images. It can rotate images automatically by checking the exif orientation tag. In Gentoo it is part of the fbi package.

$ emerge fbi
$ exiftran -ai *.jpg
# -ai for automatic in-place transformation

Wicked Firefox Extensions

Monday, August 8th, 2005

There two are by far my favourite firefox extensions:

BetterShopper - when you’re browsing on Amazon it looks up prices of currently displayed item across different Amazon stores to compare prices. It then converts all the currency displayed into the currency of your choice. Really nifty extension but perhaps more useful for non-US residents.
SessionSaver .2 - [...]