Esempio n. 1
0
File: scan.go Progetto: amery/gorepo
func repo_scan() int {
	var depth uint = REPO_SCAN_DEPTH
	excludes := []string{".repo", "downloads"}
	m := manifest.NewManifest(nil)

	for r := range tree.Scan(".", depth, int(depth/2), excludes) {
		m.AddProjectByPath(r.Path, r.Repository)
	}

	return 0
}
Esempio n. 2
0
File: list.go Progetto: amery/gorepo
func repo_list() int {
	var depth uint = REPO_LIST_SCAN_DEPTH
	excludes := []string{".repo"}
	ret := 1

	for r := range tree.Scan(".", depth, int(depth/2), excludes) {
		fmt.Printf("%s\n", r.Path)
		ret = 0
	}

	return ret
}