ensure config file generation is idempotent on rubies > 1.8.7 and generate pretty JSON while we're there