Compare commits

..

4 Commits

Author SHA1 Message Date
5734699b87
попытка настроить время материала
All checks were successful
continuous-integration/drone/push Build is passing
2024-09-07 10:43:18 +03:00
4ce334a081
попытка настроить время материала
All checks were successful
continuous-integration/drone/push Build is passing
2024-09-07 10:35:34 +03:00
9c070afde7
Упрощение сборки 2024-09-07 10:33:41 +03:00
95ab20826e
попытка настроить время материала 2024-09-07 10:33:41 +03:00

View File

@ -58,17 +58,18 @@ export const CreatedModifiedDate: QuartzTransformerPlugin<Partial<Options>> = (u
// Get a reference to the main git repo.
// It's either the same as the workdir,
// or 1+ level higher in case of a submodule/subtree setup
repo = Repository.discover(file.cwd)
repo = Repository.discover("/usr/src/app/content")
console.log(chalk.green(`Git repository found at: ${repo.path()}`));
}
try {
modified ||= await repo.getFileLatestModifiedDateAsync(file.data.filePath!)
const status = await repo.getStatusAsync();
modified ||= await repo.getFileLatestModifiedDateAsync(fullFp!);
console.log(chalk.green(`Git repository found at: ${status.tracked.includes(fullFp)}`));
} catch {
console.log(
chalk.yellow(
`\nWarning: ${file.data
.filePath!} isn't yet tracked by git, last modification date is not available for this file`,
`\nWarning: ${fullFp!} isn't yet tracked by git, last modification date is not available for this file`,
),
)
}