aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Rutger Broekhoff2023-12-30 15:41:43 +0100
committerLibravatar Rutger Broekhoff2023-12-30 15:41:43 +0100
commita8726abf0b61327190204446974c073d8a64f102 (patch)
treea4011619c24ad1f82f5bda222983f38abd820da0
parent6e53cbb10cf8635e9454af2bd1a11e1d12eca25f (diff)
downloadgitolfs3-a8726abf0b61327190204446974c073d8a64f102.tar.gz
gitolfs3-a8726abf0b61327190204446974c073d8a64f102.zip
Properly format request timestamp
-rw-r--r--cmd/git-lfs-authenticate/main.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd/git-lfs-authenticate/main.go b/cmd/git-lfs-authenticate/main.go
index 05de4c6..f48fe5c 100644
--- a/cmd/git-lfs-authenticate/main.go
+++ b/cmd/git-lfs-authenticate/main.go
@@ -37,7 +37,8 @@ func (l *logger) writer() io.WriteCloser {
37 l.m.Lock() 37 l.m.Lock()
38 if l.wc.Load() == nil { 38 if l.wc.Load() == nil {
39 os.MkdirAll(".gitolfs3/logs/", 0o700) // Mode: drwx------ 39 os.MkdirAll(".gitolfs3/logs/", 0o700) // Mode: drwx------
40 path := fmt.Sprintf(".gitolfs3/logs/gitolfs3-%s-%s.log", l.time, l.reqID) 40 ts := l.time.Format("2006-01-02")
41 path := fmt.Sprintf(".gitolfs3/logs/gitolfs3-%s-%s.log", ts, l.reqID)
41 var err error 42 var err error
42 if w, err = os.Create(path); err == nil { 43 if w, err = os.Create(path); err == nil {
43 l.wc.Store(w) 44 l.wc.Store(w)