mirror of
https://gitea.com/gitea/docs.git
synced 2026-11-04 09:15:33 +00:00
refactor: rename i18n/*/docusaurus-plugin-content-docs to i18n/*/docs (#588)
Drops the leftover docusaurus name from the translated content directories.
- git mv i18n/{en-us,zh-cn,zh-tw}/docusaurus-plugin-content-docs -> i18n/{locale}/docs (pure renames, content unchanged)
- update the paths in packages/content-loader/src/products.ts, scripts/cut-version.mjs and sites/docs/README.md
current.json / version-*.json keep their names and stay beside the content.
Verified: pnpm build succeeds, 6690 pages built.
<!-- cloudflare-preview --> Preview: https://pr-588.docs-gitea-com.pages.dev
Reviewed-on: https://gitea.com/gitea/docs/pulls/588
Reviewed-by: Zettat123 <[email protected]>
This commit is contained in:
@@ -157,11 +157,11 @@ const variables: Record<string, VersionVariables> = {
|
||||
},
|
||||
};
|
||||
|
||||
/** Localized content of the gitea docs, as laid out by the docusaurus tree. */
|
||||
/** Localized content of the gitea docs, as laid out under `i18n/<locale>/docs`. */
|
||||
function docsSources(version: 'current' | string): VersionDef['sources'] {
|
||||
const dir = version === 'current' ? 'docs' : `versioned_docs/version-${version}`;
|
||||
const i18nDir = (locale: LocaleId) =>
|
||||
`i18n/${locale}/docusaurus-plugin-content-docs/${
|
||||
`i18n/${locale}/docs/${
|
||||
version === 'current' ? 'current' : `version-${version}`
|
||||
}`;
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user