20 lines
425 B
Go
20 lines
425 B
Go
package main
|
|
|
|
import (
|
|
"strings"
|
|
|
|
"go.wit.com/lib/protobuf/gitpb"
|
|
"go.wit.com/log"
|
|
)
|
|
|
|
func purgeNotes(repo *gitpb.Repo) error {
|
|
result := repo.Run([]string{"git", "notes", "list"})
|
|
for _, line := range result.Stdout {
|
|
parts := strings.Fields(line)
|
|
log.Info("line:", line, "part", parts[1])
|
|
blah := repo.Run([]string{"git", "notes", "remove", parts[1]})
|
|
log.Info(strings.Join(blah.Stdout, "\n"))
|
|
}
|
|
return nil
|
|
}
|