internal/pkg: implement file artifact
All checks were successful
Test / Create distribution (push) Successful in 53s
Test / Sandbox (push) Successful in 2m57s
Test / ShareFS (push) Successful in 4m53s
Test / Sandbox (race detector) (push) Successful in 5m21s
Test / Hpkg (push) Successful in 5m27s
Test / Hakurei (push) Successful in 5m42s
Test / Hakurei (race detector) (push) Successful in 7m38s
Test / Flake checks (push) Successful in 1m48s

This is an Artifact implementing File, backed by a constant, caller-supplied byte slice.

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2026-01-07 00:39:29 +09:00
parent 45301559bf
commit 3a21ba1bca
4 changed files with 92 additions and 0 deletions

View File

@@ -188,6 +188,8 @@ const (
// KindExecNet is the kind of [Artifact] returned by [NewExec] but with a
// non-nil checksum.
KindExecNet
// KindFile is the kind of [Artifact] returned by [NewFile].
KindFile
)
// Ident returns a deterministic identifier for the supplied params and