Realign the fork so it diffs from upstream actions/cache only by the GCS
cache backend, instead of carrying unrelated downgrades and deletions.
- Restore package.json/package-lock.json to upstream 5.0.4 deps; the fork
had downgraded to 4.2.x. Re-add @google-cloud/storage (gcsCache.ts needs it).
- Rebuild dist/ against the restored deps so it bundles the real GCS client
rather than a stale build against downgraded deps.
- Restore deleted upstream files: 7 workflow YAMLs, .github/CODEOWNERS,
.licensed.yml. (To be disabled in the fork, not removed.)
- Revert action.yml/restore/save manifests to upstream name/description/
author; keep only the gcs-bucket/gcs-path-prefix inputs as the fork diff.
- auto-tag.yml: track upstream's highest semver release tag, moving both the
exact-version tag and the major alias, instead of force-pinning v1.
- Remove checkout/ composite action; relocated to Cula-Technologies/checkout.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@actions/cache restoreCache contract returns the matched key (primary or
restore) so callers can compare to primaryKey for cache-hit. Our wrapper
was returning the full gcs object path, so restoreImpl.ts always set
cache-hit=false → every job ran pnpm install --frozen-lockfile on top of
a restored node_modules, burning ~34s per job for nothing.
findFileOnGCS now returns { key, path }; outer wrapper returns the key.
Breaking: removes fetch-depth, filter, sparse-checkout, sparse-checkout-cone-mode
inputs. Composite always populates full history + blob:none so every caller
for the same SHA gets the same tarball. Cache key simplifies to repo-<sha>.
Rationale: every sparse callsite in cula-platform runs downstream of a
full-tree-populating job (find_affected). Full-tree restore (~3-5s) is
faster than sparse clone (~10-20s). One cache entry per SHA, no
fragmentation, no races on conflicting tarball contents.
If someone needs a sparse checkout outside the cache, use raw actions/checkout.
Required when sparse-checkout patterns include files (not just dirs) —
lint-github-docs uses cone-mode=false to pin package.json, pnpm-lock.yaml
etc. Without the passthrough actions/checkout treats files as dirs.
Adds sparse-checkout input. When set, the composite skips GCS restore
and save entirely and falls through to a plain actions/checkout. This
keeps the full-tree cache uncontaminated by sparse subsets (which
would break subsequent full-tree reads on cache hit).
First-step-capable checkout wrapper: uses Cula-Technologies/cache/restore
to pull a tarball of the repo keyed on SHA, falls back to actions/checkout
on miss then saves. Meant to be the first step of a job — avoids the
local-composite chicken-and-egg.
Drop workflows we don't need on the fork:
- licensed.yml (no .licenses for @google-cloud/storage)
- workflow.yml (jest tests mock @actions/cache, break with wrapper)
- close-inactive-issues, issue-opened, pr-opened (upstream oncall)
- publish-immutable-actions (not publishing to marketplace)
- release-new-action-version (replaced by auto-tag.yml)
Drop CODEOWNERS so merges don't require @actions/actions-cache review.
Drop .licensed.yml config (no longer used).
Port GCS support from danySam/gcs-cache. When gcs-bucket input is set,
cache to Google Cloud Storage via Application Default Credentials; else
fall back to GitHub's cache service transparently.
- New inputs: gcs-bucket, gcs-path-prefix (default: github-cache)
- New src/utils/gcsCache.ts wraps @actions/cache restore/save
- restoreImpl/saveImpl swap @actions/cache import for local wrapper
- Adds @google-cloud/storage ^7.16.0, bumps typescript to ^5.8.3
- Regenerated dist/ via npm run build
Skipped: upstream workflow removals, README/examples/RELEASES churn,
licensed/codeql config, GCS integration-test workflow.