Tuesday, December 27, 2016

How to checkout repo contents as it was on a given date in git

A bit tricky, but this does it:

git checkout `git rev-list -n 1 --before="2009-07-27 13:37" master`

Wednesday, December 7, 2016

Strage error with gnupghome parameter for pgp

I am using them pgp module for encryption in a python app.

It runs fine on the customers machine, and also on our cloud-based Jenkins server.

But it fails on my new development machine with:

init() got an unexpected keyword argument 'gnupghome'

This happening in this line of code:

        gpg = gnupg.GPG(gnupghome=self.TMP_DIR + '/pgp')

In a previous version of this code, this was homedir. I am going to try that again.