mirror of
https://github.com/hanxi/xiaomusic.git
synced 2025-12-13 15:58:13 +08:00
docs: 修改链接
This commit is contained in:
@@ -126,12 +126,12 @@ function clearDirectory(dir: string) {
|
||||
}
|
||||
}
|
||||
|
||||
function copyReadmeFile(source: string, destination: string) {
|
||||
function copyFile(source: string, destination: string) {
|
||||
if (fs.existsSync(source)) {
|
||||
fs.copyFileSync(source, destination);
|
||||
console.log(`Copied README.md from ${source} to ${destination}`);
|
||||
console.log(`Copied file from ${source} to ${destination}`);
|
||||
} else {
|
||||
console.error(`README.md not found at ${source}`);
|
||||
console.error(`file not found at ${source}`);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -176,7 +176,12 @@ export default function GitHubIssuesPlugin(options: GitHubIssuesPluginOptions):
|
||||
// 拷贝 ../README.md 文件到当前目录
|
||||
const readmeSource = path.join(process.cwd(), '../README.md');
|
||||
const readmeDestination = path.join(docsDir, 'index.md');
|
||||
copyReadmeFile(readmeSource, readmeDestination);
|
||||
copyFile(readmeSource, readmeDestination);
|
||||
|
||||
// 拷贝 ../CHANGELOG.md 文件到当前目录
|
||||
const changelogSource = path.join(process.cwd(), '../CHANGELOG.md');
|
||||
const changelogDestination = path.join(docsDir, 'changelog.md');
|
||||
copyFile(changelogSource, changelogDestination);
|
||||
|
||||
for (const issue of issues) {
|
||||
// 仅处理包含 "文档" 标签的 issue
|
||||
|
||||
Reference in New Issue
Block a user