From 26006aac70753624f098e3a2c5e9798a1fd10146 Mon Sep 17 00:00:00 2001 From: "Ourai L." Date: Mon, 29 Jul 2024 19:09:29 +0800 Subject: [PATCH] Update count.js --- .knosys/scripts/command/pmc/count.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.knosys/scripts/command/pmc/count.js b/.knosys/scripts/command/pmc/count.js index ba1c74628..c4d655f16 100644 --- a/.knosys/scripts/command/pmc/count.js +++ b/.knosys/scripts/command/pmc/count.js @@ -52,12 +52,12 @@ function resolveTask(taskMetadata, memberDirPath, memberDirName, taskNum) { const paths = [`${targetPath}/readme.md`, `${targetPath}/README.md`, targetPath]; for (let i = 0; i < paths.length; i++) { - const modifiedAt = execGit(`git log -1 --pretty=format:"%cd" -- ${paths[i]}`); + const modifiedAt = execGit(`git log -1 --follow --pretty=format:"%cd" -- ${paths[i]}`); if (modifiedAt) { task.modifiedAt = dayjs(modifiedAt).format('YYYY-MM-DD HH:mm:ss ZZ'); - console.log(`[KNOSYS_INFO] \`${paths[i]}\` full message`, execGit(`git log -1 -- ${paths[i]}`)); + // console.log(`[KNOSYS_INFO] \`${paths[i]}\` full message`, execGit(`git log -1 -- ${paths[i]}`)); console.log(`[KNOSYS_INFO] \`${paths[i]}\` modified at`, modifiedAt, task.modifiedAt); if (studentRewardPatches[memberDirName] && studentRewardPatches[memberDirName][taskDirName] === true || dayjs(task.modifiedAt).isBefore(dayjs(rewardDeadline))) {