Skip to content

Commit

Permalink
feat: set locale for 2024.2 EAP
Browse files Browse the repository at this point in the history
  • Loading branch information
bluelovers committed Jul 2, 2024
1 parent c549584 commit 244f82d
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/meta.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ export function updateMeta(content_new: string)
obj.id = 'com.intellij.zh-tw';
obj.name = `Chinese (Traditional) Language Pack / 繁體中文語言包`;

// from 2024.2 EAP
obj.locale = 'zh-TW';

obj.root['vendor'] = {
'@url': 'https://github.com/bluelovers/idea-l10n-zht',
'#': 'bluelovers',
Expand Down
11 changes: 11 additions & 0 deletions lib/util/xml/plugin-xml.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,17 @@ export class PluginXml extends XMLSerialized
this.root['version'] = value
}

get locale()
{
return this.root['locale'] as string
}

set locale(value: string)
{
this.root['locale'] = 'zh-TW';
this.root['extensions']['languageBundle']['@locale'] = 'zh-TW';
}

get name()
{
return this.root['name'] as string
Expand Down

0 comments on commit 244f82d

Please sign in to comment.