[Loc] cleanup and update localization build filters. (#24114)

* cleaned up build files

* made small adjustments to locfunc
This commit is contained in:
Alex Ma
2023-08-10 09:32:13 -07:00
committed by GitHub
parent 2d1be1b330
commit 6acc9f4a75
4 changed files with 49 additions and 27 deletions

View File

@@ -163,10 +163,11 @@ const extensionsFilter = filter([
'**/azurecore.xlf', '**/azurecore.xlf',
'**/azuremonitor.xlf', '**/azuremonitor.xlf',
'**/cms.xlf', '**/cms.xlf',
'**/context-monitor.xlf',
'**/dacpac.xlf', '**/dacpac.xlf',
'**/data-workspace.xlf',
'**/datavirtualization.xlf', '**/datavirtualization.xlf',
'**/git.xlf', '**/git.xlf',
'**/data-workspace.xlf',
'**/import.xlf', '**/import.xlf',
'**/kusto.xlf', '**/kusto.xlf',
'**/machine-learning.xlf', '**/machine-learning.xlf',
@@ -174,14 +175,14 @@ const extensionsFilter = filter([
'**/notebook.xlf', '**/notebook.xlf',
'**/profiler.xlf', '**/profiler.xlf',
'**/query-history.xlf', '**/query-history.xlf',
'**/query-store.xlf',
'**/resource-deployment.xlf', '**/resource-deployment.xlf',
'**/schema-compare.xlf', '**/schema-compare.xlf',
'**/server-report.xlf', '**/server-report.xlf',
'**/sql-assessment.xlf', '**/sql-assessment.xlf',
'**/sql-bindings.xlf', '**/sql-bindings.xlf',
'**/sql-database-projects.xlf', '**/sql-database-projects.xlf',
'**/sql-migration.xlf', '**/sql-migration.xlf'
'**/xml-language-features.xlf'
]); ]);
// Copy ADS extension XLFs into English resource folder. // Copy ADS extension XLFs into English resource folder.

File diff suppressed because one or more lines are too long

View File

@@ -154,12 +154,13 @@ export function modifyI18nPackFiles(existingTranslationFolder: string, resulting
for (let extension in extensionsPacks) { for (let extension in extensionsPacks) {
const translatedExtFile = i18n.createI18nFile(`extensions/${extension}`, extensionsPacks[extension]); const translatedExtFile = i18n.createI18nFile(`extensions/${extension}`, extensionsPacks[extension]);
this.queue(translatedExtFile); this.queue(translatedExtFile);
let adsExtensionId = 'Microsoft.' + extension;
// exclude altered vscode extensions from having a new path even if we provide a new I18n file. // Exclude altered vscode extensions from having a new id, as it's identified this way in ADS.
if (alteredVSCodeExtensions.indexOf(extension) === -1) { // We will use ADS's i18n file for actual translations.
let adsExtensionId = 'Microsoft.' + extension; if (alteredVSCodeExtensions.indexOf(extension) !== -1) {
resultingTranslationPaths.push({ id: adsExtensionId, resourceName: `extensions/${extension}.i18n.json` }); adsExtensionId = 'vscode.' + extension;
} }
resultingTranslationPaths.push({ id: adsExtensionId, resourceName: `extensions/${extension}.i18n.json` });
} }
this.queue(null); this.queue(null);
}) })
@@ -186,12 +187,12 @@ const VSCODEExtensions = [
"builtin-notebook-renderers", // notebook renderers "builtin-notebook-renderers", // notebook renderers
"configuration-editing", "configuration-editing",
"docker", "docker",
"git",
"git-base", "git-base",
"github", "github",
"github-authentication", "github-authentication",
"image-preview", "image-preview",
"ipynb", "ipynb",
"javascript",
"json", "json",
"json-language-features", "json-language-features",
"markdown", // markdown-basics "markdown", // markdown-basics

View File

@@ -38,12 +38,24 @@
"LclFile": "resources\\localization\\LCL\\{Lang}\\azurecore.xlf.lcl", "LclFile": "resources\\localization\\LCL\\{Lang}\\azurecore.xlf.lcl",
"CopyOption": "LangIDOnPath", "CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf" "OutputPath": "resources\\xlf"
},
{
"SourceFile": "resources\\xlf\\en\\azuremonitor.xlf",
"LclFile": "resources\\localization\\LCL\\{Lang}\\azuremonitor.xlf.lcl",
"CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf"
}, },
{ {
"SourceFile": "resources\\xlf\\en\\cms.xlf", "SourceFile": "resources\\xlf\\en\\cms.xlf",
"LclFile": "resources\\localization\\LCL\\{Lang}\\cms.xlf.lcl", "LclFile": "resources\\localization\\LCL\\{Lang}\\cms.xlf.lcl",
"CopyOption": "LangIDOnPath", "CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf" "OutputPath": "resources\\xlf"
},
{
"SourceFile": "resources\\xlf\\en\\context-builder.xlf",
"LclFile": "resources\\localization\\LCL\\{Lang}\\context-builder.xlf.lcl",
"CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf"
}, },
{ {
"SourceFile": "resources\\xlf\\en\\dacpac.xlf", "SourceFile": "resources\\xlf\\en\\dacpac.xlf",
@@ -56,6 +68,12 @@
"LclFile": "resources\\localization\\LCL\\{Lang}\\data-workspace.xlf.lcl", "LclFile": "resources\\localization\\LCL\\{Lang}\\data-workspace.xlf.lcl",
"CopyOption": "LangIDOnPath", "CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf" "OutputPath": "resources\\xlf"
},
{
"SourceFile": "resources\\xlf\\en\\datavirtualization.xlf",
"LclFile": "resources\\localization\\LCL\\{Lang}\\datavirtualization.xlf.lcl",
"CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf"
}, },
{ {
"SourceFile": "resources\\xlf\\en\\git.xlf", "SourceFile": "resources\\xlf\\en\\git.xlf",
@@ -104,6 +122,12 @@
"LclFile": "resources\\localization\\LCL\\{Lang}\\query-history.xlf.lcl", "LclFile": "resources\\localization\\LCL\\{Lang}\\query-history.xlf.lcl",
"CopyOption": "LangIDOnPath", "CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf" "OutputPath": "resources\\xlf"
},
{
"SourceFile": "resources\\xlf\\en\\query-store.xlf",
"LclFile": "resources\\localization\\LCL\\{Lang}\\query-store.xlf.lcl",
"CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf"
}, },
{ {
"SourceFile": "resources\\xlf\\en\\resource-deployment.xlf", "SourceFile": "resources\\xlf\\en\\resource-deployment.xlf",
@@ -128,6 +152,12 @@
"LclFile": "resources\\localization\\LCL\\{Lang}\\sql-assessment.xlf.lcl", "LclFile": "resources\\localization\\LCL\\{Lang}\\sql-assessment.xlf.lcl",
"CopyOption": "LangIDOnPath", "CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf" "OutputPath": "resources\\xlf"
},
{
"SourceFile": "resources\\xlf\\en\\sql-bindings.xlf",
"LclFile": "resources\\localization\\LCL\\{Lang}\\sql-bindings.xlf.lcl",
"CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf"
}, },
{ {
"SourceFile": "resources\\xlf\\en\\sql-database-projects.xlf", "SourceFile": "resources\\xlf\\en\\sql-database-projects.xlf",
@@ -140,18 +170,6 @@
"LclFile": "resources\\localization\\LCL\\{Lang}\\sql-migration.xlf.lcl", "LclFile": "resources\\localization\\LCL\\{Lang}\\sql-migration.xlf.lcl",
"CopyOption": "LangIDOnPath", "CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf" "OutputPath": "resources\\xlf"
},
{
"SourceFile": "resources\\xlf\\en\\sql.xlf",
"LclFile": "resources\\localization\\LCL\\{Lang}\\sql.xlf.lcl",
"CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf"
},
{
"SourceFile": "resources\\xlf\\en\\xml-language-features.xlf",
"LclFile": "resources\\localization\\LCL\\{Lang}\\xml-language-features.xlf.lcl",
"CopyOption": "LangIDOnPath",
"OutputPath": "resources\\xlf"
} }
] ]
} }