예제 #1
0
파일: repo.go 프로젝트: emil2k/go-vcs
func init() {
	// Overwrite the git opener to return repositories that use the
	// gogits native-go implementation.
	vcs.RegisterOpener("git", func(dir string) (vcs.Repository, error) {
		return Open(dir)
	})
}
예제 #2
0
파일: repo.go 프로젝트: shazow/go-vcs
func init() {
	// Overwrite the hg opener to return repositories that use the
	// faster native-Go hg implementation.
	vcs.RegisterOpener("hg", func(dir string) (vcs.Repository, error) {
		return Open(dir)
	})
}
예제 #3
0
파일: repo.go 프로젝트: alexsaveliev/go-vcs
func init() {
	vcs.RegisterOpener("hg", func(dir string) (vcs.Repository, error) {
		return Open(dir)
	})
	vcs.RegisterCloner("hg", func(url, dir string, opt vcs.CloneOpt) (vcs.Repository, error) {
		return CloneHgRepository(url, dir, opt)
	})
}