Documentation
¶
Index ¶
- Constants
- Variables
- func CopyWithCallback(writer io.Writer, reader io.Reader, totalSize int64, cb CopyCallback) (int64, error)
- func DoHTTP(c *Configuration, req *http.Request) (*http.Response, error)
- func Environ() []string
- func InRepo() bool
- func InstallFilters() error
- func InstallHooks(force bool) error
- func LocalMediaPath(sha string) (string, error)
- func ObjectUrl(endpoint Endpoint, oid string) (*url.URL, error)
- func ResetTempDir() error
- func Stack() []byte
- func TempFile(prefix string) (*os.File, error)
- type AltConfig
- type CallbackReader
- type ClientError
- type Configuration
- func (c *Configuration) Endpoint() Endpoint
- func (c *Configuration) GitConfig(key string) (string, bool)
- func (c *Configuration) HttpClient() *http.Client
- func (c *Configuration) ObjectUrl(oid string) (*url.URL, error)
- func (c *Configuration) RemoteEndpoint(remote string) Endpoint
- func (c *Configuration) Remotes() []string
- func (c *Configuration) SetConfig(key, value string)
- type CopyCallback
- type CredentialCmd
- type Creds
- type Endpoint
- type HookExists
- type WrappedError
- func (e *WrappedError) Context() map[string]string
- func (e *WrappedError) Del(key string)
- func (e *WrappedError) Error() string
- func (e *WrappedError) Errorf(format string, args ...interface{})
- func (e *WrappedError) Get(key string) string
- func (e *WrappedError) InnerError() string
- func (e *WrappedError) Set(key, value string)
- func (e *WrappedError) Stack() []byte
Constants ¶
View Source
const Version = "0.5.0"
Variables ¶
View Source
var ( LargeSizeThreshold = 5 * 1024 * 1024 TempDir = filepath.Join(os.TempDir(), "git-lfs") UserAgent string LocalWorkingDir string LocalGitDir string LocalMediaDir string LocalLogDir string )
View Source
var (
Config = NewConfig()
)
View Source
var (
NotInARepositoryError = errors.New("Not in a repository")
)
Functions ¶
func CopyWithCallback ¶
func InstallFilters ¶
func InstallFilters() error
func InstallHooks ¶
func LocalMediaPath ¶
func ResetTempDir ¶
func ResetTempDir() error
Types ¶
type CallbackReader ¶
type CallbackReader struct { C CopyCallback TotalSize int64 ReadSize int64 io.Reader }
type ClientError ¶
type ClientError struct { Message string `json:"message"` DocumentationUrl string `json:"documentation_url,omitempty"` RequestId string `json:"request_id,omitempty"` }
func (*ClientError) Error ¶
func (e *ClientError) Error() string
type Configuration ¶
type Configuration struct { CurrentRemote string // contains filtered or unexported fields }
func NewConfig ¶
func NewConfig() *Configuration
func (*Configuration) Endpoint ¶
func (c *Configuration) Endpoint() Endpoint
func (*Configuration) HttpClient ¶
func (c *Configuration) HttpClient() *http.Client
func (*Configuration) RemoteEndpoint ¶
func (c *Configuration) RemoteEndpoint(remote string) Endpoint
func (*Configuration) Remotes ¶
func (c *Configuration) Remotes() []string
func (*Configuration) SetConfig ¶
func (c *Configuration) SetConfig(key, value string)
type CopyCallback ¶
func CopyCallbackFile ¶
type CredentialCmd ¶
func NewCommand ¶
func NewCommand(input Creds, subCommand string) *CredentialCmd
func (*CredentialCmd) Credentials ¶
func (c *CredentialCmd) Credentials() Creds
func (*CredentialCmd) StdoutString ¶
func (c *CredentialCmd) StdoutString() string
type HookExists ¶
func (*HookExists) Error ¶
func (e *HookExists) Error() string
type WrappedError ¶
type WrappedError struct { Err error Message string Panic bool // contains filtered or unexported fields }
func Download ¶
func Download(oid string) (io.ReadCloser, int64, *WrappedError)
func Error ¶
func Error(err error) *WrappedError
func Errorf ¶
func Errorf(err error, format string, args ...interface{}) *WrappedError
func Upload ¶
func Upload(oidPath, filename string, cb CopyCallback) *WrappedError
func (*WrappedError) Context ¶
func (e *WrappedError) Context() map[string]string
func (*WrappedError) Del ¶
func (e *WrappedError) Del(key string)
func (*WrappedError) Error ¶
func (e *WrappedError) Error() string
func (*WrappedError) Errorf ¶
func (e *WrappedError) Errorf(format string, args ...interface{})
func (*WrappedError) Get ¶
func (e *WrappedError) Get(key string) string
func (*WrappedError) InnerError ¶
func (e *WrappedError) InnerError() string
func (*WrappedError) Set ¶
func (e *WrappedError) Set(key, value string)
func (*WrappedError) Stack ¶
func (e *WrappedError) Stack() []byte
Click to show internal directories.
Click to hide internal directories.