Nix and uzbl

1 Nix

Tried Nix once again, this time it mostly worked. Mostly followed this guide, though had to make a few adjustments, such as adding --sha256=0 option for cabal2nix. Here are some notes of what I was doing:

curl https://nixos.org/nix/install | sh
. ~/.nix-profile/etc/profile.d/nix.sh
nix-env -i cabal2nix cabal-install

cd /tmp/test
cabal init
cabal2nix --shell --sha256=0 test.cabal > shell.nix
. ~/.nix-profile/etc/profile.d/nix.sh
# relax dependencies in .cabal;
# probably i've created the project with the old cabal,
# old ghc, or old libraries somehow
cabal install, etc. or run emacs from it

# import Acme.Time.Now
# add to .cabal
cabal2nix --shell --sha256=0 test.cabal > shell.nix
cabal configure
cabal build

With a regular system-wide Haskell (ghc, cabal, packages) installation, there is plenty of conflicts; at some point `which ghci` --version and ghci --version printed different versions from the same shell.

Emacs (haskell-mode, REPL) worked just fine after running it from a shell with nix-altered PATH.

All in all, it works, but appears to be pretty awkward (perhaps more so than cabal sandboxes), to require adding new packages (say, the first project i decided to try with Nix required fann, which wasn't there), and may introduce even more problems when it comes to system/DE components. I like it, but perhaps will stick to cabal sandboxes for now – they seem to be easier to handle, though even they are a pain to use, comparing to some other languages. Briefly considered stack/LTS, but don't want to deal with missing packages.

Anyway, decided to use Nix just to install some programs: I'm currently on CentOS, and there is not many packages here, while building big projects from sources, installing and resolving all the dependencies manually, and then updating those regularly is quite a pain. After a couple of hours, recalled that I wasn't quite happy with FF, and wanted to try alternative browsers.

2 uzbl

After Arora failed to parse its start page (and I have also found that it is abandoned), and Midori failed to run (with tons of GTK errors), I decided to try uzbl. The first impression was that it is cool; it quickly changed to the second impression, which was that it is not usable. But after opening its config file, the third impression was the same as the first one.

The things I didn't like include google-analytics on its start page, default vi-style qwerty-based keybindings, plenty of GTK-related warnings (I'm not quite familiar with GTK, but I suspect that it may be because of different versions of GTK, and/or improper nix build), and perhaps GUI: I don't like overly fancy GUI of FF, but it was just too bad in uzbl, though at least there wasn't much of it, and probably it's because of uzbl being installed with Nix.

The design is not great by default: there are colors like red on dark grey, which is bad.

dilbert.com, together with googlesyndication (according to logs), just makes uzbl to freeze – usually leading to me killing it.

One last thing I didn't like is a pile of python, JS, and shell scripts, and even some OpenJDK messages from time to time – perhaps that's why it is quite slow.

But let's proceed to good parts now. First thing you see is advanced keyboard control, and fancy (mostly in a good sense) design: minimalistic, but pretty – reminds of tiled WMs. Perhaps most of its issues can be fixed by configuring it: keybindings can be reconfigured, google can be blocked, colors and fonts can be changed, and those python/js scripts can be replaced: there is plenty of user-supplied scripts, and they can be written in any language, which is a good approach; pipes are used for communication, an event manager can be changed, and its overall architecture seems to be rather hackable – apart from the webkit part, perhaps.

Though I'm stuck with GNOME, uzbl makes me to consider switching to some tiling WM (i3, most likely; it is good for a netbook, at least) someday soon.

3 Vimperator

Vimperator is pretty nice, too: it's like vim inside of FF, and a emacs-style config can be set.

Update: emacs-style config is probably not the best idea, apart from a couple of commands: it hits the "uncanny valley".

Update 2: emacs-specific extensions may be handier and more lightweight, though apparently they are mostly broken in the most recent FF. Some use EXWM to get nicer keyboard controls in FF now.