gsnedders

Regular expressions are just brainfuck in disguise.

Installing lxml on Dreamhost

Tags: , March 15, 2009 (3 comments)

I just spend the best part of 50 minutes getting lxml running on Dreamhost (really not recommended as a host, at all). Here's what I hope is a working shell script that takes a pristine Dreamhost site and installs lxml on it.

#!/bin/sh
mkdir work
cd work
curl -O ftp://xmlsoft.org/libxml2/LATEST_LIBXML2
curl -O ftp://xmlsoft.org/libxml2/LATEST_LIBXSLT
tar -xzf LATEST_LIBXML2
tar -xzf LATEST_LIBXSLT
cd libxml2-*
./configure --prefix=${HOME}/.local
make
make install
cd ../libxslt-*
./configure --prefix=${HOME}/.local --with-libxml-prefix=${HOME}/.local --with-libxml-include-prefix=${HOME}/.local/include --with-libxml-libs-prefix=${HOME}/.local/lib
make
make install
export LDFLAGS=-L/$HOME/.local/lib
export CPPFLAGS=-I/$HOME/.local/include
export LD_RUN_PATH=$HOME/.local/lib
curl -O http://peak.telecommunity.com/dist/ez_setup.py
python ez_setup.py
easy_install --prefix=~/.python lxml
python -c "from lxml import etree"

My Year In Cities, 2008

Tags: , December 31, 2008 (0 comments)

Following the lead of Anne (who himself followed some Mark), here is a list of cities I visited in 2008:

  • St Andrews, United Kingdom
  • Edinburgh, United Kingdom
  • Dundee, United Kingdom
  • Cambridge, United Kingdom
  • Aberdeen, United Kingdom
  • Ely, United Kingdom
  • Berlin, Germany
  • Prague, Czech Republic
  • Copenhagen, Denmark
  • Kalmar, Sweden
  • Borgholm, Sweden
  • Lyon, France
  • Nice (though mainly Mandelieu), France
  • Monaco
  • Glasgow, United Kingdom

One or more nights in each place, apart from: Edinburgh, Dundee, Glasgow (these are all fairly close to home (St Andrews)), and Monaco (half a day after TPAC with Anne, Lachlan, and Marcos).

Friendly Love

Tags: , , September 20, 2008 (0 comments)

O love, O sweetest love,
I fall for one so near,
I cannot bear to risk,
Of a friend no more.

I fall for one so near.
Will it be love,
Of a friend no more?
Or will friendship end?

Will it be love,
Love of a friend,
Or will friendship end?
What love I have.

Love of a friend,
I cannot bear to risk.
What love I have,
O love, O sweetest love.

Anolis 1.0RC1

Tags: September 1, 2008 (2 comments)

The project that I have been working on for the past several months has finally come to fruition: I tagged the first release candidate earlier this week (which, actually, won't be the final release, as one or two things that ought to be in it have come up, primarily support for Python 2.3). However, I better start by answering a more basic question: what is it? It is an HTML document postprocessor. It takes an HTML document, and adds in a table of contents, section numbers, cross-references, and one or two other things; in short, it allows you to be lazy. Who cares about that? At least four people.

It has it's own website all ready, quite a feat knowing my laziness. Hopefully the gigantic HTML 5 will move over to using it soon (it has been an invaluable test case throughout development, testing all kinds of bizarre edge cases), and possibly one or two other things too. It's nice to get something used, apart from SimplePie, for once.

Higher Results

Tags: , , August 6, 2008 (1 comment)

Just under a year after I got my Standard Grade results, I received my Higher results today, via SMS, as the only real way to get them when in Copenhagen without internet access (I am now in Kalmar, with internet access). Needless to say, they are:

ComputingA
EnglishB
FrenchC
MathematicsB
PhysicsA

I ought to have done better in French and maths — with French I certainly have the evidence to appeal that (I should have, if I hadn't completely wrecked one essay, got a B); however, with maths, having been ill for a great part of the year, I only improved very late, resulting in a lack of evidence to appeal with. That said, I am still doing maths, so it is less important.

For those who want a quick run-down of the grades, anything equal to or greater than 50% is a pass, and the percentages break into grades roughly as follows (see the Wikipedia article for more information):

GradePercentage
A70% and above
B60% – 69%
C50% – 59%
D45% – 49%
No Award44% and below

Page:  1 2 3 4 … 31