tarutil

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 24, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Package tarutil provides deterministic tar creation with fixed ownership.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Write

func Write(w io.Writer, entries []Entry, epoch time.Time) error

Write emits entries as a reproducible PAX tar stream.

Types

type Entry

type Entry struct {
	Path  string
	Mode  fs.FileMode
	Data  []byte
	Link  string
	IsDir bool
}

Entry is one tar member.

func CollectDir

func CollectDir(root, prefix string, options Options) ([]Entry, error)

CollectDir reads a directory tree into deterministic tar entries.

type Options

type Options struct {
	Prefix  string
	Exclude []string
	Modes   map[string]fs.FileMode
}

Options controls deterministic collection.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL