docs: update zh-tw (#265)

Reviewed-on: https://gitea.com/gitea/docs/pulls/265
Reviewed-by: Lunny Xiao <[email protected]>
Co-authored-by: ifurther <[email protected]>
Co-committed-by: ifurther <[email protected]>
This commit is contained in:
ifurther
2025-09-03 21:00:35 +00:00
committed by techknowlogick
parent 908a27589d
commit cb462089e9
88 changed files with 3545 additions and 3423 deletions
@@ -8,24 +8,24 @@ aliases:
# 迁移接口
完整迁移功能在 Gitea 1.9.0 版本中引入。它定义了两个接口,用于支持从其他 Git 托管平台迁移存库数据到 Gitea,或者在将来将 Gitea 数据迁移到其他 Git 托管平台。
完整迁移功能在 Gitea 1.9.0 版本中引入。它定义了两个接口,用于支持从其他 Git 托管平台迁移存库数据到 Gitea,或者在将来将 Gitea 数据迁移到其他 Git 托管平台。
目前已实了从 GitHub、GitLab 和其他 Gitea 实例的迁移。
目前已实了从 GitHub、GitLab 和其他 Gitea 实例的迁移。
首先,Gitea 在包[modules/migration](https://github.com/go-gitea/gitea/tree/main/modules/migration)中定义了一些标准对象。它们是`Repository``Milestone``Release``ReleaseAsset``Label``Issue``Comment``PullRequest``Reaction``Review``ReviewComment`
## 下载器接口
要从新的 Git 托管平台迁移,需要行两个步骤的更新。
要从新的 Git 托管平台迁移,需要行两个步骤的更新。
-应该实现一个`Downloader`,用于获取存库信息。
-应该实现一个`DownloaderFactory`,用于检测 URL 是否匹配,并创建上述的`Downloader`
- 您需要在`init()`中通`RegisterDownloaderFactory`注册`DownloaderFactory`
-應該实現一个`Downloader`,用于获取存库信息。
-應該实現一个`DownloaderFactory`,用于检测 URL 是否匹配,並建立上述的`Downloader`
- 您需要在`init()`中通`RegisterDownloaderFactory`注册`DownloaderFactory`
您可以在[downloader.go](https://github.com/go-gitea/gitea/blob/main/modules/migration/downloader.go)中找到这些接口。
## 上传器接口
目前,只实`GiteaLocalUploader`,因此我们只能通此 Uploader 将下载的数据保存到本地的 Gitea 实例。目前不支持其他上传器。
目前,只实`GiteaLocalUploader`,因此我们只能通此 Uploader 将下载的数据保存到本地的 Gitea 实例。目前不支持其他上传器。
您可以在[uploader.go](https://github.com/go-gitea/gitea/blob/main/modules/migration/uploader.go)中找到这些接口。