Documentation
¶
Index ¶
- Constants
- Variables
- func EasyExec(c string, args ...string) error
- func GitRepack(m MetaContext, arg GitRepackArg) (bool, error)
- func IsPackDataFile(f string) bool
- func IsPackIndexFile(f string) bool
- func LogInput(l DebugLogger, s string)
- func LogOutput(l DebugLogger, s string)
- func NewGoGitRepoWithStorage(stor storage.Storer) (*gogit.Repository, error)
- func NewPackSyncStorage(s storage.Storer, ps *PackSync, op GitOpType) (storage.Storer, error)
- func TermLogMsgFetch(ctx context.Context, tl TermLogger, typ string, hash plumbing.Hash)
- func TermLogf(ctx context.Context, t TermLogger, opts TermLogBitfield, format string, ...)
- type BadGitPathError
- type BadIndexNameError
- type BaseCmd
- type BatchedIOLoggedO
- type BatchedLineIOer
- type CapabilitiesCmd
- type Cmd
- type ComingledIndex
- type DebugLogger
- type ExecContext
- type FastFetch
- type FetchArg
- type FetchCmd
- type GitCmdArg
- type GitCmdRes
- type GitCountObjectsRes
- type GitError
- type GitOpType
- type GitRepackArg
- type GitRepoDesc
- type Index
- type IndexName
- type InternalError
- type LineOutputter
- type ListCmd
- type LocalCheckoutDir
- type LocalPath
- type LocalRepo
- type LogWrapperOutput
- type MemoryStorage
- func (s *MemoryStorage) HasEncodedObject(h plumbing.Hash) error
- func (s *MemoryStorage) List() (RefListIter, error)
- func (s *MemoryStorage) LocalCheckoutDir() LocalCheckoutDir
- func (s *MemoryStorage) Name() RemoteName
- func (s *MemoryStorage) PackSync() *PackSync
- func (s *MemoryStorage) ToGitStorage(op GitOpType) (storage.Storer, error)
- func (s *MemoryStorage) URL() RemoteURL
- type MemoryStorageBase
- func (m *MemoryStorageBase) FetchNewIndices(ctx context.Context, since time.Time) ([]RawIndex, error)
- func (m *MemoryStorageBase) FetchPackData(ctx context.Context, name IndexName, wc io.Writer) error
- func (m *MemoryStorageBase) HasIndex(ctx context.Context, name IndexName) (bool, error)
- func (m *MemoryStorageBase) PushPackData(ctx context.Context, name IndexName, rc io.Reader) error
- func (m *MemoryStorageBase) PushPackIndex(ctx context.Context, name IndexName, rc io.Reader) error
- func (m *MemoryStorageBase) WithLocal(ps *PackSync, lcd LocalCheckoutDir) *MemoryStorage
- type MemoryStorageFactory
- type MetaContext
- func (m MetaContext) Ctx() context.Context
- func (m MetaContext) DbgLogCmd(s string)
- func (m MetaContext) DbgLogOutput(s string)
- func (m MetaContext) DbgLogf(format string, args ...interface{})
- func (m MetaContext) E() *ExecContext
- func (m MetaContext) InitPackSyncPush() error
- func (m MetaContext) RemoteRepo(op GitOpType) (*gogit.Repository, error)
- func (m MetaContext) Repack() (bool, error)
- func (m MetaContext) ReverseRemote(op GitOpType) (*ReverseRemote, error)
- func (m MetaContext) TermLogStatus(err error)
- func (m MetaContext) TermLogf(opts TermLogBitfield, format string, args ...interface{})
- type NilTermLogger
- type NotImplementedError
- type OutputSet
- type PackFileGeneric
- type PackFileType
- type PackSync
- type PackSyncRemoter
- type PackSyncStorageBase
- type PackSyncStoragePush
- func (p *PackSyncStoragePush) EncodedObject(t plumbing.ObjectType, h plumbing.Hash) (plumbing.EncodedObject, error)
- func (p *PackSyncStoragePush) EncodedObjectSize(h plumbing.Hash) (int64, error)
- func (p *PackSyncStoragePush) HasEncodedObject(h plumbing.Hash) error
- func (p *PackSyncStoragePush) SetEncodedObject(obj plumbing.EncodedObject) (plumbing.Hash, error)
- type ParseError
- type Parser
- type PushCmd
- type RawIndex
- type RefData
- type RefDataByName
- type RefListIter
- type RefListSliceIter
- type RemoteHelper
- type RemoteHelperOptions
- type RemoteName
- type RemoteURL
- type ReverseRemote
- type SimpleBatchedLineIO
- type SimpleLineOuputter
- type StorageWrapper
- func (w *StorageWrapper) HasEncodedObject(h plumbing.Hash) error
- func (w *StorageWrapper) List() (RefListIter, error)
- func (w *StorageWrapper) LocalCheckoutDir() LocalCheckoutDir
- func (w *StorageWrapper) Name() RemoteName
- func (w *StorageWrapper) PackSync() *PackSync
- func (w *StorageWrapper) ToGitStorage(op GitOpType) (storage.Storer, error)
- func (w *StorageWrapper) URL() RemoteURL
- type StorageWrapperFactory
- type Storer
- type StorerFactory
- type SyncedPack
- type TermLogBitfield
- type TermLogLine
- type TermLogger
- type TestEnv
- type TestHelper
- type TestLogger
- type TestMemoryStorageFactory
- type TestScratchRepo
- func (r *TestScratchRepo) Git(t *testing.T, args ...string)
- func (r *TestScratchRepo) GitWithErr(t *testing.T, args ...string) error
- func (r *TestScratchRepo) Mkdir(t *testing.T, name string)
- func (r *TestScratchRepo) Origin() string
- func (r *TestScratchRepo) ReadFile(t *testing.T, name string, content string)
- func (r *TestScratchRepo) ReadFileBinary(t *testing.T, name string, expected []byte)
- func (r *TestScratchRepo) ReadFileToString(t *testing.T, name string) string
- func (r *TestScratchRepo) ReadFileWithErr(name string, content string) error
- func (r *TestScratchRepo) WriteFile(t *testing.T, name, content string)
- func (r *TestScratchRepo) WriteFileBinary(t *testing.T, name string, content []byte)
- type UnknownCmd
Constants ¶
const MsgFetchObjects = "🐕 Fetching from remote ... "
const TestProtName = "tap"
Variables ¶
var GitObjPackDir = filepath.Join("objects", "pack")
var GitRemoteTapCode string
Functions ¶
func GitRepack ¶
func GitRepack( m MetaContext, arg GitRepackArg, ) ( bool, error, )
func IsPackDataFile ¶
func IsPackIndexFile ¶
func LogInput ¶
func LogInput(l DebugLogger, s string)
func LogOutput ¶
func LogOutput(l DebugLogger, s string)
func NewGoGitRepoWithStorage ¶
func NewGoGitRepoWithStorage(stor storage.Storer) (*gogit.Repository, error)
func NewPackSyncStorage ¶
func TermLogMsgFetch ¶
func TermLogf ¶
func TermLogf( ctx context.Context, t TermLogger, opts TermLogBitfield, format string, args ...interface{}, )
Types ¶
type BadGitPathError ¶
type BadGitPathError struct {
Path LocalPath
}
func (BadGitPathError) Error ¶
func (e BadGitPathError) Error() string
type BadIndexNameError ¶
type BadIndexNameError struct{}
func (BadIndexNameError) Error ¶
func (e BadIndexNameError) Error() string
type BaseCmd ¶
type BaseCmd struct {
Output LineOutputter
}
type BatchedIOLoggedO ¶
type BatchedIOLoggedO struct {
// contains filtered or unexported fields
}
func (*BatchedIOLoggedO) Next ¶
func (t *BatchedIOLoggedO) Next( ctx context.Context, ) (string, LineOutputter, error)
type BatchedLineIOer ¶
type BatchedLineIOer interface {
Next(ctx context.Context) (string, LineOutputter, error)
}
func NewBatchedIOLoggedO ¶
func NewBatchedIOLoggedO( blio BatchedLineIOer, log DebugLogger, ) BatchedLineIOer
type CapabilitiesCmd ¶
type CapabilitiesCmd struct {
BaseCmd
}
func (*CapabilitiesCmd) Run ¶
func (c *CapabilitiesCmd) Run(m MetaContext) error
type Cmd ¶
type Cmd interface { Run(MetaContext) error // contains filtered or unexported methods }
type ComingledIndex ¶
type ComingledIndex struct { sync.RWMutex Indices map[IndexName]*Index Objects map[plumbing.Hash][]*Index Newest time.Time }
func NewComingledIndex ¶
func NewComingledIndex() *ComingledIndex
func (*ComingledIndex) Absorb ¶
func (c *ComingledIndex) Absorb(idx *Index) error
func (*ComingledIndex) NumIndicies ¶
func (c *ComingledIndex) NumIndicies() int
type DebugLogger ¶
type DebugLogger interface {
Log(s string)
}
type ExecContext ¶
type ExecContext struct {
// contains filtered or unexported fields
}
func (*ExecContext) DbgLog ¶
func (e *ExecContext) DbgLog() DebugLogger
func (*ExecContext) Storage ¶
func (e *ExecContext) Storage() Storer
func (*ExecContext) TermLog ¶
func (e *ExecContext) TermLog() TermLogger
type FastFetch ¶
type FastFetch struct { storage.Storer // remote FOKS storage // contains filtered or unexported fields }
FastFetch is a specialized fetcher that combines a PackSync and low-level go-git access, to provide an optimized fetch backend.
func NewFastFetch ¶
func NewFastFetch( m MetaContext, args []FetchArg, ) ( *FastFetch, error, )
func (*FastFetch) EncodedObject ¶
func (f *FastFetch) EncodedObject( typ plumbing.ObjectType, hash plumbing.Hash, ) ( plumbing.EncodedObject, error, )
func (*FastFetch) EncodedObjectSize ¶
func (*FastFetch) HasEncodedObject ¶
func (*FastFetch) Run ¶
func (f *FastFetch) Run(m MetaContext) error
type GitCmdRes ¶
func GitRepackAlways ¶
type GitCountObjectsRes ¶
func GitCountObjects ¶
func GitCountObjects( arg GitCmdArg, ) ( *GitCountObjectsRes, error, )
type GitRepoDesc ¶
func (*GitRepoDesc) Origin ¶
func (d *GitRepoDesc) Origin() string
type Index ¶
type Index struct { Name IndexName Filename string Sz int64 NumObjs int Raw []byte Idx *idxfile.MemoryIndex Ctime time.Time }
func (*Index) FullIndexPath ¶
func (*Index) PackDataFilename ¶
func (*Index) PackIndexFilename ¶
func (*Index) PartialIndexPath ¶
type IndexName ¶
type IndexName string
func ParsePackIndex ¶
func (IndexName) PackDataFilename ¶
func (IndexName) PackIndexFilename ¶
type InternalError ¶
type InternalError string
func (InternalError) Error ¶
func (e InternalError) Error() string
type LineOutputter ¶
Note that for I/O in this system, the input and ouptut are intertwined. Every line of input may or may not have a corresponding set of output lines. For instance, a capabilities command's first line of input has a corresponding n lines of output, one for each "capabitlity." For a batch command like push, the last line of input (the empty line) has a corresponding set of output, one for each input line, showing results of each push. Hence, the TextInterfacer line source returns a single input line, and a LineOutputter instance that allows the machinery to output 0-n lines of output. OR, the answer might have been an error, in which case, bubble that back up.
type LocalCheckoutDir ¶
type LocalCheckoutDir string
func NewLocalCheckDirFromWorkingDirAndGitDir ¶
func NewLocalCheckDirFromWorkingDirAndGitDir( wd LocalPath, gd LocalPath, ) ( LocalCheckoutDir, error, )
func NewLocalCheckoutDirFromDotGit ¶
func NewLocalCheckoutDirFromDotGit(p LocalPath) (LocalCheckoutDir, error)
func (LocalCheckoutDir) DotGit ¶
func (l LocalCheckoutDir) DotGit() string
func (LocalCheckoutDir) String ¶
func (l LocalCheckoutDir) String() string
type LocalRepo ¶
type LocalRepo struct {
// contains filtered or unexported fields
}
func NewLocalRepo ¶
func NewLocalRepo() *LocalRepo
type LogWrapperOutput ¶
type LogWrapperOutput struct {
// contains filtered or unexported fields
}
type MemoryStorage ¶
type MemoryStorage struct { *MemoryStorageBase // contains filtered or unexported fields }
func (*MemoryStorage) HasEncodedObject ¶
func (s *MemoryStorage) HasEncodedObject(h plumbing.Hash) error
func (*MemoryStorage) List ¶
func (s *MemoryStorage) List() (RefListIter, error)
func (*MemoryStorage) LocalCheckoutDir ¶
func (s *MemoryStorage) LocalCheckoutDir() LocalCheckoutDir
func (*MemoryStorage) Name ¶
func (s *MemoryStorage) Name() RemoteName
func (*MemoryStorage) PackSync ¶
func (s *MemoryStorage) PackSync() *PackSync
func (*MemoryStorage) ToGitStorage ¶
func (s *MemoryStorage) ToGitStorage(op GitOpType) (storage.Storer, error)
func (*MemoryStorage) URL ¶
func (s *MemoryStorage) URL() RemoteURL
type MemoryStorageBase ¶
func NewMemoryStorageBase ¶
func NewMemoryStorageBase(nm RemoteName, url RemoteURL) *MemoryStorageBase
func (*MemoryStorageBase) FetchNewIndices ¶
func (*MemoryStorageBase) FetchPackData ¶
func (*MemoryStorageBase) PushPackData ¶
func (*MemoryStorageBase) PushPackIndex ¶
func (*MemoryStorageBase) WithLocal ¶
func (m *MemoryStorageBase) WithLocal( ps *PackSync, lcd LocalCheckoutDir, ) *MemoryStorage
type MemoryStorageFactory ¶
type MemoryStorageFactory struct {
// contains filtered or unexported fields
}
func NewMemoryStorageFactory ¶
func NewMemoryStorageFactory() *MemoryStorageFactory
func (*MemoryStorageFactory) New ¶
func (f *MemoryStorageFactory) New(nm RemoteName, url RemoteURL, lcd LocalCheckoutDir) (Storer, error)
type MetaContext ¶
type MetaContext struct {
// contains filtered or unexported fields
}
func NewMetaContext ¶
func NewMetaContext(ctx context.Context, e *ExecContext) MetaContext
func NewMetaContextBackground ¶
func NewMetaContextBackground(e *ExecContext) MetaContext
func (MetaContext) Ctx ¶
func (m MetaContext) Ctx() context.Context
func (MetaContext) DbgLogCmd ¶
func (m MetaContext) DbgLogCmd(s string)
func (MetaContext) DbgLogOutput ¶
func (m MetaContext) DbgLogOutput(s string)
func (MetaContext) DbgLogf ¶
func (m MetaContext) DbgLogf(format string, args ...interface{})
func (MetaContext) E ¶
func (m MetaContext) E() *ExecContext
func (MetaContext) InitPackSyncPush ¶
func (m MetaContext) InitPackSyncPush() error
func (MetaContext) RemoteRepo ¶
func (m MetaContext) RemoteRepo(op GitOpType) (*gogit.Repository, error)
func (MetaContext) Repack ¶
func (m MetaContext) Repack() (bool, error)
func (MetaContext) ReverseRemote ¶
func (m MetaContext) ReverseRemote( op GitOpType, ) ( *ReverseRemote, error, )
func (MetaContext) TermLogStatus ¶
func (m MetaContext) TermLogStatus(err error)
func (MetaContext) TermLogf ¶
func (m MetaContext) TermLogf(opts TermLogBitfield, format string, args ...interface{})
type NilTermLogger ¶
type NilTermLogger struct{}
func (*NilTermLogger) Log ¶
func (n *NilTermLogger) Log(ctx context.Context, t TermLogLine)
type NotImplementedError ¶
type NotImplementedError struct{}
func (NotImplementedError) Error ¶
func (e NotImplementedError) Error() string
type OutputSet ¶
type OutputSet struct {
// contains filtered or unexported fields
}
func NewOutputSet ¶
func NewOutputSet() *OutputSet
type PackFileGeneric ¶
type PackFileGeneric struct { Name IndexName Type PackFileType }
func ParsePackFileGeneric ¶
func ParsePackFileGeneric(f string) *PackFileGeneric
type PackFileType ¶
type PackFileType int
const ( PackFileTypeNone PackFileType = 0 PackFileTypeData PackFileType = (1 << 0) PackFileTypeIndex PackFileType = (1 << 1) PackFileTypeBoth PackFileType = (PackFileTypeData | PackFileTypeIndex) )
type PackSync ¶
type PackSync struct {
// contains filtered or unexported fields
}
func NewPackSync ¶
func NewPackSync( rn RemoteName, rem PackSyncRemoter, localGit *filesystem.Storage, dotGitDir billy.Filesystem, tl TermLogger, ) *PackSync
func NewPackSyncFromPath ¶
func NewPackSyncFromPath( rn RemoteName, rem PackSyncRemoter, lcd LocalCheckoutDir, tl TermLogger, ) ( *PackSync, error, )
func (*PackSync) InitFastFetch ¶
InitFastFetch initializes the packsync object for a fetch operation. It first builds an index from the on-disk partial indices, then fetches new indices from the server, and finally updates the index with the new indices.
func (*PackSync) InitPush ¶
func (p *PackSync) InitPush( m MetaContext, ) error
type PackSyncRemoter ¶
type PackSyncRemoter interface { HasIndex(ctx context.Context, name IndexName) (bool, error) FetchNewIndices(ctx context.Context, since time.Time) ([]RawIndex, error) FetchPackData(ctx context.Context, name IndexName, wc io.Writer) error PushPackData(ctx context.Context, name IndexName, rc io.Reader) error PushPackIndex(ctx context.Context, name IndexName, rc io.Reader) error }
type PackSyncStorageBase ¶
type PackSyncStoragePush ¶
type PackSyncStoragePush struct { *PackSyncStorageBase // contains filtered or unexported fields }
func NewPackSyncStoragePush ¶
func NewPackSyncStoragePush(b *PackSyncStorageBase) *PackSyncStoragePush
func (*PackSyncStoragePush) EncodedObject ¶
func (p *PackSyncStoragePush) EncodedObject( t plumbing.ObjectType, h plumbing.Hash, ) (plumbing.EncodedObject, error)
func (*PackSyncStoragePush) EncodedObjectSize ¶
func (p *PackSyncStoragePush) EncodedObjectSize(h plumbing.Hash) (int64, error)
func (*PackSyncStoragePush) HasEncodedObject ¶
func (p *PackSyncStoragePush) HasEncodedObject(h plumbing.Hash) error
func (*PackSyncStoragePush) SetEncodedObject ¶
func (p *PackSyncStoragePush) SetEncodedObject( obj plumbing.EncodedObject, ) (plumbing.Hash, error)
type ParseError ¶
type ParseError struct {
// contains filtered or unexported fields
}
func (ParseError) Error ¶
func (e ParseError) Error() string
type Parser ¶
type Parser struct {
// contains filtered or unexported fields
}
func NewParser ¶
func NewParser(tio BatchedLineIOer) *Parser
func (*Parser) Next ¶
Next returns the next command from the input. On EOF, it returns nil for both the command and the error. For all other errors, it returns nil and the error. Should be called in a loop, like so, more or less:
for { cmd, err := p.Next() if err != nil { return err } if cmd == nil { break } }
type PushCmd ¶
type PushCmd struct { BaseCmd // input args Refs []config.RefSpec // contains filtered or unexported fields }
func (*PushCmd) Run ¶
func (c *PushCmd) Run(m MetaContext) error
type RefDataByName ¶
type RefDataByName map[plumbing.ReferenceName]*RefData
RefDataByName represents a map of reference names to data about that ref.
type RefListIter ¶
type RefListSliceIter ¶
type RefListSliceIter struct {
// contains filtered or unexported fields
}
func NewRefListSliceIter ¶
func NewRefListSliceIter(refs []*plumbing.Reference) *RefListSliceIter
func (*RefListSliceIter) Close ¶
func (r *RefListSliceIter) Close()
func (*RefListSliceIter) ForEach ¶
func (r *RefListSliceIter) ForEach(f func(*plumbing.Reference) error) error
func (*RefListSliceIter) HasAnyHashes ¶
func (r *RefListSliceIter) HasAnyHashes() bool
type RemoteHelper ¶
type RemoteHelper struct {
// contains filtered or unexported fields
}
A RemoteHelper takes I/O from git (some via argv, and others via stdin/stdout), and also a storageEngine, and performs the git-remote-helper-protocol. This class is responsible for all of the specifics of fetch/push mechanics, etc. The storage by comparison is dumb.
func NewRemoteHelper ¶
func NewRemoteHelper( blio BatchedLineIOer, store Storer, opts RemoteHelperOptions, ) (*RemoteHelper, error)
type RemoteHelperOptions ¶
type RemoteHelperOptions struct { DbgLog DebugLogger // For development/internal logging TermLog TermLogger // For user-facing logging (on the terminal) GitCmd string // optional -- where to find the 'git' command if not the default RepackThreshhold int // optional -- how many loose objects before we pack }
type RemoteName ¶
type RemoteName string
type ReverseRemote ¶
func (*ReverseRemote) Name ¶
func (r *ReverseRemote) Name() string
type SimpleBatchedLineIO ¶
type SimpleBatchedLineIO struct {
// contains filtered or unexported fields
}
func NewSimpleBatchedLineIO ¶
func NewSimpleBatchedLineIO(in io.Reader, out io.Writer) *SimpleBatchedLineIO
func (*SimpleBatchedLineIO) Next ¶
func (s *SimpleBatchedLineIO) Next(ctx context.Context) (string, LineOutputter, error)
type SimpleLineOuputter ¶
type SimpleLineOuputter struct {
// contains filtered or unexported fields
}
type StorageWrapper ¶
type StorageWrapper struct {
// contains filtered or unexported fields
}
func NewStorageWrapper ¶
func NewStorageWrapper( storage storage.Storer, nm RemoteName, url RemoteURL, ps *PackSync, lcd LocalCheckoutDir, ) (*StorageWrapper, error)
func (*StorageWrapper) HasEncodedObject ¶
func (w *StorageWrapper) HasEncodedObject(h plumbing.Hash) error
func (*StorageWrapper) List ¶
func (w *StorageWrapper) List() (RefListIter, error)
func (*StorageWrapper) LocalCheckoutDir ¶
func (w *StorageWrapper) LocalCheckoutDir() LocalCheckoutDir
func (*StorageWrapper) Name ¶
func (w *StorageWrapper) Name() RemoteName
func (*StorageWrapper) PackSync ¶
func (w *StorageWrapper) PackSync() *PackSync
func (*StorageWrapper) ToGitStorage ¶
func (w *StorageWrapper) ToGitStorage(op GitOpType) (storage.Storer, error)
func (*StorageWrapper) URL ¶
func (w *StorageWrapper) URL() RemoteURL
type StorageWrapperFactory ¶
type StorageWrapperFactory struct {
// contains filtered or unexported fields
}
func (*StorageWrapperFactory) New ¶
func (s *StorageWrapperFactory) New(nm RemoteName, url RemoteURL, lcd LocalCheckoutDir) (Storer, error)
type Storer ¶
type Storer interface { // For the go-git Storage interface ToGitStorage(op GitOpType) (storage.Storer, error) PackSync() *PackSync List() (RefListIter, error) Name() RemoteName URL() RemoteURL LocalCheckoutDir() LocalCheckoutDir }
type StorerFactory ¶
type StorerFactory interface {
New(nm RemoteName, url RemoteURL, lcd LocalCheckoutDir) (Storer, error)
}
type TermLogBitfield ¶
type TermLogBitfield uint32
const ( TermLogStd TermLogBitfield = 0 TermLogCr TermLogBitfield = 1 TermLogNoNewline TermLogBitfield = 2 )
func (TermLogBitfield) ToMsg ¶
func (b TermLogBitfield) ToMsg(msg string) TermLogLine
type TermLogLine ¶
type TermLogLine struct { Msg string Opts TermLogBitfield }
type TermLogger ¶
type TermLogger interface {
Log(ctx context.Context, t TermLogLine)
}
type TestEnv ¶
type TestEnv struct { Dir string Bin string Sfact *TestMemoryStorageFactory EnvIsSet bool Desc GitRepoDesc // contains filtered or unexported fields }
func NewTestEnv ¶
func NewTestEnvWithPrefix ¶
func (*TestEnv) InitWithDesc ¶
func (e *TestEnv) InitWithDesc(d GitRepoDesc) error
func (*TestEnv) NewScratchRepo ¶
func (e *TestEnv) NewScratchRepo(t *testing.T) *TestScratchRepo
type TestHelper ¶
type TestHelper struct {
// contains filtered or unexported fields
}
A git-remote-helper that works only in test. It creates a socket and listens on it, expecting the tap process to connect to it. As per that protocol, the first line in the transcript is the command line invocation of the tap process. And then it should work as a typical remote helper.
func NewTestHelper ¶
func NewTestHelper(s string, sfact StorerFactory) *TestHelper
func (*TestHelper) Run ¶
func (t *TestHelper) Run() error
func (*TestHelper) Stop ¶
func (t *TestHelper) Stop() error
type TestLogger ¶
type TestLogger struct { }
func (*TestLogger) Log ¶
func (t *TestLogger) Log(s string)
type TestMemoryStorageFactory ¶
type TestMemoryStorageFactory struct { Last *MemoryStorage // contains filtered or unexported fields }
func NewTestMemoryStorageFactory ¶
func NewTestMemoryStorageFactory() *TestMemoryStorageFactory
func (*TestMemoryStorageFactory) New ¶
func (f *TestMemoryStorageFactory) New( nm RemoteName, url RemoteURL, lcd LocalCheckoutDir, ) (Storer, error)
type TestScratchRepo ¶
type TestScratchRepo struct {
// contains filtered or unexported fields
}
func (*TestScratchRepo) GitWithErr ¶
func (r *TestScratchRepo) GitWithErr(t *testing.T, args ...string) error
func (*TestScratchRepo) Origin ¶
func (r *TestScratchRepo) Origin() string
func (*TestScratchRepo) ReadFile ¶
func (r *TestScratchRepo) ReadFile(t *testing.T, name string, content string)
func (*TestScratchRepo) ReadFileBinary ¶
func (r *TestScratchRepo) ReadFileBinary(t *testing.T, name string, expected []byte)
func (*TestScratchRepo) ReadFileToString ¶
func (r *TestScratchRepo) ReadFileToString(t *testing.T, name string) string
func (*TestScratchRepo) ReadFileWithErr ¶
func (r *TestScratchRepo) ReadFileWithErr(name string, content string) error
func (*TestScratchRepo) WriteFile ¶
func (r *TestScratchRepo) WriteFile(t *testing.T, name, content string)
func (*TestScratchRepo) WriteFileBinary ¶
func (r *TestScratchRepo) WriteFileBinary(t *testing.T, name string, content []byte)
type UnknownCmd ¶
func (*UnknownCmd) Run ¶
func (c *UnknownCmd) Run(m MetaContext) error