nienbo / cache-buildkite-plugin

Tarball, Rsync & S3 Cache Kit for Buildkite. Supports Linux, macOS and Windows
https://buildkite.com/plugins
MIT License
67 stars 39 forks source link

add date formats to templates #71

Closed pquerna closed 6 months ago

pquerna commented 6 months ago

I wanted a cache to easily expire every month (and get rebuilt), so it was helpful to have date as a template option, eg:

  key: "z1-cache-{{ id }}-{{ runner.os }}-{{ checksum 'yarn.lock' }}-{{ date '+%Y-%m'}}"
gencer commented 6 months ago

Hi @pquerna! Thanks for the PR.

Released as https://github.com/nienbo/cache-buildkite-plugin/releases/tag/v2.4.16 🚀