patches.js: factor out version graph code into amd module.
Merge branch 'master' of ssh://github.com/adhocracy/adhocracy-3