Thinkpad Nvidia kernel boot params

GRUB_CMDLINE_LINUX_DEFAULT=”pcie_aspm=force i915.i915_enable_rc6=1 i915.i915_enable_fbc=1 i915.lvds_downclock=1 acpi=no-irq nox2apic”

most importantly nox2apic enables fn + home/end to toggle the brightness levels.

Converting webm to ogg or mp3

ffmpeg -i ./input.webm -vn -acodec copy ./output.ogg

imagemagick batch resize files

mogrify -resize 50% -format jpg *

moving chromium from machine X to machine Y

There are two things to be moved so that Chromium resumes full functionality.
The profile is stored under ~/.config/chromium
and the passwords are stored under ~/,gnome2/keyrings

Make sure to move both of these,

gnome system monitor crashes Ubuntu 12.04

This happens only if you have more than 4 cores.

Here is how to fix it:

install dconf-tools with the ‘sudo apt-get install dconf-tools’ command
start dconf-editor
navigate to org->gnome->gnome-system-monitor
modify the cpu-colors key’s value two more tuples in form of (core_number, ‘#FFFFFF’).

For my 8Core machine it looks like this:
[(0, '#FF6E00'), (1, '#CB0C29'), (2, '#49A835'), (3, '#2D7DB3'), (4, '#FF6E00'), (5, '#CB0C29'), (6, '#49A835'), (7, '#2D7DB3')]

fix: undefined reference to libiconv

I was trying to compile gd for php5 and and I encountered this:

undefined reference to `libiconv’
undefined reference to `libiconv_open’
undefined reference to `libiconv_close’

To fix:

Modify Makefile to contain  CFLAGS=-liconv

switching wallpaper in gnome 3

I hate how rigid gnome3 is but here is a way to switch the wallpapers.
You might want to wrap this in a shell script to randomly pick a file from folder of wallpapers.

1
gsettings set org.gnome.desktop.background picture-uri "$uri"

change terminal color when on ssh

function ssh() {
echo -ne “\033]10;gray25\007\033]11;gray65\007″;
/usr/bin/ssh $*;
echo -ne “\033]10;gray25\007\033]11;gray65\007″;
}

from: http://www.reddit.com/r/linux/comments/i0by6/different_terminal_color_schemes/

Hide the facebook Sidebar / Chatbar

I prefer using the older Facebook UI. It’s cleaner to me and doesn’t OD on Information. The new one kind of goes insane with the number of updates.

I wrote a chrome extension to hide these and go back to my sweet old Facebook interface :)
You can download it here : http://bit.ly/ob00Ut

PHP CURL http_code “0″

If you are using a https: URL
try setting the CA verification to false:
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);