// NewRepository loads the repository at the given path.
NewRepository loads the repository at the given path.
// NewRepository loads the repository at the given path .
func NewRepository(path string) (*Repository, error) {
	metadata, err := LoadMetadata(filepath.Join(path, metadataDir))
	if err != nil {
		return nil, err
	}
	repo := &Repository{
		RootPath: path,
		Metadata: metadata,
		git: git.Client{
			RepoPath: path,
		},
		golist: golist.Client{
			RootPath:        path,
			ShortenModPath:  shortenModPath,
			LengthenModPath: lengthenModPath,
		},
		Logf: log.Printf,
	}
	return repo, nil
}
func NewRepository ( path string ) ( * Repository , error ) { metadata , err := LoadMetadata ( filepath . Join ( path , metadataDir ) ) if err != nil { return nil , err } repo := & Repository { RootPath : path , Metadata : metadata , git : git . Client { RepoPath : path , } , golist : golist . Client { RootPath : path , ShortenModPath : shortenModPath , LengthenModPath : lengthenModPath , } , Logf : log . Printf , } return repo , nil }
NewRepository loads the repository at the given path.
NewRepository loads the repository at the given path .