File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1822,6 +1822,8 @@ dart run slang edit <type> <params...>
18221822To keep the order of the keys consistent, you can normalize the translations.
18231823They will follow the same order as the base locale.
18241824
1825+ As a side effect, this command also reformats the translation file/files.
1826+
18251827` ` ` sh
18261828dart run slang normalize [--locale=fr-FR]
18271829` ` `
Original file line number Diff line number Diff line change @@ -11,6 +11,8 @@ import 'package:slang/src/utils/log.dart' as log;
1111const _supportedFiles = [FileType .json, FileType .yaml];
1212
1313/// Normalizes the translation files according to the base locale.
14+ ///
15+ /// As a side effect, this command also reformats the translation file/files.
1416Future <void > runNormalize ({
1517 required SlangFileCollection fileCollection,
1618 required List <String > arguments,
@@ -40,10 +42,6 @@ Future<void> runNormalize({
4042 log.info ('Target: all locales' );
4143
4244 for (final locale in translationMap.getLocales ()) {
43- if (locale == fileCollection.config.baseLocale) {
44- continue ;
45- }
46-
4745 await _normalizeLocale (
4846 fileCollection: fileCollection,
4947 locale: locale,
You can’t perform that action at this time.
0 commit comments