Skip to content

Commit

Permalink
Update count.js
Browse files Browse the repository at this point in the history
  • Loading branch information
ourai authored Jul 29, 2024
1 parent 7f62d48 commit 26006aa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .knosys/scripts/command/pmc/count.js
Original file line number Diff line number Diff line change
Expand Up @@ -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))) {
Expand Down

0 comments on commit 26006aa

Please sign in to comment.