This repository was archived by the owner on Jul 16, 2020. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +19
-3
lines changed Expand file tree Collapse file tree 3 files changed +19
-3
lines changed Original file line number Diff line number Diff line change 12
12
],
13
13
"require" : {
14
14
"php" : " >=5.5.0" ,
15
- "laravel/framework" : " ~5.1"
15
+ "illuminate/console" : " ~5.1.0|~5.2.0|~5.3.0" ,
16
+ "illuminate/support" : " ~5.1.0|~5.2.0|~5.3.0"
16
17
},
17
18
"require-dev" : {
18
19
"phpunit/phpunit" : " ~4.7"
Original file line number Diff line number Diff line change @@ -42,10 +42,21 @@ private function allocateLocaleArray($path)
42
42
43
43
$ dir = new DirectoryIterator ($ path );
44
44
foreach ($ dir as $ fileinfo ) {
45
- if (!$ fileinfo ->isDot ()) {
45
+ // Do not mess with dotfiles at all.
46
+ if ($ fileinfo ->isDot ()) {
47
+ continue ;
48
+ }
49
+
50
+ // Check if the "file" is a subdirectory which has to be scanned.
51
+ if ($ fileinfo ->isDir ()) {
52
+ // Recursivley iterate through subdirs, until everything was allocated.
53
+ $ data [$ fileinfo ->getFilename ()] =
54
+ $ this ->allocateLocaleArray ($ path . '/ ' . $ fileinfo ->getFilename ());
55
+ } else {
46
56
$ noExt = $ this ->removeExtension ($ fileinfo ->getFilename ());
57
+
47
58
// Ignore non *.php files (ex.: .gitignore, vim swap files etc.)
48
- if (pathinfo ($ fileinfo ->getFileName ())[ ' extension ' ] !== 'php ' ) {
59
+ if (pathinfo ($ fileinfo ->getFileName (), PATHINFO_EXTENSION ) !== 'php ' ) {
49
60
continue ;
50
61
}
51
62
$ tmp = include ($ path . '/ ' . $ fileinfo ->getFilename ());
Original file line number Diff line number Diff line change @@ -30,6 +30,10 @@ public function boot()
30
30
__DIR__ .'/config/vue-i18n-generator.php ' => config_path ('vue-i18n-generator.php ' ),
31
31
]);
32
32
33
+ $ this ->mergeConfigFrom (
34
+ __DIR__ .'/config/vue-i18n-generator.php ' ,
35
+ 'vue-i18n-generator '
36
+ );
33
37
}
34
38
35
39
/**
You can’t perform that action at this time.
0 commit comments