summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doPatch.go2
-rw-r--r--doStats.go6
2 files changed, 6 insertions, 2 deletions
diff --git a/doPatch.go b/doPatch.go
index 3aa07e7..e0f697e 100644
--- a/doPatch.go
+++ b/doPatch.go
@@ -40,7 +40,7 @@ func doPatch() (string, error) {
me.curpatches = forgepb.NewPatches()
me.curpatches.Filename = config.Get("curpatches")
if me.curpatches.Filename == "" {
- panic("config failed")
+ panic("config failed. no 'curpatches' set in ~/.config/forge/config.text")
}
if err := me.curpatches.Load(); err != nil {
me.curpatches.Save()
diff --git a/doStats.go b/doStats.go
index 09ec0c7..f379562 100644
--- a/doStats.go
+++ b/doStats.go
@@ -127,10 +127,13 @@ func makeFmts() string {
return "--format=" + strings.Join(all, standardSeperator)
}
+// the correct syntax for
+// git log -n 8 --format=%H%00%ae%00%as%00%s origin/HEAD
func last100(r *gitpb.Repo, pb *gitpb.Stats) (int, error) {
var allerr error
var counter int
- cmd := []string{"git", "log", "-n", "100", makeFmts(), "origin/" + r.GetMasterBranchName()}
+ // cmd := []string{"git", "log", "-n", "100", makeFmts(), "origin/" + r.GetMasterBranchName()}
+ cmd := []string{"git", "log", "-n", "100", makeFmts(), "origin/HEAD"}
if config.If("stats") {
log.Info("Run:", cmd)
}
@@ -153,6 +156,7 @@ func last100(r *gitpb.Repo, pb *gitpb.Stats) (int, error) {
allerr = errors.Join(allerr, err)
astat.Ctime = timestamppb.New(*ctime)
astat.Subject = parts[4]
+ astat.Type = gitpb.Stat_REMOTE
pb.Append(astat)
}
return counter, allerr