Skip to content

Commit 67b0195

Browse files
committed
fix multiple commit order issue
Signed-off-by: shmck <[email protected]>
1 parent 791212e commit 67b0195

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/utils/commits.ts

+4-2
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ export async function getCommits({
7373
commits[position] = [commit.hash];
7474
} else {
7575
// add to the list
76-
commits[position].push(commit.hash);
76+
commits[position].unshift(commit.hash);
7777
}
7878
positions.unshift(position);
7979
} else {
@@ -84,7 +84,7 @@ export async function getCommits({
8484
commits.INIT = [commit.hash];
8585
} else {
8686
// add to the list
87-
commits.INIT.push(commit.hash);
87+
commits.INIT.unshift(commit.hash);
8888
}
8989
positions.unshift("INIT");
9090
}
@@ -101,5 +101,7 @@ export async function getCommits({
101101
await rmdir(tmpDir, { recursive: true });
102102
}
103103

104+
console.log(commits);
105+
104106
return commits;
105107
}

0 commit comments

Comments
 (0)