Documentation ¶
Index ¶
- func ConcatFileContent(dst io.Writer, src io.Reader) error
- func Equal(file1, file2 File, full ...bool) (bool, error)
- func Export(storageRoot string, w io.Writer, opts ...ExportOption) (retErr error)
- func Import(storageRoot string, r io.Reader, cb ...func(*tar.Header) error) error
- func Iterate(r io.Reader, cb func(File) error, stream ...bool) error
- func NewHeader(name string, size int64) *tar.Header
- func NewReader(files []File) (io.Reader, error)
- func WithWriter(w io.Writer, cb func(*tar.Writer) error) (retErr error)
- func WriteFile(tw *tar.Writer, file File) error
- type ExportOption
- type File
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConcatFileContent ¶
ConcatFileContent writes the content of each file in the stream to dst, one after another. Headers are not copied. `src` must be a tar stream
This is not a terribly useful function but many of the tests are structured around the 1.x behavior of concatenating files, and so this is useful for porting those tests.
Types ¶
type ExportOption ¶
type ExportOption func(*exportConfig)
ExportOption configures an export call.
func WithHeaderCallback ¶
func WithHeaderCallback(cb func(*tar.Header) error) ExportOption
WithHeaderCallback configures the export call to execute the callback for each tar file exported.
Click to show internal directories.
Click to hide internal directories.