I recently ran into a strange problem with running emacs. A few days ago, my delete, page up, and page down keys stopped working, but only when emacs was run in the terminal. Whenever I hit one of those keys, emacs would complain that the region was empty. This was baffling for a while. Searching the internet turned up nothing, so I had to assume that it was something I had done. One further symptom manifest: when I used my M-[ keybinding, the bound function would execute and it inserted 3~…
I periodically try to use TAGS to navigate round my code in emacs.
When it works, it is very convenient. I have not been using them
lately, partly because generating the tags and keeping them up-to-date
has always been a bit fiddly. In the past, I have tried to get emacs
to automatically regenerate my tags when I save changes to a file. I
have had solutions that work to a greater or lesser extent, but they
are always a bit unsatisfying. Inevitably, I end up having to write
an extra shell scr…
Relative to many other languages, the humble array is underrepresented
in Haskell. That may follow from the difficulty of fitting arrays
into pure code; an entire array to update a single element rarely
makes sense. There are some immutable data structures that
look like arrays,
but are not actually. Mutable arrays (in ST or IO) make more
sense, so I want to write up a few notes about them.
Haskell has two general purpose array libraries:
array and
vector. There are also
some special-purpose…
For quite some time, I have been meaning to set up travis-ci for some of my github projects. To get the ball rolling, I chose my projects with the simplest build systems and dependencies. As promised, it was very much a painless experience. I added my trivial .travis.yml files specifying Haskell as my language and asking for a few versions of ghc; everything else was automatic. I had to make a few tweaks here and there to update some old test suites that I had not run in a while. That alone…
whole-program-llvm is a set of scripts that I started to compile programs and libraries into single LLVM bitcode files. The scripts stand in for a compiler (either clang or gcc) and compile each file in a program or library twice: once as the build system intended and once as LLVM bitcode. Another script, extract-bc can then be run over the final binary to link the LLVM bitcode files into a single large bitcode file. This is very useful for performing whole program analysis (hence the name of…
I recently found myself needing to excise all of the type 3 fonts from
a TeX document. I believe that type 3 fonts are actually just
embedded postscript, which is less than ideal for a nice PDF.
Obviously, I would never intentionally include a type 3 font, so some
other tool in my toolchain must have been adding them. Eventually, I
figured out that they were sneaking in through some matplotlib graphs.
I found a nice description of the
problem. The solution I chose was to tell matplotlib to us…
Today I ended up reading one of many articles decrying the current state of OpenGL. I don't remember which one. I will be interested to see where OpenGL does from here given its competition. The whole topic got me curious to see what version of OpenGL my video drivers actually supported, so of course I checked with glxinfo. Much to my surprise, I was running the open source nouveau driver. I never thought about it while I was installing Ubuntu, and I guess this was the default.
I have to sa…
I just released version 0.2.0.2 of my datalog library to
hackage.
Datalog is a declarative query language similar in spirit to Prolog,
though less expressive. If you have a problem that can be expressed
as
dynamic transitive closure,
Datalog is one way to express your problem. I believe Datalog is
equivalent to SQL with recursive queries. My implementation is
currently fairly basic; I hope to add some more sophistication in the
near future. The primary feature of my implementation is that it…
Recently, I cut a long overdue release of Taffybar, my desktop bar for xmonad (or any window manager, really). The changes are in the changelog. A few highlights are:
Better support for resizing screens
A few new widgets
A completely new pager built on EWMH
Vastly improved power usage
Fixed an annoying bug where time zone changes are not picked up
More recent fixes deal with breakage from the network/network-uri split. Now on a Hackage near you.
I have no specific plans for interesting new …
I have been running Debian unstable on my machines for years reasonably happy. Living on the bleeding edge is slightly exciting. Having maximally up-to-date versions of programs is also useful. The cost of running Debian unstable is implied by the name: sometimes things break. I have been fine with that over the years - I knew what I was getting in to. So the occasional update messes up a symlink for glibc. No big deal. At least, that is how I used to feel.
I feel like I might be getting …