Ubuntu – Really force remove a package.

I was trying to remove a package on one of the Ubuntu installations the other day and was not able to do so. I tried google and tried all the options mentioned in various forums like “-f”, purge, reinstall and few others but nothing helped. I kept getting some errors about some files being already deleted. I also tried “set -e” in the prompt but the only result I got was terminal also getting killed.

Finally I found the only thing that could work for me was to go to directory “/var/lib/dkpg/info”and then delete all files that started with the name of the package. Hope this helps someone.

Ubuntu-Desktop
Ubuntu-Desktop (Photo credit: Kevin Byrom)
Enhanced by Zemanta

Display X applications from virtual terminals

GNOME Session plugin
GNOME Session plugin (Photo credit: David Siegel)

Here is a script that can help you set the proper envirionment to start a gnome-shell from one of the terminals.

#!/bin/bash - 
#===============================================================================
#
# FILE: xenv.sh
# 
# USAGE: ./xenv.sh 
# 
# DESCRIPTION: http://live.gnome.org/GnomeShell/Debugging
#
# 
# OPTIONS: ---
# REQUIREMENTS: ---
# BUGS: ---
# NOTES: ---
# AUTHOR: Amit Agarwal (aka), [email protected]
# CREATED: 09/14/2011 04:45:31 PM IST
# Last modified: Wed Sep 14, 2011 04:45PM
# REVISION: ---
#===============================================================================

gnome_session=$(pgrep -u $USER gnome-session)
eval export$(sed's/\o000/\n/g;' < /proc/$gnome_session/environ |grep DISPLAY)
eval export$(sed's/\o000/\n/g;' < /proc/$gnome_session/environ |grep XAUTHORITY)
eval export$(sed's/\o000/\n/g;' < /proc/$gnome_session/environ |grep DBUS_SESSION_BUS_ADDRESS)

So, once you have done that you have the correct environment to use the X display and thus you can start the gnome-shell as well or do any other fancy thing that you want 🙂

Enhanced by Zemanta

gnome-tweak-tool gets a fantastic new Font Selector window

Here is the quick look at how the Font Selector looks like now. And its not just for the gnome-tweak-tool, its for all the places for font selection. I really loved it. So intuitive to use and amazingly good to look. This is what a good design and thinking can do. Kudos to Gnome team for coming up with this.

Font Selector for Verne
Font Selector for Verne
Enhanced by Zemanta