Issue #806 invalid

Support a cache mode

Marc Schlaich
created an issue

Pygmentizing a lot of files is considerably slow. A popular issue of this fact is the compilation time of LaTeX documents with minted ([[|ref1]], [[|ref2]]).

I like the idea in these threads to cache generated convertions. So my proposal is to directly embed this into pygments. My idea is to add a commandline argument: {{{pygmentize --cache=.pyg_cache...}}}.

If you accept this proposal you can assign it to me :-)

Comments (7)

  1. Tim Hatch

    Interesting idea. Have you considered using a makefile that regenerates the changed file in much the same manner? Or are you using pygments in some other fashion (in the api, in rst, etc)?

  2. Marc Schlaich reporter

    As already mentioned this should be for LaTeX compilation, especially for the minted package.

    Of course there are multiple ways to achieve this, but I think pygments itself is the easiest entry point for this functionality. And there might be some other use cases, too.

  3. Marc Schlaich reporter

    If it is not clear in the first post: I can contribute this functionality if you are generally interested and you are going to accept a pull request.

  4. Log in to comment