// Code generated by go.wit.com/apps/autogenpb DO NOT EDIT. // go install go.wit.com/apps/autogenpb@latest // // This file was autogenerated with autogenpb: // autogenpb v0.5.27 Built on 2025/10/16 17:13:05 ( 52 m) // Theese sort.pb.go and marshal.pb.go files are autogenerated // The autogenpb sources have example .proto files with instructions // package gitpb import ( "sort" ) func (pb *Stats) SortCtime() { statMu.Lock() defer statMu.Unlock() sort.Sort(sortStatCtime(pb.Stats)) } // sort struct by Ctime type sortStatCtime []*Stat func (a sortStatCtime) Len() int { return len(a) } func (a sortStatCtime) Less(i, j int) bool { itime := a[i].Ctime.AsTime() jtime := a[j].Ctime.AsTime() return itime.Before(jtime) } func (a sortStatCtime) Swap(i, j int) { a[i], a[j] = a[j], a[i] }