Skip to content

cache: automagically cache and reuse output files

Jakub Ružička requested to merge cache into master

Following commands got support for automating cache and reuse of produced output files:

  • make-archive
  • get-archive
  • srcpkg
  • build

Cache uses checksum of current project state as a key and also stores and validates cached files' checksums. Currently the project checksum is obtained using git magicks so the cache is only enabled for projects using git.

Cache lives in pkg/.cache.json and it's updated automatically when a new archive/srcpkg/package is created or when invalid cache entry is requested.

Caching can be disabled using new --no-cache option.

Cache can be cleared by removing pkg/.cache.json file.

Self test on make-archive is included.

Merge request reports