Versions in this module Expand all Collapse all v0 v0.0.2 Apr 15, 2024 Changes in this version + const ArchiveTypeTar + const ArchiveTypeZip + const CompressionTypeGzip + const CompressionTypeNone + const CompressionTypeZstd + const FileSchemeHTTP + const FileSchemeHTTPS + const FileSchemeLocal + const FileSchemeNull + const FileSchemeStdin + const FileSchemeStdio + const FileSchemeStdout + const GitSchemeGit + const GitSchemeHTTP + const GitSchemeHTTPS + const GitSchemeLocal + const GitSchemeSSH + func NewCannotSpecifyCompressionForZipError() error + func NewCannotSpecifyGitBranchAndTagError() error + func NewCannotSpecifyTagWithRefError() error + func NewCompressionUnknownError(compression string) error + func NewDepthParseError(s string) error + func NewDepthZeroError() error + func NewFormatCannotBeDeterminedError(value string) error + func NewFormatNotAllowedError(format string, allowedFormats map[string]struct{}) error + func NewFormatOverrideNotAllowedForDevNullError(devNull string) error + func NewFormatUnknownError(formatString string) error + func NewInvalidPathError(format string, path string) error + func NewNoPathError() error + func NewOptionsCouldNotParseRecurseSubmodulesError(s string) error + func NewOptionsCouldNotParseStripComponentsError(s string) error + func NewOptionsInvalidForFormatError(format string, s string) error + func NewOptionsInvalidKeysError(keys ...string) error + func NewOptionsInvalidValueForKeyError(key string, value string) error + func NewPathUnknownGzError(path string) error + func NewProtoFileCannotBeDevPathError(format string, path string) error + func NewReadDisabledError(scheme string) error + func NewReadGitDisabledError() error + func NewReadHTTPDisabledError() error + func NewReadLocalDisabledError() error + func NewReadModuleDisabledError() error + func NewReadStdioDisabledError() error + func NewRealCleanPathError(path string) error + func NewWriteDisabledError(scheme string) error + func NewWriteHTTPDisabledError() error + func NewWriteLocalDisabledError() error + func NewWriteStdioDisabledError() error + type ArchiveFormatOption func(*archiveFormatInfo) + func WithArchiveDefaultCompressionType(defaultCompressionType CompressionType) ArchiveFormatOption + type ArchiveRef interface + ArchiveType func() ArchiveType + StripComponents func() uint32 + SubDirPath func() string + func NewArchiveRef(path string, archiveType ArchiveType, compressionType CompressionType, ...) (ArchiveRef, error) + type ArchiveType int + type BucketRef interface + type CompressionType int + type DirFormatOption func(*dirFormatInfo) + type DirRef interface + Path func() string + func NewDirRef(path string) (DirRef, error) + type FileRef interface + CompressionType func() CompressionType + FileScheme func() FileScheme + Path func() string + type FileScheme int + type GetBucketOption func(*getBucketOptions) + func WithGetBucketTerminateFileNames(terminateFileNames [][]string) GetBucketOption + type GetFileOption func(*getFileOptions) + func WithGetFileKeepFileCompression() GetFileOption + type GetModuleOption func(*getModuleOptions) + type GetParsedRefOption func(*getParsedRefOptions) + func WithAllowedFormats(formats ...string) GetParsedRefOption + type GitFormatOption func(*gitFormatInfo) + type GitRef interface + Depth func() uint32 + GitName func() git.Name + GitScheme func() GitScheme + Path func() string + RecurseSubmodules func() bool + SubDirPath func() string + func NewGitRef(path string, gitName git.Name, depth uint32, recurseSubmodules bool, ...) (GitRef, error) + type GitScheme int + type HasFormat interface + Format func() string + type ModuleFormatOption func(*moduleFormatInfo) + type ModuleRef interface + ModuleReference func() bufmoduleref.ModuleReference + func NewModuleRef(path string) (ModuleRef, error) + type ParsedArchiveRef interface + func NewDirectParsedArchiveRef(format string, path string, fileScheme FileScheme, archiveType ArchiveType, ...) ParsedArchiveRef + type ParsedBucketRef interface + type ParsedDirRef interface + func NewDirectParsedDirRef(format string, path string) ParsedDirRef + type ParsedFileRef interface + type ParsedGitRef interface + func NewDirectParsedGitRef(format string, path string, gitScheme GitScheme, gitName git.Name, ...) ParsedGitRef + type ParsedModuleRef interface + func NewDirectParsedModuleRef(format string, moduleReference bufmoduleref.ModuleReference) ParsedModuleRef + type ParsedProtoFileRef interface + type ParsedRef interface + type ParsedSingleRef interface + func NewDirectParsedSingleRef(format string, path string, fileScheme FileScheme, ...) ParsedSingleRef + type ProtoFileFormatOption func(*protoFileFormatInfo) + type ProtoFileRef interface + IncludePackageFiles func() bool + Path func() string + type PutFileOption func(*putFileOptions) + func WithPutFileNoFileCompression() PutFileOption + type RawRef struct + ArchiveStripComponents uint32 + CompressionType CompressionType + Format string + GitBranch string + GitDepth uint32 + GitRecurseSubmodules bool + GitRef string + GitTag string + IncludePackageFiles bool + Path string + SubDirPath string + UnrecognizedOptions map[string]string + type ReadBucketCloser interface + RelativeRootPath func() string + SetSubDirPath func(string) + SubDirPath func() string + type ReadBucketCloserWithTerminateFileProvider interface + TerminateFileProvider func() TerminateFileProvider + type ReadWriteBucketCloser interface + type Reader interface + GetBucket func(ctx context.Context, container app.EnvStdinContainer, bucketRef BucketRef, ...) (ReadBucketCloserWithTerminateFileProvider, error) + GetFile func(ctx context.Context, container app.EnvStdinContainer, fileRef FileRef, ...) (io.ReadCloser, error) + GetModule func(ctx context.Context, container app.EnvStdinContainer, moduleRef ModuleRef, ...) (bufmodule.Module, error) + func NewReader(logger *zap.Logger, storageosProvider storageos.Provider, ...) Reader + type ReaderOption func(*reader) + func WithReaderGit(gitCloner git.Cloner) ReaderOption + func WithReaderHTTP(httpClient *http.Client, httpAuthenticator httpauth.Authenticator) ReaderOption + func WithReaderLocal() ReaderOption + func WithReaderModule(moduleResolver bufmodule.ModuleResolver, moduleReader bufmodule.ModuleReader) ReaderOption + func WithReaderStdio() ReaderOption + type Ref interface + type RefParser interface + GetParsedRef func(ctx context.Context, value string, options ...GetParsedRefOption) (ParsedRef, error) + func NewRefParser(logger *zap.Logger, options ...RefParserOption) RefParser + type RefParserOption func(*refParser) + func WithArchiveFormat(format string, archiveType ArchiveType, options ...ArchiveFormatOption) RefParserOption + func WithDirFormat(format string, options ...DirFormatOption) RefParserOption + func WithGitFormat(format string, options ...GitFormatOption) RefParserOption + func WithModuleFormat(format string, options ...ModuleFormatOption) RefParserOption + func WithProtoFileFormat(format string, options ...ProtoFileFormatOption) RefParserOption + func WithRawRefProcessor(rawRefProcessor func(*RawRef) error) RefParserOption + func WithSingleFormat(format string, options ...SingleFormatOption) RefParserOption + type SingleFormatOption func(*singleFormatInfo) + func WithSingleCustomOptionKey(key string) SingleFormatOption + func WithSingleDefaultCompressionType(defaultCompressionType CompressionType) SingleFormatOption + type SingleRef interface + CustomOptionValue func(key string) (string, bool) + func NewSingleRef(path string, compressionType CompressionType) (SingleRef, error) + type TerminateFile interface + Name func() string + Path func() string + type TerminateFileProvider interface + GetTerminateFiles func() []TerminateFile + type Writer interface + PutFile func(ctx context.Context, container app.EnvStdoutContainer, fileRef FileRef, ...) (io.WriteCloser, error) + func NewWriter(logger *zap.Logger, options ...WriterOption) Writer + type WriterOption func(*writer) + func WithWriterLocal() WriterOption + func WithWriterStdio() WriterOption