MCPcopy Create free account
hub / github.com/TeleBoxOrg/TeleBox_Plugins / getCommitWindow

Function getCommitWindow

scripts/commit-summary.js:31–39  ·  view source on GitHub ↗
(date)

Source from the content-addressed store, hash-verified

29 return `${yyyy}-${MM}-${dd}T${hh}:${mm}:${ss}${sign}${offH}:${offM}`;
30};
31const getCommitWindow = (date) => {
32 const end = new Date(`${date}T23:00:00${LOCAL_TZ_OFFSET}`);
33 const start = new Date(end.getTime() - 24 * 60 * 60 * 1000);
34
35 return {
36 since: formatDateTimeWithOffset(start, LOCAL_TZ_OFFSET_MINUTES),
37 until: formatDateTimeWithOffset(end, LOCAL_TZ_OFFSET_MINUTES)
38 };
39};
40const TARGET_DATE = process.env.TARGET_DATE || formatDateInTimeZone(new Date(), LOCAL_TZ);
41const CHECKOUT_SUCCESS = process.env.CHECKOUT_SUCCESS === 'true';
42

Callers 1

getCommitsForDateFunction · 0.85

Calls 1

formatDateTimeWithOffsetFunction · 0.85

Tested by

no test coverage detected