Skip to content

Commit a680011

Browse files
committed
enhance: use --since=@<unix_timestamp> instead of --since="yyyy/MM/dd HH:mm:ss"
Signed-off-by: leo <longshuang@msn.cn>
1 parent 99d973f commit a680011

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

‎src/Commands/QueryCurrentBranchCommitHashes.cs‎

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
using System;
2-
using System.Collections.Generic;
1+
using System.Collections.Generic;
32
using System.Diagnostics;
43
using System.Threading.Tasks;
54

@@ -9,10 +8,9 @@ public class QueryCurrentBranchCommitHashes : Command
98
{
109
public QueryCurrentBranchCommitHashes(string repo, ulong sinceTimestamp)
1110
{
12-
var since = DateTime.UnixEpoch.AddSeconds(sinceTimestamp).ToLocalTime().ToString("yyyy/MM/dd HH:mm:ss");
1311
WorkingDirectory = repo;
1412
Context = repo;
15-
Args = $"log --since={since.Quoted()} --format=%H";
13+
Args = $"log --since=@{sinceTimestamp} --format=%H";
1614
}
1715

1816
public async Task<HashSet<string>> GetResultAsync()

0 commit comments

Comments
 (0)