From c53da5a9a1da1b29db24d4e1ce2b294514d99ac2 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Tue, 17 Dec 2024 00:00:49 -0600 Subject: smarter and faster mtime logic --- shell.go | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'shell.go') diff --git a/shell.go b/shell.go index efb682d..3d15eee 100644 --- a/shell.go +++ b/shell.go @@ -6,7 +6,6 @@ import ( "os" "path/filepath" "strings" - "time" "github.com/go-cmd/cmd" "go.wit.com/lib/gui/shell" @@ -109,13 +108,3 @@ func (repo *Repo) IsDirectory() bool { } return info.IsDir() } - -func (repo *Repo) mtime(filename string) (time.Time, error) { - pathf := filepath.Join(repo.FullPath, filename) - statf, err := os.Stat(pathf) - if err == nil { - return statf.ModTime(), nil - } - log.Log(GITPB, "mtime() os.Stat() error", pathf, err) - return time.Now(), err -} -- cgit v1.2.3