Documentation
¶
Overview ¶
Package contextio keeps file/archive work responsive to a build's lifetime. It does not add goroutines: network readers must also bind their request to the context, while ordinary file and decompression reads stop between chunks.
Index ¶
- func Copy(ctx context.Context, destination io.Writer, input io.Reader) (int64, error)
- func CopyN(ctx context.Context, destination io.Writer, input io.Reader, size int64) (int64, error)
- func Filesystem(ctx context.Context, tree fs.FS) fs.FS
- func ReadAll(ctx context.Context, input io.Reader) ([]byte, error)
- func ReadFile(ctx context.Context, name string) ([]byte, error)
- func Reader(ctx context.Context, input io.Reader) io.Reader
- func Sum256(ctx context.Context, contents []byte) ([sha256.Size]byte, error)
- func WriteFile(ctx context.Context, name string, contents []byte, mode fs.FileMode) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Filesystem ¶
Filesystem wraps embedded/ZIP resource reads without changing path ownership.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.