fix: ganti --after/--before ke --since/--until dengan waktu eksplisit

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
sas.fajri
2026-05-28 16:59:59 +07:00
parent f27a8abf70
commit 2bd1771c2b
3 changed files with 7 additions and 11 deletions

View File

@@ -151,12 +151,11 @@ def upload_timesheet(session_id: str, entry: dict, user_id: int) -> int:
# ── Git ───────────────────────────────────────────────────────────────────────
def get_commits_today(repo_path: str, author: str, today: str) -> list[dict]:
until = (date.fromisoformat(today) + timedelta(days=1)).isoformat()
cmd = [
"git", "-C", repo_path, "log",
f"--author={author}",
f"--after={today}",
f"--before={until}",
f"--since={today} 00:00:00",
f"--until={today} 23:59:59",
"--format=%h|%ad|%s",
"--date=format:%Y-%m-%d %H:%M",
]