actions / setup-go

Set up your GitHub Actions workflow with a specific version of Go
MIT License
1.41k stars 531 forks source link

PoC PR for next-gen caching #426

Open dsame opened 1 year ago

dsame commented 1 year ago

Description:

The existing set of cache related inputs ...

  cache:
    description: Used to specify whether caching is needed. Set to true, if you'd like to enable caching for both modules and intermediate build files.
    default: true
  cache-dependency-path:
    description: 'Used to specify the path or glob pattern to a dependency file(s), default: go.sum'

... is expanded by the additional ones:

  cache-mod:
    description: Used to specify whether modules caching is needed. Set to false, if you've found it increase the overall build time.
    default: true
  cache-build:
    description: Used to specify whether caching of intermediate build files is needed. Set to false, if you've found it increase the overall build time.
    default: true
  cache-build-path:
    description: 'Used to specify the path or glob pattern to source files(s) that affect the build cache, default: **/*.go'
  cache-id:
    description: 'Used to modify cache ID if the parallel workflows must not share the same cache, default: none'
  cache-lookup-only:
    description: 'Use the cache created by another workflow, but do not update it'
    default: false

Besides, caches of modules and intermediate build artifacts are kept and updated separately.

Related issue: https://github.com/actions/setup-actions-team/issues/39

Check list:

irl-segfault commented 11 months ago

These would be very convenient and useful knobs to expose. Thanks for pushing this towards merging!