Add -D key/value support

I believe this to be a fairly elegant solution to the problem