1+ <?php
2+ /**
3+ * This is a configuration file for the [[\yii\console\controllers\MessageController]] console command.
4+ *
5+ * In order to update translations, run the following console command:
6+ * php yii message messages/config.php
7+ *
8+ * @see yii\console\controllers\MessageController
9+ */
10+ return [
11+ // string, required, root directory of all source files
12+ 'sourcePath ' => __DIR__ . DIRECTORY_SEPARATOR . '.. ' ,
13+ // array, required, list of language codes that the extracted messages
14+ // should be translated to. For example, ['zh-CN', 'de'].
15+ 'languages ' => ['en ' ],
16+ // string, the name of the function for translating messages.
17+ // Defaults to 'Yii::t'. This is used as a mark to find the messages to be
18+ // translated. You may use a string for single function name or an array for
19+ // multiple function names.
20+ 'translator ' => 'Yii::t ' ,
21+ // boolean, whether to sort messages by keys when merging new messages
22+ // with the existing ones. Defaults to false, which means the new (untranslated)
23+ // messages will be separated from the old (translated) ones.
24+ 'sort ' => true ,
25+ // boolean, whether to remove messages that no longer appear in the source code.
26+ // Defaults to false, which means each of these messages will be enclosed with a pair of '@@' marks.
27+ 'removeUnused ' => false ,
28+ // array, list of patterns that specify which files (not directories) should be processed.
29+ // If empty or not set, all files will be processed.
30+ // Please refer to "except" for details about the patterns.
31+ 'only ' => ['*.php ' ],
32+ // array, list of patterns that specify which files/directories should NOT be processed.
33+ // If empty or not set, all files/directories will be processed.
34+ // A path matches a pattern if it contains the pattern string at its end. For example,
35+ // '/a/b' will match all files and directories ending with '/a/b';
36+ // the '*.svn' will match all files and directories whose name ends with '.svn'.
37+ // and the '.svn' will match all files and directories named exactly '.svn'.
38+ // Note, the '/' characters in a pattern matches both '/' and '\'.
39+ // See helpers/FileHelper::findFiles() description for more details on pattern matching rules.
40+ // If a file/directory matches both a pattern in "only" and "except", it will NOT be processed.
41+ 'except ' => [
42+ '.svn ' ,
43+ '.git ' ,
44+ '.gitignore ' ,
45+ '.gitkeep ' ,
46+ '.hg ' ,
47+ '.hgignore ' ,
48+ '.hgkeep ' ,
49+ '/assets ' ,
50+ '/messages ' ,
51+ '/migrations ' ,
52+ '/tests ' ,
53+ '/runtime ' ,
54+ '/vendor ' ,
55+ '/web ' ,
56+ '/webstub ' ,
57+ ],
58+ // 'php' output format is for saving messages to php files.
59+ 'format ' => 'php ' ,
60+ // Root directory containing message translations.
61+ 'messagePath ' => __DIR__ ,
62+ // boolean, whether the message file should be overwritten with the merged messages
63+ 'overwrite ' => true ,
64+ // Message categories to ignore
65+ 'ignoreCategories ' => [
66+ 'yii '
67+ ]
68+ ];
0 commit comments