Esempio n. 1
0
func sanityCheckBuild(cmd *c.Command, args []string) {
	dev.MustFindCrowbar()
	paths := make([]string, 0, 0)
	for _, bc := range dev.BarclampsInBuild(dev.CurrentBuild()) {
		paths = append(paths, filepath.Join(bc.Repo.Path(), "crowbar.yml"))
	}
	buildutils.SanityCheckMetadata(paths)
}
Esempio n. 2
0
func barclampsInBuild(cmd *c.Command, args []string) {
	dev.MustFindCrowbar()
	res := make([]string, 0, 20)
	var build dev.Build
	var found bool
	if len(args) == 0 {
		build = dev.CurrentBuild()
	} else if len(args) == 1 {
		builds := dev.Builds()
		build, found = builds[args[0]]
		if !found {
			log.Fatalln("No such build %s", args[0])
		}
	}
	for name := range dev.BarclampsInBuild(build) {
		res = append(res, name)
	}
	sort.Strings(res)
	for _, name := range res {
		fmt.Println(name)
	}
}