Documentation ¶
Overview ¶
Package localstorage handles LFS content stored locally NOTE: Subject to change, do not rely on this package from outside git-lfs source
Index ¶
Constants ¶
This section is empty.
Variables ¶
var (
TempDir = filepath.Join(os.TempDir(), "git-lfs")
)
Functions ¶
func InitStorage ¶ added in v1.5.3
func InitStorage() error
func InitStorageOrFail ¶ added in v1.5.3
func InitStorageOrFail()
func ResetTempDir ¶ added in v1.3.0
func ResetTempDir() error
func ResolveDirs ¶ added in v1.3.0
func ResolveDirs()
Types ¶
type LocalStorage ¶
LocalStorage manages the locally stored LFS objects for a repository.
func NewStorage ¶ added in v1.3.0
func NewStorage(storageDir, tempDir string) (*LocalStorage, error)
func Objects ¶ added in v1.3.0
func Objects() *LocalStorage
func (*LocalStorage) AllObjects ¶
func (s *LocalStorage) AllObjects() []Object
AllObjects returns a slice of the the objects stored in this LocalStorage object. This does not necessarily mean referenced by commits, just stored. Note: reports final SHA only, extensions are ignored.
func (*LocalStorage) BuildObjectPath ¶
func (s *LocalStorage) BuildObjectPath(oid string) (string, error)
func (*LocalStorage) ClearTempObjects ¶
func (s *LocalStorage) ClearTempObjects() error
func (*LocalStorage) ObjectPath ¶
func (s *LocalStorage) ObjectPath(oid string) string
func (*LocalStorage) ScanObjectsChan ¶
func (s *LocalStorage) ScanObjectsChan() <-chan Object
ScanObjectsChan returns a channel of all the objects stored in this LocalStorage object. This does not necessarily mean referenced by commits, just stored. You should not alter the store until this channel is closed. Note: reports final SHA only, extensions are ignored.