mirror of
https://github.com/taigrr/gico.git
synced 2026-04-02 03:09:07 -07:00
fix an error where the wait group never completes on uninitialized repo
This commit is contained in:
@@ -2,6 +2,7 @@ package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"os"
|
||||
"time"
|
||||
|
||||
git "github.com/go-git/go-git/v5"
|
||||
@@ -12,12 +13,16 @@ import (
|
||||
type Repo git.Repository
|
||||
|
||||
func main() {
|
||||
year := time.Now().Year() - 1
|
||||
year := time.Now().Year()
|
||||
authors := []string{"Groot"}
|
||||
mr, err := commits.GetMRRepos()
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
if len(mr) == 0 {
|
||||
fmt.Println("found no repos!")
|
||||
os.Exit(1)
|
||||
}
|
||||
gfreq, err := mr.FrequencyChan(year, authors)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
|
||||
Reference in New Issue
Block a user