Post-commit hook cache fixes

The cache as currently implemented doesn't work at all. This PR  fixes it. Tested for HTTPS URLs only, on an instance with 7k SVN-based jobs.