Random Notes

Open Street Mapping

$ gpsbabel -t -i nmea -f infile.log -x simplify,error=0.0005k -x discard,hdop=6 -o gpx -F outfile.gpx

H263 encoding on Linux

From ubuntuforums

$ sudo aptitude install libavcodec-unstripped-51

Speeding up dpkg

From Antti-Juhani Kaijanaho's Blog

Step One: Clear the available file dpkg clear-avail

Step Two: Forget old unavailable packages dpkg forget-old-unavail

A bash function from Andrew, to use like this:

$ pdfsearch lecture-notes/ binomial

function pdfsearch {
if [ $# -ge 2 ]; then
    for f in "$1"/*.pdf; do
        echo "$f"; pdftotext "$f" - | grep "$2" && echo;
    done
fi