Wednesday, June 03, 2009

Uzbl the new usable browser on Ubuntu 9.04 Jaunty Jackalope

Uzbl is a new Webkit based browser with minimal graphical interphase. For opening a URL you have to type 'o URL' and it opens. See the screenshot below:


For adding a bookmark you have to type 'B'. For loading a bookmark you have to type 'u' and for loading a URL from history you have to type 'U'.

Actually o, B, u, U etc are keybindings defined in the config file and B, u and U also call the required scripts.

Tabbed browsing is not available but you can open any number of windows for different URLs.

This browser is being developed on Archlinux and easily installable from AUR. The bookmarks and history use the utility dmenu which has been patched for displaying the URLs vertically and available as dmenu-vertical in AUR.

After installation you can start the browser with 'uzbl' command but you get a blank browser window which does nothing since there is no default configuration. You need to create 'uzbl' folder in ~/.config and copy the following two files in it:
cp /usr/share/uzbl/examples/configs/sampleconfig ~/.config/uzbl/config
cp /usr/share/uzbl/examples/configs/cookies ~/.config/uzbl/

For bookmarks you need to create 'uzbl' folder in ~/.local/share and copy the file:
cp /usr/share/uzbl/examples/data/bookmarks ~/.local/share/uzbl/

and create an empty session file:
cd ~/.local/share/uzbl
touch session
You can also create a launcher uzbl.desktop:
[Desktop Entry]
Encoding=UTF-8
Name=Uzbl
GenericName=uzbl
Exec=/usr/bin/uzbl %u
Terminal=false
Type=Application
Categories=Application;Network;
Icon=applications-internet
All the above settings are required even on Archlinux on which it is being developed since the developer is trying to just give a browser with all other things managed from scripts outside the browser, although, thy are giving 'example scripts' and the settings given above configure these example scripts to work in conjunction with the browser.

Now let us come to installation of uzbl on Ubuntu 9.04 Jaunty Jackalope.

For installing the recent version of Webkit Library add the following sources to /etc/apt/sources.list
deb http://ppa.launchpad.net/webkit-team/ppa/ubuntu intrepid main
deb-src http://ppa.launchpad.net/webkit-team/ppa/ubuntu intrepid main
to import keys
sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0x991e6cf92d9a3c5b
and to install
sudo apt-get update
sudo apt-get install git git-core libwebkit-dev
to compile and install uzbl
git clone git://github.com/Dieterbe/uzbl.git
cd uzbl
make
sudo make install
After installation on Ubuntu you need to create uzbl directory in ~/.config and ~/.local/share and copy/create the files as stated above.

In addition, Ubuntu does not have $XDG_DATA_HOME set to ~/.local/share by default and dmenu-vertical is not available in Debian/Ubuntu repositories. These things are required by the example scripts.

There are various ways to set the environment variable $XDG_DATA_HOME but I simply decided to put the following line in the load_url_from_bookmarks and insert_bookmark scripts for the time being.
XDG_DATA_HOME=~/.local/share
I have downloaded dmenu-4.0 sources from:
wget http://code.suckless.org/dl/tools/dmenu-4.0.tar.gz

and the required patch from:
wget http://evaryont.me/dmenu-vertical-history.patch
and compiled dmenu-vertical:
tar -xvzf dmenu-4.0.tar.gz
cd dmenu-4.0
patch -p1 < ~/path-to/dmenu-vertical-history.patch
make
sudo checkinstall
I used checkinstall to make .deb package of dmenu-vetical.

No comments:

Air India direct flight to San Fransisco has flown through China today.

 My sister in law left for San Fransisco by AI 173 flight which flows over North Pole. I tracked that flight on flightstats.com till it land...