mirror of
https://github.com/jackyzha0/quartz.git
synced 2025-12-19 10:54:06 -06:00
fix(lastmod): fix where created may be later than modified when using git modified date
This commit is contained in:
parent
ebff6617bb
commit
37c57a2745
@ -80,6 +80,7 @@ export const CreatedModifiedDate: QuartzTransformerPlugin<Partial<Options>> = (u
|
|||||||
} else if (source === "git" && repo) {
|
} else if (source === "git" && repo) {
|
||||||
try {
|
try {
|
||||||
const relativePath = path.relative(repositoryWorkdir, fullFp)
|
const relativePath = path.relative(repositoryWorkdir, fullFp)
|
||||||
|
created ||= await repo.getFileLatestModifiedDateAsync(relativePath)
|
||||||
modified ||= await repo.getFileLatestModifiedDateAsync(relativePath)
|
modified ||= await repo.getFileLatestModifiedDateAsync(relativePath)
|
||||||
} catch {
|
} catch {
|
||||||
console.log(
|
console.log(
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user