├── .gitignore ├── .travis.yml ├── LICENSE ├── Makefile ├── README.md ├── composer.json ├── composer.lock ├── phpunit.xml ├── src ├── Commands │ └── GenerateInclude.php ├── Generator.php ├── GeneratorProvider.php └── config │ └── vue-i18n-generator.php └── tests └── GenerateTest.php /.gitignore: -------------------------------------------------------------------------------- 1 | /vendor 2 | /.idea -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: php 2 | 3 | os: 4 | # - windows 5 | - linux 6 | 7 | php: 8 | - 5.6 9 | - 7.3 10 | 11 | script: 12 | - vendor/phpunit/phpunit/phpunit 13 | 14 | before_install: 15 | - composer self-update 16 | 17 | install: 18 | - composer install 19 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2015-2016 Martin Lindhe 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | test: 2 | vendor/phpunit/phpunit/phpunit 3 | 4 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## About 2 | 3 | **NO LONGER MAINTAINED** 4 | 5 | 6 | [![Build Status](https://travis-ci.org/martinlindhe/laravel-vue-i18n-generator.png?branch=master)](https://travis-ci.org/martinlindhe/laravel-vue-i18n-generator) 7 | 8 | 9 | Laravel 5 package that allows you to share your [Laravel localizations](https://laravel.com/docs/5.8/localization) 10 | with your [vue](http://vuejs.org/) front-end, using [vue-i18n](https://github.com/kazupon/vue-i18n) or [vuex-i18n](https://github.com/dkfbasel/vuex-i18n). 11 | 12 | 13 | ## Laravel 5.7 notice! 14 | 15 | Configuration paths have changed in Laravel 5.7, in order for this package to function properly you need to configure correct paths for jsPath and jsFile in your `config\vue-i18n-generator.php`. 16 | 17 | 18 | ## Install the package 19 | 20 | In your project: 21 | ```composer require martinlindhe/laravel-vue-i18n-generator --dev``` 22 | 23 | ### For Laravel 5.4 and below: 24 | For older versions of the framework: 25 | 26 | Register the service provider in ```config/app.php``` 27 | 28 | ```php 29 | MartinLindhe\VueInternationalizationGenerator\GeneratorProvider::class, 30 | ``` 31 | 32 | Next, publish the package default config: 33 | 34 | ``` 35 | php artisan vendor:publish --provider="MartinLindhe\VueInternationalizationGenerator\GeneratorProvider" 36 | ``` 37 | 38 | ## Using vue-i18n 39 | 40 | Next, you need to install one out of two supported VueJs i18n libraries. We support [vue-i18n](https://github.com/kazupon/vue-i18n) as default library. Beside that we also support [vuex-i18n](https://github.com/dkfbasel/vuex-i18n). 41 | 42 | When you go with the default option, you only need to install the library through your favorite package manager. 43 | ### vue-i18n 44 | ``` 45 | npm i --save vue-i18n 46 | ``` 47 | 48 | ``` 49 | yarn add vue-i18n 50 | ``` 51 | 52 | Then generate the include file with 53 | ``` 54 | php artisan vue-i18n:generate 55 | ``` 56 | 57 | Assuming you are using a recent version of vue-i18n (>=6.x), adjust your vue app with something like: 58 | ```js 59 | import Vue from 'vue'; 60 | import VueInternationalization from 'vue-i18n'; 61 | import Locale from './vue-i18n-locales.generated'; 62 | 63 | Vue.use(VueInternationalization); 64 | 65 | const lang = document.documentElement.lang.substr(0, 2); 66 | // or however you determine your current app locale 67 | 68 | const i18n = new VueInternationalization({ 69 | locale: lang, 70 | messages: Locale 71 | }); 72 | 73 | const app = new Vue({ 74 | el: '#app', 75 | i18n, 76 | components: { 77 | ... 78 | } 79 | } 80 | ``` 81 | 82 | For older vue-i18n (5.x), the initialization looks something like: 83 | ```js 84 | import Vue from 'vue'; 85 | import VueInternationalization from 'vue-i18n'; 86 | import Locales from './vue-i18n-locales.generated.js'; 87 | 88 | Vue.use(VueInternationalization); 89 | 90 | Vue.config.lang = 'en'; 91 | 92 | Object.keys(Locales).forEach(function (lang) { 93 | Vue.locale(lang, Locales[lang]) 94 | }); 95 | 96 | ... 97 | ``` 98 | 99 | 100 | 101 | 102 | ## Using vuex-i18n 103 | 104 | ### vuex-i18n 105 | ``` 106 | npm i --save vuex-i18n 107 | ``` 108 | 109 | ``` 110 | yarn add vuex-i18n vuex 111 | ``` 112 | 113 | Next, open `config/vue-i18n-generator.php` and do the following changes: 114 | 115 | ```diff 116 | - 'i18nLib' => 'vue-i18n', 117 | + 'i18nLib' => 'vuex-i18n', 118 | ``` 119 | 120 | Then generate the include file with 121 | ``` 122 | php artisan vue-i18n:generate 123 | ``` 124 | 125 | Assuming you are using a recent version of vuex-i18n, adjust your vue app with something like: 126 | ```js 127 | import Vuex from 'vuex'; 128 | import vuexI18n from 'vuex-i18n'; 129 | import Locales from './vue-i18n-locales.generated.js'; 130 | 131 | const store = new Vuex.Store(); 132 | 133 | Vue.use(vuexI18n.plugin, store); 134 | 135 | Vue.i18n.add('en', Locales.en); 136 | Vue.i18n.add('de', Locales.de); 137 | 138 | // set the start locale to use 139 | Vue.i18n.set(Spark.locale); 140 | 141 | require('./components/bootstrap'); 142 | 143 | var app = new Vue({ 144 | store, 145 | mixins: [require('spark')] 146 | }); 147 | ``` 148 | 149 | ## Output Formats 150 | 151 | You can specify the output formats from `es6`, `umd`, or `json` with the `--format` option. (defaults to `es6`) 152 | 153 | ``` 154 | php artisan vue-i18n:generate --format {es6,umd,json} 155 | ``` 156 | 157 | ### Use case example for UMD module 158 | 159 | ``` 160 | php artisan vue-i18n:generate --format umd 161 | ``` 162 | An UMD module can be imported into the browser, build system, node and etc. 163 | 164 | Now you can include the generated script in the browser as a normal script and reference it with window.vuei18nLocales. 165 | ```vue 166 | 167 | 168 | // in your js 169 | Vue.use(VueI18n) 170 | Vue.config.lang = Laravel.language 171 | Object.keys(window.vuei18nLocales).forEach(function (lang) { 172 | Vue.locale(lang, window.vuei18nLocales[lang]) 173 | }) 174 | ``` 175 | You can still require/import it in your build system as stated above. 176 | 177 | One advantage of doing things like this is you are not obligated to do a build of your javascript each time a the translation files get changed/saved. A good example is if you have a backend that can read and write to your translation files (like Backpack). You can listen to a save event there and call vue-i18n-generator. 178 | 179 | ## Generating Multiple Files 180 | 181 | Sometimes you may want to generate multiple files as you want to make use of lazy loading. As such, you can specify that the generator produces multiple files within the destination directory. 182 | 183 | There are two options: 184 | 1. One file per laravel module language file using switch ```--multi``` 185 | 2. One file per locale using switch ```--multi-locales``` 186 | 187 | ``` 188 | php artisan vue-i18n:generate --multi{-locales} 189 | ``` 190 | 191 | ## Parameters 192 | 193 | The generator adjusts the strings in order to work with vue-i18n's named formatting, 194 | so you can reuse your Laravel translations with parameters. 195 | 196 | resource/lang/message.php: 197 | ```php 198 | return [ 199 | 'hello' => 'Hello :name', 200 | ]; 201 | ``` 202 | 203 | in vue-i18n-locales.generated.js: 204 | ```js 205 | ... 206 | "hello": "Hello {name}", 207 | ... 208 | ``` 209 | 210 | Blade template: 211 | ```php 212 |
213 |

{{ trans('message.hello', ['name' => 'visitor']) }}

214 |
215 | ``` 216 | 217 | Vue template: 218 | ```js 219 |
220 |

{{ $t('message.hello', {name: 'visitor'}) }}

221 |
222 | ``` 223 | 224 | 225 | ## Notices 226 | 227 | - The generated file is an ES6 module. 228 | 229 | The more sophisticated pluralization localization as described [here](https://laravel.com/docs/5.5/localization#pluralization) is not supported since neither vue-i18n or vuex-i18n support this. 230 | 231 | # License 232 | 233 | Under [MIT](LICENSE) 234 | -------------------------------------------------------------------------------- /composer.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "martinlindhe/laravel-vue-i18n-generator", 3 | "license": "MIT", 4 | "description": "Generates a vue-i18n compatible include file from your Laravel translations.", 5 | "keywords": ["laravel","vue-i18n"], 6 | "homepage": "http://github.com/martinlindhe/laravel-vue-i18n-generator", 7 | "authors": [ 8 | { 9 | "name": "Martin Lindhe", 10 | "email": "martin@ubique.se" 11 | } 12 | ], 13 | "require": { 14 | "php": ">=5.5.0", 15 | "ext-json": "*", 16 | "ext-mbstring": "*", 17 | "illuminate/console": "~5.1.0|~5.2.0|~5.3.0|~5.4.0|~5.5.0|~5.6.0|~5.7.0|~5.8.0|~6.0|~7.0", 18 | "illuminate/support": "~5.1.0|~5.2.0|~5.3.0|~5.4.0|~5.5.0|~5.6.0|~5.7.0|~5.8.0|~6.0|~7.0" 19 | }, 20 | "require-dev": { 21 | "phpunit/phpunit": "~4.7" 22 | }, 23 | "autoload": { 24 | "psr-4": { 25 | "MartinLindhe\\VueInternationalizationGenerator\\": "src/" 26 | } 27 | }, 28 | "extra": { 29 | "laravel": { 30 | "providers": [ 31 | "MartinLindhe\\VueInternationalizationGenerator\\GeneratorProvider" 32 | ] 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /composer.lock: -------------------------------------------------------------------------------- 1 | { 2 | "_readme": [ 3 | "This file locks the dependencies of your project to a known state", 4 | "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", 5 | "This file is @generated automatically" 6 | ], 7 | "hash": "aef7e32d65602af9e197d287373696f3", 8 | "content-hash": "82281b7ebf88accc8c084eb976b3d7f0", 9 | "packages": [ 10 | { 11 | "name": "classpreloader/classpreloader", 12 | "version": "2.0.0", 13 | "source": { 14 | "type": "git", 15 | "url": "https://github.com/ClassPreloader/ClassPreloader.git", 16 | "reference": "8c3c14b10309e3b40bce833913a6c0c0b8c8f962" 17 | }, 18 | "dist": { 19 | "type": "zip", 20 | "url": "https://api.github.com/repos/ClassPreloader/ClassPreloader/zipball/8c3c14b10309e3b40bce833913a6c0c0b8c8f962", 21 | "reference": "8c3c14b10309e3b40bce833913a6c0c0b8c8f962", 22 | "shasum": "" 23 | }, 24 | "require": { 25 | "nikic/php-parser": "~1.3", 26 | "php": ">=5.5.9" 27 | }, 28 | "require-dev": { 29 | "phpunit/phpunit": "~4.0" 30 | }, 31 | "type": "library", 32 | "extra": { 33 | "branch-alias": { 34 | "dev-master": "2.0-dev" 35 | } 36 | }, 37 | "autoload": { 38 | "psr-4": { 39 | "ClassPreloader\\": "src/" 40 | } 41 | }, 42 | "notification-url": "https://packagist.org/downloads/", 43 | "license": [ 44 | "MIT" 45 | ], 46 | "authors": [ 47 | { 48 | "name": "Michael Dowling", 49 | "email": "mtdowling@gmail.com" 50 | }, 51 | { 52 | "name": "Graham Campbell", 53 | "email": "graham@alt-three.com" 54 | } 55 | ], 56 | "description": "Helps class loading performance by generating a single PHP file containing all of the autoloaded files for a specific use case", 57 | "keywords": [ 58 | "autoload", 59 | "class", 60 | "preload" 61 | ], 62 | "time": "2015-06-28 21:39:13" 63 | }, 64 | { 65 | "name": "danielstjules/stringy", 66 | "version": "1.10.0", 67 | "source": { 68 | "type": "git", 69 | "url": "https://github.com/danielstjules/Stringy.git", 70 | "reference": "4749c205db47ee5b32e8d1adf6d9aff8db6caf3b" 71 | }, 72 | "dist": { 73 | "type": "zip", 74 | "url": "https://api.github.com/repos/danielstjules/Stringy/zipball/4749c205db47ee5b32e8d1adf6d9aff8db6caf3b", 75 | "reference": "4749c205db47ee5b32e8d1adf6d9aff8db6caf3b", 76 | "shasum": "" 77 | }, 78 | "require": { 79 | "ext-mbstring": "*", 80 | "php": ">=5.3.0" 81 | }, 82 | "require-dev": { 83 | "phpunit/phpunit": "~4.0" 84 | }, 85 | "type": "library", 86 | "autoload": { 87 | "psr-4": { 88 | "Stringy\\": "src/" 89 | }, 90 | "files": [ 91 | "src/Create.php" 92 | ] 93 | }, 94 | "notification-url": "https://packagist.org/downloads/", 95 | "license": [ 96 | "MIT" 97 | ], 98 | "authors": [ 99 | { 100 | "name": "Daniel St. Jules", 101 | "email": "danielst.jules@gmail.com", 102 | "homepage": "http://www.danielstjules.com" 103 | } 104 | ], 105 | "description": "A string manipulation library with multibyte support", 106 | "homepage": "https://github.com/danielstjules/Stringy", 107 | "keywords": [ 108 | "UTF", 109 | "helpers", 110 | "manipulation", 111 | "methods", 112 | "multibyte", 113 | "string", 114 | "utf-8", 115 | "utility", 116 | "utils" 117 | ], 118 | "time": "2015-07-23 00:54:12" 119 | }, 120 | { 121 | "name": "dnoegel/php-xdg-base-dir", 122 | "version": "0.1", 123 | "source": { 124 | "type": "git", 125 | "url": "https://github.com/dnoegel/php-xdg-base-dir.git", 126 | "reference": "265b8593498b997dc2d31e75b89f053b5cc9621a" 127 | }, 128 | "dist": { 129 | "type": "zip", 130 | "url": "https://api.github.com/repos/dnoegel/php-xdg-base-dir/zipball/265b8593498b997dc2d31e75b89f053b5cc9621a", 131 | "reference": "265b8593498b997dc2d31e75b89f053b5cc9621a", 132 | "shasum": "" 133 | }, 134 | "require": { 135 | "php": ">=5.3.2" 136 | }, 137 | "require-dev": { 138 | "phpunit/phpunit": "@stable" 139 | }, 140 | "type": "project", 141 | "autoload": { 142 | "psr-4": { 143 | "XdgBaseDir\\": "src/" 144 | } 145 | }, 146 | "notification-url": "https://packagist.org/downloads/", 147 | "license": [ 148 | "MIT" 149 | ], 150 | "description": "implementation of xdg base directory specification for php", 151 | "time": "2014-10-24 07:27:01" 152 | }, 153 | { 154 | "name": "doctrine/inflector", 155 | "version": "v1.1.0", 156 | "source": { 157 | "type": "git", 158 | "url": "https://github.com/doctrine/inflector.git", 159 | "reference": "90b2128806bfde671b6952ab8bea493942c1fdae" 160 | }, 161 | "dist": { 162 | "type": "zip", 163 | "url": "https://api.github.com/repos/doctrine/inflector/zipball/90b2128806bfde671b6952ab8bea493942c1fdae", 164 | "reference": "90b2128806bfde671b6952ab8bea493942c1fdae", 165 | "shasum": "" 166 | }, 167 | "require": { 168 | "php": ">=5.3.2" 169 | }, 170 | "require-dev": { 171 | "phpunit/phpunit": "4.*" 172 | }, 173 | "type": "library", 174 | "extra": { 175 | "branch-alias": { 176 | "dev-master": "1.1.x-dev" 177 | } 178 | }, 179 | "autoload": { 180 | "psr-0": { 181 | "Doctrine\\Common\\Inflector\\": "lib/" 182 | } 183 | }, 184 | "notification-url": "https://packagist.org/downloads/", 185 | "license": [ 186 | "MIT" 187 | ], 188 | "authors": [ 189 | { 190 | "name": "Roman Borschel", 191 | "email": "roman@code-factory.org" 192 | }, 193 | { 194 | "name": "Benjamin Eberlei", 195 | "email": "kontakt@beberlei.de" 196 | }, 197 | { 198 | "name": "Guilherme Blanco", 199 | "email": "guilhermeblanco@gmail.com" 200 | }, 201 | { 202 | "name": "Jonathan Wage", 203 | "email": "jonwage@gmail.com" 204 | }, 205 | { 206 | "name": "Johannes Schmitt", 207 | "email": "schmittjoh@gmail.com" 208 | } 209 | ], 210 | "description": "Common String Manipulations with regard to casing and singular/plural rules.", 211 | "homepage": "http://www.doctrine-project.org", 212 | "keywords": [ 213 | "inflection", 214 | "pluralize", 215 | "singularize", 216 | "string" 217 | ], 218 | "time": "2015-11-06 14:35:42" 219 | }, 220 | { 221 | "name": "jakub-onderka/php-console-color", 222 | "version": "0.1", 223 | "source": { 224 | "type": "git", 225 | "url": "https://github.com/JakubOnderka/PHP-Console-Color.git", 226 | "reference": "e0b393dacf7703fc36a4efc3df1435485197e6c1" 227 | }, 228 | "dist": { 229 | "type": "zip", 230 | "url": "https://api.github.com/repos/JakubOnderka/PHP-Console-Color/zipball/e0b393dacf7703fc36a4efc3df1435485197e6c1", 231 | "reference": "e0b393dacf7703fc36a4efc3df1435485197e6c1", 232 | "shasum": "" 233 | }, 234 | "require": { 235 | "php": ">=5.3.2" 236 | }, 237 | "require-dev": { 238 | "jakub-onderka/php-code-style": "1.0", 239 | "jakub-onderka/php-parallel-lint": "0.*", 240 | "jakub-onderka/php-var-dump-check": "0.*", 241 | "phpunit/phpunit": "3.7.*", 242 | "squizlabs/php_codesniffer": "1.*" 243 | }, 244 | "type": "library", 245 | "autoload": { 246 | "psr-0": { 247 | "JakubOnderka\\PhpConsoleColor": "src/" 248 | } 249 | }, 250 | "notification-url": "https://packagist.org/downloads/", 251 | "license": [ 252 | "BSD-2-Clause" 253 | ], 254 | "authors": [ 255 | { 256 | "name": "Jakub Onderka", 257 | "email": "jakub.onderka@gmail.com", 258 | "homepage": "http://www.acci.cz" 259 | } 260 | ], 261 | "time": "2014-04-08 15:00:19" 262 | }, 263 | { 264 | "name": "jakub-onderka/php-console-highlighter", 265 | "version": "v0.3.2", 266 | "source": { 267 | "type": "git", 268 | "url": "https://github.com/JakubOnderka/PHP-Console-Highlighter.git", 269 | "reference": "7daa75df45242c8d5b75a22c00a201e7954e4fb5" 270 | }, 271 | "dist": { 272 | "type": "zip", 273 | "url": "https://api.github.com/repos/JakubOnderka/PHP-Console-Highlighter/zipball/7daa75df45242c8d5b75a22c00a201e7954e4fb5", 274 | "reference": "7daa75df45242c8d5b75a22c00a201e7954e4fb5", 275 | "shasum": "" 276 | }, 277 | "require": { 278 | "jakub-onderka/php-console-color": "~0.1", 279 | "php": ">=5.3.0" 280 | }, 281 | "require-dev": { 282 | "jakub-onderka/php-code-style": "~1.0", 283 | "jakub-onderka/php-parallel-lint": "~0.5", 284 | "jakub-onderka/php-var-dump-check": "~0.1", 285 | "phpunit/phpunit": "~4.0", 286 | "squizlabs/php_codesniffer": "~1.5" 287 | }, 288 | "type": "library", 289 | "autoload": { 290 | "psr-0": { 291 | "JakubOnderka\\PhpConsoleHighlighter": "src/" 292 | } 293 | }, 294 | "notification-url": "https://packagist.org/downloads/", 295 | "license": [ 296 | "MIT" 297 | ], 298 | "authors": [ 299 | { 300 | "name": "Jakub Onderka", 301 | "email": "acci@acci.cz", 302 | "homepage": "http://www.acci.cz/" 303 | } 304 | ], 305 | "time": "2015-04-20 18:58:01" 306 | }, 307 | { 308 | "name": "jeremeamia/SuperClosure", 309 | "version": "2.1.0", 310 | "source": { 311 | "type": "git", 312 | "url": "https://github.com/jeremeamia/super_closure.git", 313 | "reference": "b712f39c671e5ead60c7ebfe662545456aade833" 314 | }, 315 | "dist": { 316 | "type": "zip", 317 | "url": "https://api.github.com/repos/jeremeamia/super_closure/zipball/b712f39c671e5ead60c7ebfe662545456aade833", 318 | "reference": "b712f39c671e5ead60c7ebfe662545456aade833", 319 | "shasum": "" 320 | }, 321 | "require": { 322 | "nikic/php-parser": "~1.0", 323 | "php": ">=5.4" 324 | }, 325 | "require-dev": { 326 | "codeclimate/php-test-reporter": "~0.1.2", 327 | "phpunit/phpunit": "~4.0" 328 | }, 329 | "type": "library", 330 | "extra": { 331 | "branch-alias": { 332 | "dev-master": "2.1-dev" 333 | } 334 | }, 335 | "autoload": { 336 | "psr-4": { 337 | "SuperClosure\\": "src/" 338 | } 339 | }, 340 | "notification-url": "https://packagist.org/downloads/", 341 | "license": [ 342 | "MIT" 343 | ], 344 | "authors": [ 345 | { 346 | "name": "Jeremy Lindblom", 347 | "email": "jeremeamia@gmail.com", 348 | "homepage": "https://github.com/jeremeamia", 349 | "role": "Developer" 350 | } 351 | ], 352 | "description": "Serialize Closure objects, including their context and binding", 353 | "homepage": "https://github.com/jeremeamia/super_closure", 354 | "keywords": [ 355 | "closure", 356 | "function", 357 | "lambda", 358 | "parser", 359 | "serializable", 360 | "serialize", 361 | "tokenizer" 362 | ], 363 | "time": "2015-03-11 20:06:43" 364 | }, 365 | { 366 | "name": "laravel/framework", 367 | "version": "v5.1.23", 368 | "source": { 369 | "type": "git", 370 | "url": "https://github.com/laravel/framework.git", 371 | "reference": "a4ea877d2bb6a68796b244a741594968796c1c4e" 372 | }, 373 | "dist": { 374 | "type": "zip", 375 | "url": "https://api.github.com/repos/laravel/framework/zipball/a4ea877d2bb6a68796b244a741594968796c1c4e", 376 | "reference": "a4ea877d2bb6a68796b244a741594968796c1c4e", 377 | "shasum": "" 378 | }, 379 | "require": { 380 | "classpreloader/classpreloader": "~2.0", 381 | "danielstjules/stringy": "~1.8", 382 | "doctrine/inflector": "~1.0", 383 | "ext-mbstring": "*", 384 | "ext-openssl": "*", 385 | "jeremeamia/superclosure": "~2.0", 386 | "league/flysystem": "~1.0", 387 | "monolog/monolog": "~1.11", 388 | "mtdowling/cron-expression": "~1.0", 389 | "nesbot/carbon": "~1.19", 390 | "paragonie/random_compat": "^1.0.6", 391 | "php": ">=5.5.9", 392 | "psy/psysh": "~0.5.1", 393 | "swiftmailer/swiftmailer": "~5.1", 394 | "symfony/console": "2.7.*", 395 | "symfony/css-selector": "2.7.*", 396 | "symfony/debug": "2.7.*", 397 | "symfony/dom-crawler": "2.7.*", 398 | "symfony/finder": "2.7.*", 399 | "symfony/http-foundation": "2.7.*", 400 | "symfony/http-kernel": "2.7.*", 401 | "symfony/process": "2.7.*", 402 | "symfony/routing": "2.7.*", 403 | "symfony/translation": "2.7.*", 404 | "symfony/var-dumper": "2.7.*", 405 | "vlucas/phpdotenv": "~1.0" 406 | }, 407 | "replace": { 408 | "illuminate/auth": "self.version", 409 | "illuminate/broadcasting": "self.version", 410 | "illuminate/bus": "self.version", 411 | "illuminate/cache": "self.version", 412 | "illuminate/config": "self.version", 413 | "illuminate/console": "self.version", 414 | "illuminate/container": "self.version", 415 | "illuminate/contracts": "self.version", 416 | "illuminate/cookie": "self.version", 417 | "illuminate/database": "self.version", 418 | "illuminate/encryption": "self.version", 419 | "illuminate/events": "self.version", 420 | "illuminate/exception": "self.version", 421 | "illuminate/filesystem": "self.version", 422 | "illuminate/foundation": "self.version", 423 | "illuminate/hashing": "self.version", 424 | "illuminate/http": "self.version", 425 | "illuminate/log": "self.version", 426 | "illuminate/mail": "self.version", 427 | "illuminate/pagination": "self.version", 428 | "illuminate/pipeline": "self.version", 429 | "illuminate/queue": "self.version", 430 | "illuminate/redis": "self.version", 431 | "illuminate/routing": "self.version", 432 | "illuminate/session": "self.version", 433 | "illuminate/support": "self.version", 434 | "illuminate/translation": "self.version", 435 | "illuminate/validation": "self.version", 436 | "illuminate/view": "self.version" 437 | }, 438 | "require-dev": { 439 | "aws/aws-sdk-php": "~3.0", 440 | "iron-io/iron_mq": "~2.0", 441 | "mockery/mockery": "~0.9.1", 442 | "pda/pheanstalk": "~3.0", 443 | "phpunit/phpunit": "~4.0", 444 | "predis/predis": "~1.0" 445 | }, 446 | "suggest": { 447 | "aws/aws-sdk-php": "Required to use the SQS queue driver and SES mail driver (~3.0).", 448 | "doctrine/dbal": "Required to rename columns and drop SQLite columns (~2.4).", 449 | "fzaninotto/faker": "Required to use the eloquent factory builder (~1.4).", 450 | "guzzlehttp/guzzle": "Required to use the Mailgun and Mandrill mail drivers (~5.3|~6.0).", 451 | "iron-io/iron_mq": "Required to use the iron queue driver (~2.0).", 452 | "league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (~1.0).", 453 | "league/flysystem-rackspace": "Required to use the Flysystem Rackspace driver (~1.0).", 454 | "pda/pheanstalk": "Required to use the beanstalk queue driver (~3.0).", 455 | "predis/predis": "Required to use the redis cache and queue drivers (~1.0).", 456 | "pusher/pusher-php-server": "Required to use the Pusher broadcast driver (~2.0)." 457 | }, 458 | "type": "library", 459 | "extra": { 460 | "branch-alias": { 461 | "dev-master": "5.1-dev" 462 | } 463 | }, 464 | "autoload": { 465 | "classmap": [ 466 | "src/Illuminate/Queue/IlluminateQueueClosure.php" 467 | ], 468 | "files": [ 469 | "src/Illuminate/Foundation/helpers.php", 470 | "src/Illuminate/Support/helpers.php" 471 | ], 472 | "psr-4": { 473 | "Illuminate\\": "src/Illuminate/" 474 | } 475 | }, 476 | "notification-url": "https://packagist.org/downloads/", 477 | "license": [ 478 | "MIT" 479 | ], 480 | "authors": [ 481 | { 482 | "name": "Taylor Otwell", 483 | "email": "taylorotwell@gmail.com" 484 | } 485 | ], 486 | "description": "The Laravel Framework.", 487 | "homepage": "http://laravel.com", 488 | "keywords": [ 489 | "framework", 490 | "laravel" 491 | ], 492 | "time": "2015-11-03 16:32:33" 493 | }, 494 | { 495 | "name": "league/flysystem", 496 | "version": "1.0.15", 497 | "source": { 498 | "type": "git", 499 | "url": "https://github.com/thephpleague/flysystem.git", 500 | "reference": "31525caf9e8772683672fefd8a1ca0c0736020f4" 501 | }, 502 | "dist": { 503 | "type": "zip", 504 | "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/31525caf9e8772683672fefd8a1ca0c0736020f4", 505 | "reference": "31525caf9e8772683672fefd8a1ca0c0736020f4", 506 | "shasum": "" 507 | }, 508 | "require": { 509 | "php": ">=5.4.0" 510 | }, 511 | "conflict": { 512 | "league/flysystem-sftp": "<1.0.6" 513 | }, 514 | "require-dev": { 515 | "ext-fileinfo": "*", 516 | "mockery/mockery": "~0.9", 517 | "phpspec/phpspec": "^2.2", 518 | "phpspec/prophecy-phpunit": "~1.0", 519 | "phpunit/phpunit": "~4.1" 520 | }, 521 | "suggest": { 522 | "ext-fileinfo": "Required for MimeType", 523 | "league/flysystem-aws-s3-v2": "Allows you to use S3 storage with AWS SDK v2", 524 | "league/flysystem-aws-s3-v3": "Allows you to use S3 storage with AWS SDK v3", 525 | "league/flysystem-azure": "Allows you to use Windows Azure Blob storage", 526 | "league/flysystem-cached-adapter": "Flysystem adapter decorator for metadata caching", 527 | "league/flysystem-copy": "Allows you to use Copy.com storage", 528 | "league/flysystem-dropbox": "Allows you to use Dropbox storage", 529 | "league/flysystem-eventable-filesystem": "Allows you to use EventableFilesystem", 530 | "league/flysystem-rackspace": "Allows you to use Rackspace Cloud Files", 531 | "league/flysystem-sftp": "Allows you to use SFTP server storage via phpseclib", 532 | "league/flysystem-webdav": "Allows you to use WebDAV storage", 533 | "league/flysystem-ziparchive": "Allows you to use ZipArchive adapter" 534 | }, 535 | "type": "library", 536 | "extra": { 537 | "branch-alias": { 538 | "dev-master": "1.1-dev" 539 | } 540 | }, 541 | "autoload": { 542 | "psr-4": { 543 | "League\\Flysystem\\": "src/" 544 | } 545 | }, 546 | "notification-url": "https://packagist.org/downloads/", 547 | "license": [ 548 | "MIT" 549 | ], 550 | "authors": [ 551 | { 552 | "name": "Frank de Jonge", 553 | "email": "info@frenky.net" 554 | } 555 | ], 556 | "description": "Filesystem abstraction: Many filesystems, one API.", 557 | "keywords": [ 558 | "Cloud Files", 559 | "WebDAV", 560 | "abstraction", 561 | "aws", 562 | "cloud", 563 | "copy.com", 564 | "dropbox", 565 | "file systems", 566 | "files", 567 | "filesystem", 568 | "filesystems", 569 | "ftp", 570 | "rackspace", 571 | "remote", 572 | "s3", 573 | "sftp", 574 | "storage" 575 | ], 576 | "time": "2015-09-30 22:26:59" 577 | }, 578 | { 579 | "name": "monolog/monolog", 580 | "version": "1.17.2", 581 | "source": { 582 | "type": "git", 583 | "url": "https://github.com/Seldaek/monolog.git", 584 | "reference": "bee7f0dc9c3e0b69a6039697533dca1e845c8c24" 585 | }, 586 | "dist": { 587 | "type": "zip", 588 | "url": "https://api.github.com/repos/Seldaek/monolog/zipball/bee7f0dc9c3e0b69a6039697533dca1e845c8c24", 589 | "reference": "bee7f0dc9c3e0b69a6039697533dca1e845c8c24", 590 | "shasum": "" 591 | }, 592 | "require": { 593 | "php": ">=5.3.0", 594 | "psr/log": "~1.0" 595 | }, 596 | "provide": { 597 | "psr/log-implementation": "1.0.0" 598 | }, 599 | "require-dev": { 600 | "aws/aws-sdk-php": "^2.4.9", 601 | "doctrine/couchdb": "~1.0@dev", 602 | "graylog2/gelf-php": "~1.0", 603 | "jakub-onderka/php-parallel-lint": "0.9", 604 | "php-console/php-console": "^3.1.3", 605 | "phpunit/phpunit": "~4.5", 606 | "phpunit/phpunit-mock-objects": "2.3.0", 607 | "raven/raven": "^0.13", 608 | "ruflin/elastica": ">=0.90 <3.0", 609 | "swiftmailer/swiftmailer": "~5.3", 610 | "videlalvaro/php-amqplib": "~2.4" 611 | }, 612 | "suggest": { 613 | "aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB", 614 | "doctrine/couchdb": "Allow sending log messages to a CouchDB server", 615 | "ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)", 616 | "ext-mongo": "Allow sending log messages to a MongoDB server", 617 | "graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server", 618 | "php-console/php-console": "Allow sending log messages to Google Chrome", 619 | "raven/raven": "Allow sending log messages to a Sentry server", 620 | "rollbar/rollbar": "Allow sending log messages to Rollbar", 621 | "ruflin/elastica": "Allow sending log messages to an Elastic Search server", 622 | "videlalvaro/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib" 623 | }, 624 | "type": "library", 625 | "extra": { 626 | "branch-alias": { 627 | "dev-master": "1.16.x-dev" 628 | } 629 | }, 630 | "autoload": { 631 | "psr-4": { 632 | "Monolog\\": "src/Monolog" 633 | } 634 | }, 635 | "notification-url": "https://packagist.org/downloads/", 636 | "license": [ 637 | "MIT" 638 | ], 639 | "authors": [ 640 | { 641 | "name": "Jordi Boggiano", 642 | "email": "j.boggiano@seld.be", 643 | "homepage": "http://seld.be" 644 | } 645 | ], 646 | "description": "Sends your logs to files, sockets, inboxes, databases and various web services", 647 | "homepage": "http://github.com/Seldaek/monolog", 648 | "keywords": [ 649 | "log", 650 | "logging", 651 | "psr-3" 652 | ], 653 | "time": "2015-10-14 12:51:02" 654 | }, 655 | { 656 | "name": "mtdowling/cron-expression", 657 | "version": "v1.0.4", 658 | "source": { 659 | "type": "git", 660 | "url": "https://github.com/mtdowling/cron-expression.git", 661 | "reference": "fd92e883195e5dfa77720b1868cf084b08be4412" 662 | }, 663 | "dist": { 664 | "type": "zip", 665 | "url": "https://api.github.com/repos/mtdowling/cron-expression/zipball/fd92e883195e5dfa77720b1868cf084b08be4412", 666 | "reference": "fd92e883195e5dfa77720b1868cf084b08be4412", 667 | "shasum": "" 668 | }, 669 | "require": { 670 | "php": ">=5.3.2" 671 | }, 672 | "require-dev": { 673 | "phpunit/phpunit": "4.*" 674 | }, 675 | "type": "library", 676 | "autoload": { 677 | "psr-0": { 678 | "Cron": "src/" 679 | } 680 | }, 681 | "notification-url": "https://packagist.org/downloads/", 682 | "license": [ 683 | "MIT" 684 | ], 685 | "authors": [ 686 | { 687 | "name": "Michael Dowling", 688 | "email": "mtdowling@gmail.com", 689 | "homepage": "https://github.com/mtdowling" 690 | } 691 | ], 692 | "description": "CRON for PHP: Calculate the next or previous run date and determine if a CRON expression is due", 693 | "keywords": [ 694 | "cron", 695 | "schedule" 696 | ], 697 | "time": "2015-01-11 23:07:46" 698 | }, 699 | { 700 | "name": "nesbot/carbon", 701 | "version": "1.21.0", 702 | "source": { 703 | "type": "git", 704 | "url": "https://github.com/briannesbitt/Carbon.git", 705 | "reference": "7b08ec6f75791e130012f206e3f7b0e76e18e3d7" 706 | }, 707 | "dist": { 708 | "type": "zip", 709 | "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/7b08ec6f75791e130012f206e3f7b0e76e18e3d7", 710 | "reference": "7b08ec6f75791e130012f206e3f7b0e76e18e3d7", 711 | "shasum": "" 712 | }, 713 | "require": { 714 | "php": ">=5.3.0", 715 | "symfony/translation": "~2.6|~3.0" 716 | }, 717 | "require-dev": { 718 | "phpunit/phpunit": "~4.0|~5.0" 719 | }, 720 | "type": "library", 721 | "autoload": { 722 | "psr-4": { 723 | "Carbon\\": "src/Carbon/" 724 | } 725 | }, 726 | "notification-url": "https://packagist.org/downloads/", 727 | "license": [ 728 | "MIT" 729 | ], 730 | "authors": [ 731 | { 732 | "name": "Brian Nesbitt", 733 | "email": "brian@nesbot.com", 734 | "homepage": "http://nesbot.com" 735 | } 736 | ], 737 | "description": "A simple API extension for DateTime.", 738 | "homepage": "http://carbon.nesbot.com", 739 | "keywords": [ 740 | "date", 741 | "datetime", 742 | "time" 743 | ], 744 | "time": "2015-11-04 20:07:17" 745 | }, 746 | { 747 | "name": "nikic/php-parser", 748 | "version": "v1.4.1", 749 | "source": { 750 | "type": "git", 751 | "url": "https://github.com/nikic/PHP-Parser.git", 752 | "reference": "f78af2c9c86107aa1a34cd1dbb5bbe9eeb0d9f51" 753 | }, 754 | "dist": { 755 | "type": "zip", 756 | "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/f78af2c9c86107aa1a34cd1dbb5bbe9eeb0d9f51", 757 | "reference": "f78af2c9c86107aa1a34cd1dbb5bbe9eeb0d9f51", 758 | "shasum": "" 759 | }, 760 | "require": { 761 | "ext-tokenizer": "*", 762 | "php": ">=5.3" 763 | }, 764 | "type": "library", 765 | "extra": { 766 | "branch-alias": { 767 | "dev-master": "1.4-dev" 768 | } 769 | }, 770 | "autoload": { 771 | "files": [ 772 | "lib/bootstrap.php" 773 | ] 774 | }, 775 | "notification-url": "https://packagist.org/downloads/", 776 | "license": [ 777 | "BSD-3-Clause" 778 | ], 779 | "authors": [ 780 | { 781 | "name": "Nikita Popov" 782 | } 783 | ], 784 | "description": "A PHP parser written in PHP", 785 | "keywords": [ 786 | "parser", 787 | "php" 788 | ], 789 | "time": "2015-09-19 14:15:08" 790 | }, 791 | { 792 | "name": "paragonie/random_compat", 793 | "version": "1.0.10", 794 | "source": { 795 | "type": "git", 796 | "url": "https://github.com/paragonie/random_compat.git", 797 | "reference": "2fa50aa2f17066fa74ba00d943e8cee1a98284af" 798 | }, 799 | "dist": { 800 | "type": "zip", 801 | "url": "https://api.github.com/repos/paragonie/random_compat/zipball/2fa50aa2f17066fa74ba00d943e8cee1a98284af", 802 | "reference": "2fa50aa2f17066fa74ba00d943e8cee1a98284af", 803 | "shasum": "" 804 | }, 805 | "require": { 806 | "php": ">=5.2.0" 807 | }, 808 | "suggest": { 809 | "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." 810 | }, 811 | "type": "library", 812 | "autoload": { 813 | "files": [ 814 | "lib/random.php" 815 | ] 816 | }, 817 | "notification-url": "https://packagist.org/downloads/", 818 | "license": [ 819 | "MIT" 820 | ], 821 | "authors": [ 822 | { 823 | "name": "Paragon Initiative Enterprises", 824 | "email": "security@paragonie.com", 825 | "homepage": "https://paragonie.com" 826 | } 827 | ], 828 | "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", 829 | "keywords": [ 830 | "csprng", 831 | "pseudorandom", 832 | "random" 833 | ], 834 | "time": "2015-10-23 13:21:37" 835 | }, 836 | { 837 | "name": "psr/log", 838 | "version": "1.0.0", 839 | "source": { 840 | "type": "git", 841 | "url": "https://github.com/php-fig/log.git", 842 | "reference": "fe0936ee26643249e916849d48e3a51d5f5e278b" 843 | }, 844 | "dist": { 845 | "type": "zip", 846 | "url": "https://api.github.com/repos/php-fig/log/zipball/fe0936ee26643249e916849d48e3a51d5f5e278b", 847 | "reference": "fe0936ee26643249e916849d48e3a51d5f5e278b", 848 | "shasum": "" 849 | }, 850 | "type": "library", 851 | "autoload": { 852 | "psr-0": { 853 | "Psr\\Log\\": "" 854 | } 855 | }, 856 | "notification-url": "https://packagist.org/downloads/", 857 | "license": [ 858 | "MIT" 859 | ], 860 | "authors": [ 861 | { 862 | "name": "PHP-FIG", 863 | "homepage": "http://www.php-fig.org/" 864 | } 865 | ], 866 | "description": "Common interface for logging libraries", 867 | "keywords": [ 868 | "log", 869 | "psr", 870 | "psr-3" 871 | ], 872 | "time": "2012-12-21 11:40:51" 873 | }, 874 | { 875 | "name": "psy/psysh", 876 | "version": "v0.5.2", 877 | "source": { 878 | "type": "git", 879 | "url": "https://github.com/bobthecow/psysh.git", 880 | "reference": "aaf8772ade08b5f0f6830774a5d5c2f800415975" 881 | }, 882 | "dist": { 883 | "type": "zip", 884 | "url": "https://api.github.com/repos/bobthecow/psysh/zipball/aaf8772ade08b5f0f6830774a5d5c2f800415975", 885 | "reference": "aaf8772ade08b5f0f6830774a5d5c2f800415975", 886 | "shasum": "" 887 | }, 888 | "require": { 889 | "dnoegel/php-xdg-base-dir": "0.1", 890 | "jakub-onderka/php-console-highlighter": "0.3.*", 891 | "nikic/php-parser": "^1.2.1", 892 | "php": ">=5.3.9", 893 | "symfony/console": "~2.3.10|^2.4.2|~3.0", 894 | "symfony/var-dumper": "~2.7|~3.0" 895 | }, 896 | "require-dev": { 897 | "fabpot/php-cs-fixer": "~1.5", 898 | "phpunit/phpunit": "~3.7|~4.0", 899 | "squizlabs/php_codesniffer": "~2.0", 900 | "symfony/finder": "~2.1|~3.0" 901 | }, 902 | "suggest": { 903 | "ext-pcntl": "Enabling the PCNTL extension makes PsySH a lot happier :)", 904 | "ext-pdo-sqlite": "The doc command requires SQLite to work.", 905 | "ext-posix": "If you have PCNTL, you'll want the POSIX extension as well.", 906 | "ext-readline": "Enables support for arrow-key history navigation, and showing and manipulating command history." 907 | }, 908 | "bin": [ 909 | "bin/psysh" 910 | ], 911 | "type": "library", 912 | "extra": { 913 | "branch-alias": { 914 | "dev-develop": "0.6.x-dev" 915 | } 916 | }, 917 | "autoload": { 918 | "files": [ 919 | "src/Psy/functions.php" 920 | ], 921 | "psr-0": { 922 | "Psy\\": "src/" 923 | } 924 | }, 925 | "notification-url": "https://packagist.org/downloads/", 926 | "license": [ 927 | "MIT" 928 | ], 929 | "authors": [ 930 | { 931 | "name": "Justin Hileman", 932 | "email": "justin@justinhileman.info", 933 | "homepage": "http://justinhileman.com" 934 | } 935 | ], 936 | "description": "An interactive shell for modern PHP.", 937 | "homepage": "http://psysh.org", 938 | "keywords": [ 939 | "REPL", 940 | "console", 941 | "interactive", 942 | "shell" 943 | ], 944 | "time": "2015-07-16 15:26:57" 945 | }, 946 | { 947 | "name": "swiftmailer/swiftmailer", 948 | "version": "v5.4.1", 949 | "source": { 950 | "type": "git", 951 | "url": "https://github.com/swiftmailer/swiftmailer.git", 952 | "reference": "0697e6aa65c83edf97bb0f23d8763f94e3f11421" 953 | }, 954 | "dist": { 955 | "type": "zip", 956 | "url": "https://api.github.com/repos/swiftmailer/swiftmailer/zipball/0697e6aa65c83edf97bb0f23d8763f94e3f11421", 957 | "reference": "0697e6aa65c83edf97bb0f23d8763f94e3f11421", 958 | "shasum": "" 959 | }, 960 | "require": { 961 | "php": ">=5.3.3" 962 | }, 963 | "require-dev": { 964 | "mockery/mockery": "~0.9.1,<0.9.4" 965 | }, 966 | "type": "library", 967 | "extra": { 968 | "branch-alias": { 969 | "dev-master": "5.4-dev" 970 | } 971 | }, 972 | "autoload": { 973 | "files": [ 974 | "lib/swift_required.php" 975 | ] 976 | }, 977 | "notification-url": "https://packagist.org/downloads/", 978 | "license": [ 979 | "MIT" 980 | ], 981 | "authors": [ 982 | { 983 | "name": "Chris Corbyn" 984 | }, 985 | { 986 | "name": "Fabien Potencier", 987 | "email": "fabien@symfony.com" 988 | } 989 | ], 990 | "description": "Swiftmailer, free feature-rich PHP mailer", 991 | "homepage": "http://swiftmailer.org", 992 | "keywords": [ 993 | "email", 994 | "mail", 995 | "mailer" 996 | ], 997 | "time": "2015-06-06 14:19:39" 998 | }, 999 | { 1000 | "name": "symfony/console", 1001 | "version": "v2.7.6", 1002 | "source": { 1003 | "type": "git", 1004 | "url": "https://github.com/symfony/console.git", 1005 | "reference": "5efd632294c8320ea52492db22292ff853a43766" 1006 | }, 1007 | "dist": { 1008 | "type": "zip", 1009 | "url": "https://api.github.com/repos/symfony/console/zipball/5efd632294c8320ea52492db22292ff853a43766", 1010 | "reference": "5efd632294c8320ea52492db22292ff853a43766", 1011 | "shasum": "" 1012 | }, 1013 | "require": { 1014 | "php": ">=5.3.9" 1015 | }, 1016 | "require-dev": { 1017 | "psr/log": "~1.0", 1018 | "symfony/event-dispatcher": "~2.1", 1019 | "symfony/process": "~2.1" 1020 | }, 1021 | "suggest": { 1022 | "psr/log": "For using the console logger", 1023 | "symfony/event-dispatcher": "", 1024 | "symfony/process": "" 1025 | }, 1026 | "type": "library", 1027 | "extra": { 1028 | "branch-alias": { 1029 | "dev-master": "2.7-dev" 1030 | } 1031 | }, 1032 | "autoload": { 1033 | "psr-4": { 1034 | "Symfony\\Component\\Console\\": "" 1035 | } 1036 | }, 1037 | "notification-url": "https://packagist.org/downloads/", 1038 | "license": [ 1039 | "MIT" 1040 | ], 1041 | "authors": [ 1042 | { 1043 | "name": "Fabien Potencier", 1044 | "email": "fabien@symfony.com" 1045 | }, 1046 | { 1047 | "name": "Symfony Community", 1048 | "homepage": "https://symfony.com/contributors" 1049 | } 1050 | ], 1051 | "description": "Symfony Console Component", 1052 | "homepage": "https://symfony.com", 1053 | "time": "2015-10-20 14:38:46" 1054 | }, 1055 | { 1056 | "name": "symfony/css-selector", 1057 | "version": "v2.7.6", 1058 | "source": { 1059 | "type": "git", 1060 | "url": "https://github.com/symfony/css-selector.git", 1061 | "reference": "e1b865b26be4a56d22a8dee398375044a80c865b" 1062 | }, 1063 | "dist": { 1064 | "type": "zip", 1065 | "url": "https://api.github.com/repos/symfony/css-selector/zipball/e1b865b26be4a56d22a8dee398375044a80c865b", 1066 | "reference": "e1b865b26be4a56d22a8dee398375044a80c865b", 1067 | "shasum": "" 1068 | }, 1069 | "require": { 1070 | "php": ">=5.3.9" 1071 | }, 1072 | "type": "library", 1073 | "extra": { 1074 | "branch-alias": { 1075 | "dev-master": "2.7-dev" 1076 | } 1077 | }, 1078 | "autoload": { 1079 | "psr-4": { 1080 | "Symfony\\Component\\CssSelector\\": "" 1081 | } 1082 | }, 1083 | "notification-url": "https://packagist.org/downloads/", 1084 | "license": [ 1085 | "MIT" 1086 | ], 1087 | "authors": [ 1088 | { 1089 | "name": "Jean-François Simon", 1090 | "email": "jeanfrancois.simon@sensiolabs.com" 1091 | }, 1092 | { 1093 | "name": "Fabien Potencier", 1094 | "email": "fabien@symfony.com" 1095 | }, 1096 | { 1097 | "name": "Symfony Community", 1098 | "homepage": "https://symfony.com/contributors" 1099 | } 1100 | ], 1101 | "description": "Symfony CssSelector Component", 1102 | "homepage": "https://symfony.com", 1103 | "time": "2015-10-11 09:39:48" 1104 | }, 1105 | { 1106 | "name": "symfony/debug", 1107 | "version": "v2.7.6", 1108 | "source": { 1109 | "type": "git", 1110 | "url": "https://github.com/symfony/debug.git", 1111 | "reference": "fb9e6887db716939f41af0ba8ef38a1582eb501b" 1112 | }, 1113 | "dist": { 1114 | "type": "zip", 1115 | "url": "https://api.github.com/repos/symfony/debug/zipball/fb9e6887db716939f41af0ba8ef38a1582eb501b", 1116 | "reference": "fb9e6887db716939f41af0ba8ef38a1582eb501b", 1117 | "shasum": "" 1118 | }, 1119 | "require": { 1120 | "php": ">=5.3.9", 1121 | "psr/log": "~1.0" 1122 | }, 1123 | "conflict": { 1124 | "symfony/http-kernel": ">=2.3,<2.3.24|~2.4.0|>=2.5,<2.5.9|>=2.6,<2.6.2" 1125 | }, 1126 | "require-dev": { 1127 | "symfony/class-loader": "~2.2", 1128 | "symfony/http-kernel": "~2.3.24|~2.5.9|~2.6,>=2.6.2" 1129 | }, 1130 | "type": "library", 1131 | "extra": { 1132 | "branch-alias": { 1133 | "dev-master": "2.7-dev" 1134 | } 1135 | }, 1136 | "autoload": { 1137 | "psr-4": { 1138 | "Symfony\\Component\\Debug\\": "" 1139 | } 1140 | }, 1141 | "notification-url": "https://packagist.org/downloads/", 1142 | "license": [ 1143 | "MIT" 1144 | ], 1145 | "authors": [ 1146 | { 1147 | "name": "Fabien Potencier", 1148 | "email": "fabien@symfony.com" 1149 | }, 1150 | { 1151 | "name": "Symfony Community", 1152 | "homepage": "https://symfony.com/contributors" 1153 | } 1154 | ], 1155 | "description": "Symfony Debug Component", 1156 | "homepage": "https://symfony.com", 1157 | "time": "2015-10-11 09:39:48" 1158 | }, 1159 | { 1160 | "name": "symfony/dom-crawler", 1161 | "version": "v2.7.6", 1162 | "source": { 1163 | "type": "git", 1164 | "url": "https://github.com/symfony/dom-crawler.git", 1165 | "reference": "5fef7d8b80d8f9992df99d8ee283f420484c9612" 1166 | }, 1167 | "dist": { 1168 | "type": "zip", 1169 | "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/5fef7d8b80d8f9992df99d8ee283f420484c9612", 1170 | "reference": "5fef7d8b80d8f9992df99d8ee283f420484c9612", 1171 | "shasum": "" 1172 | }, 1173 | "require": { 1174 | "php": ">=5.3.9" 1175 | }, 1176 | "require-dev": { 1177 | "symfony/css-selector": "~2.3" 1178 | }, 1179 | "suggest": { 1180 | "symfony/css-selector": "" 1181 | }, 1182 | "type": "library", 1183 | "extra": { 1184 | "branch-alias": { 1185 | "dev-master": "2.7-dev" 1186 | } 1187 | }, 1188 | "autoload": { 1189 | "psr-4": { 1190 | "Symfony\\Component\\DomCrawler\\": "" 1191 | } 1192 | }, 1193 | "notification-url": "https://packagist.org/downloads/", 1194 | "license": [ 1195 | "MIT" 1196 | ], 1197 | "authors": [ 1198 | { 1199 | "name": "Fabien Potencier", 1200 | "email": "fabien@symfony.com" 1201 | }, 1202 | { 1203 | "name": "Symfony Community", 1204 | "homepage": "https://symfony.com/contributors" 1205 | } 1206 | ], 1207 | "description": "Symfony DomCrawler Component", 1208 | "homepage": "https://symfony.com", 1209 | "time": "2015-10-11 09:39:48" 1210 | }, 1211 | { 1212 | "name": "symfony/event-dispatcher", 1213 | "version": "v2.7.6", 1214 | "source": { 1215 | "type": "git", 1216 | "url": "https://github.com/symfony/event-dispatcher.git", 1217 | "reference": "87a5db5ea887763fa3a31a5471b512ff1596d9b8" 1218 | }, 1219 | "dist": { 1220 | "type": "zip", 1221 | "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/87a5db5ea887763fa3a31a5471b512ff1596d9b8", 1222 | "reference": "87a5db5ea887763fa3a31a5471b512ff1596d9b8", 1223 | "shasum": "" 1224 | }, 1225 | "require": { 1226 | "php": ">=5.3.9" 1227 | }, 1228 | "require-dev": { 1229 | "psr/log": "~1.0", 1230 | "symfony/config": "~2.0,>=2.0.5", 1231 | "symfony/dependency-injection": "~2.6", 1232 | "symfony/expression-language": "~2.6", 1233 | "symfony/stopwatch": "~2.3" 1234 | }, 1235 | "suggest": { 1236 | "symfony/dependency-injection": "", 1237 | "symfony/http-kernel": "" 1238 | }, 1239 | "type": "library", 1240 | "extra": { 1241 | "branch-alias": { 1242 | "dev-master": "2.7-dev" 1243 | } 1244 | }, 1245 | "autoload": { 1246 | "psr-4": { 1247 | "Symfony\\Component\\EventDispatcher\\": "" 1248 | } 1249 | }, 1250 | "notification-url": "https://packagist.org/downloads/", 1251 | "license": [ 1252 | "MIT" 1253 | ], 1254 | "authors": [ 1255 | { 1256 | "name": "Fabien Potencier", 1257 | "email": "fabien@symfony.com" 1258 | }, 1259 | { 1260 | "name": "Symfony Community", 1261 | "homepage": "https://symfony.com/contributors" 1262 | } 1263 | ], 1264 | "description": "Symfony EventDispatcher Component", 1265 | "homepage": "https://symfony.com", 1266 | "time": "2015-10-11 09:39:48" 1267 | }, 1268 | { 1269 | "name": "symfony/finder", 1270 | "version": "v2.7.6", 1271 | "source": { 1272 | "type": "git", 1273 | "url": "https://github.com/symfony/finder.git", 1274 | "reference": "2ffb4e9598db3c48eb6d0ae73b04bbf09280c59d" 1275 | }, 1276 | "dist": { 1277 | "type": "zip", 1278 | "url": "https://api.github.com/repos/symfony/finder/zipball/2ffb4e9598db3c48eb6d0ae73b04bbf09280c59d", 1279 | "reference": "2ffb4e9598db3c48eb6d0ae73b04bbf09280c59d", 1280 | "shasum": "" 1281 | }, 1282 | "require": { 1283 | "php": ">=5.3.9" 1284 | }, 1285 | "type": "library", 1286 | "extra": { 1287 | "branch-alias": { 1288 | "dev-master": "2.7-dev" 1289 | } 1290 | }, 1291 | "autoload": { 1292 | "psr-4": { 1293 | "Symfony\\Component\\Finder\\": "" 1294 | } 1295 | }, 1296 | "notification-url": "https://packagist.org/downloads/", 1297 | "license": [ 1298 | "MIT" 1299 | ], 1300 | "authors": [ 1301 | { 1302 | "name": "Fabien Potencier", 1303 | "email": "fabien@symfony.com" 1304 | }, 1305 | { 1306 | "name": "Symfony Community", 1307 | "homepage": "https://symfony.com/contributors" 1308 | } 1309 | ], 1310 | "description": "Symfony Finder Component", 1311 | "homepage": "https://symfony.com", 1312 | "time": "2015-10-11 09:39:48" 1313 | }, 1314 | { 1315 | "name": "symfony/http-foundation", 1316 | "version": "v2.7.6", 1317 | "source": { 1318 | "type": "git", 1319 | "url": "https://github.com/symfony/http-foundation.git", 1320 | "reference": "7598eea151ae3d4134df1f9957364b17809eea75" 1321 | }, 1322 | "dist": { 1323 | "type": "zip", 1324 | "url": "https://api.github.com/repos/symfony/http-foundation/zipball/7598eea151ae3d4134df1f9957364b17809eea75", 1325 | "reference": "7598eea151ae3d4134df1f9957364b17809eea75", 1326 | "shasum": "" 1327 | }, 1328 | "require": { 1329 | "php": ">=5.3.9" 1330 | }, 1331 | "require-dev": { 1332 | "symfony/expression-language": "~2.4" 1333 | }, 1334 | "type": "library", 1335 | "extra": { 1336 | "branch-alias": { 1337 | "dev-master": "2.7-dev" 1338 | } 1339 | }, 1340 | "autoload": { 1341 | "psr-4": { 1342 | "Symfony\\Component\\HttpFoundation\\": "" 1343 | }, 1344 | "classmap": [ 1345 | "Resources/stubs" 1346 | ] 1347 | }, 1348 | "notification-url": "https://packagist.org/downloads/", 1349 | "license": [ 1350 | "MIT" 1351 | ], 1352 | "authors": [ 1353 | { 1354 | "name": "Fabien Potencier", 1355 | "email": "fabien@symfony.com" 1356 | }, 1357 | { 1358 | "name": "Symfony Community", 1359 | "homepage": "https://symfony.com/contributors" 1360 | } 1361 | ], 1362 | "description": "Symfony HttpFoundation Component", 1363 | "homepage": "https://symfony.com", 1364 | "time": "2015-10-23 14:47:27" 1365 | }, 1366 | { 1367 | "name": "symfony/http-kernel", 1368 | "version": "v2.7.6", 1369 | "source": { 1370 | "type": "git", 1371 | "url": "https://github.com/symfony/http-kernel.git", 1372 | "reference": "4260f2273a446a6715063dc9ca89fd0c475c2f77" 1373 | }, 1374 | "dist": { 1375 | "type": "zip", 1376 | "url": "https://api.github.com/repos/symfony/http-kernel/zipball/4260f2273a446a6715063dc9ca89fd0c475c2f77", 1377 | "reference": "4260f2273a446a6715063dc9ca89fd0c475c2f77", 1378 | "shasum": "" 1379 | }, 1380 | "require": { 1381 | "php": ">=5.3.9", 1382 | "psr/log": "~1.0", 1383 | "symfony/debug": "~2.6,>=2.6.2", 1384 | "symfony/event-dispatcher": "~2.6,>=2.6.7", 1385 | "symfony/http-foundation": "~2.5,>=2.5.4" 1386 | }, 1387 | "conflict": { 1388 | "symfony/config": "<2.7" 1389 | }, 1390 | "require-dev": { 1391 | "symfony/browser-kit": "~2.3", 1392 | "symfony/class-loader": "~2.1", 1393 | "symfony/config": "~2.7", 1394 | "symfony/console": "~2.3", 1395 | "symfony/css-selector": "~2.0,>=2.0.5", 1396 | "symfony/dependency-injection": "~2.2", 1397 | "symfony/dom-crawler": "~2.0,>=2.0.5", 1398 | "symfony/expression-language": "~2.4", 1399 | "symfony/finder": "~2.0,>=2.0.5", 1400 | "symfony/process": "~2.0,>=2.0.5", 1401 | "symfony/routing": "~2.2", 1402 | "symfony/stopwatch": "~2.3", 1403 | "symfony/templating": "~2.2", 1404 | "symfony/translation": "~2.0,>=2.0.5", 1405 | "symfony/var-dumper": "~2.6" 1406 | }, 1407 | "suggest": { 1408 | "symfony/browser-kit": "", 1409 | "symfony/class-loader": "", 1410 | "symfony/config": "", 1411 | "symfony/console": "", 1412 | "symfony/dependency-injection": "", 1413 | "symfony/finder": "", 1414 | "symfony/var-dumper": "" 1415 | }, 1416 | "type": "library", 1417 | "extra": { 1418 | "branch-alias": { 1419 | "dev-master": "2.7-dev" 1420 | } 1421 | }, 1422 | "autoload": { 1423 | "psr-4": { 1424 | "Symfony\\Component\\HttpKernel\\": "" 1425 | } 1426 | }, 1427 | "notification-url": "https://packagist.org/downloads/", 1428 | "license": [ 1429 | "MIT" 1430 | ], 1431 | "authors": [ 1432 | { 1433 | "name": "Fabien Potencier", 1434 | "email": "fabien@symfony.com" 1435 | }, 1436 | { 1437 | "name": "Symfony Community", 1438 | "homepage": "https://symfony.com/contributors" 1439 | } 1440 | ], 1441 | "description": "Symfony HttpKernel Component", 1442 | "homepage": "https://symfony.com", 1443 | "time": "2015-10-27 19:07:21" 1444 | }, 1445 | { 1446 | "name": "symfony/process", 1447 | "version": "v2.7.6", 1448 | "source": { 1449 | "type": "git", 1450 | "url": "https://github.com/symfony/process.git", 1451 | "reference": "4a959dd4e19c2c5d7512689413921e0a74386ec7" 1452 | }, 1453 | "dist": { 1454 | "type": "zip", 1455 | "url": "https://api.github.com/repos/symfony/process/zipball/4a959dd4e19c2c5d7512689413921e0a74386ec7", 1456 | "reference": "4a959dd4e19c2c5d7512689413921e0a74386ec7", 1457 | "shasum": "" 1458 | }, 1459 | "require": { 1460 | "php": ">=5.3.9" 1461 | }, 1462 | "type": "library", 1463 | "extra": { 1464 | "branch-alias": { 1465 | "dev-master": "2.7-dev" 1466 | } 1467 | }, 1468 | "autoload": { 1469 | "psr-4": { 1470 | "Symfony\\Component\\Process\\": "" 1471 | } 1472 | }, 1473 | "notification-url": "https://packagist.org/downloads/", 1474 | "license": [ 1475 | "MIT" 1476 | ], 1477 | "authors": [ 1478 | { 1479 | "name": "Fabien Potencier", 1480 | "email": "fabien@symfony.com" 1481 | }, 1482 | { 1483 | "name": "Symfony Community", 1484 | "homepage": "https://symfony.com/contributors" 1485 | } 1486 | ], 1487 | "description": "Symfony Process Component", 1488 | "homepage": "https://symfony.com", 1489 | "time": "2015-10-23 14:47:27" 1490 | }, 1491 | { 1492 | "name": "symfony/routing", 1493 | "version": "v2.7.6", 1494 | "source": { 1495 | "type": "git", 1496 | "url": "https://github.com/symfony/routing.git", 1497 | "reference": "f353e1f588679c3ec987624e6c617646bd01ba38" 1498 | }, 1499 | "dist": { 1500 | "type": "zip", 1501 | "url": "https://api.github.com/repos/symfony/routing/zipball/f353e1f588679c3ec987624e6c617646bd01ba38", 1502 | "reference": "f353e1f588679c3ec987624e6c617646bd01ba38", 1503 | "shasum": "" 1504 | }, 1505 | "require": { 1506 | "php": ">=5.3.9" 1507 | }, 1508 | "conflict": { 1509 | "symfony/config": "<2.7" 1510 | }, 1511 | "require-dev": { 1512 | "doctrine/annotations": "~1.0", 1513 | "doctrine/common": "~2.2", 1514 | "psr/log": "~1.0", 1515 | "symfony/config": "~2.7", 1516 | "symfony/expression-language": "~2.4", 1517 | "symfony/http-foundation": "~2.3", 1518 | "symfony/yaml": "~2.0,>=2.0.5" 1519 | }, 1520 | "suggest": { 1521 | "doctrine/annotations": "For using the annotation loader", 1522 | "symfony/config": "For using the all-in-one router or any loader", 1523 | "symfony/expression-language": "For using expression matching", 1524 | "symfony/yaml": "For using the YAML loader" 1525 | }, 1526 | "type": "library", 1527 | "extra": { 1528 | "branch-alias": { 1529 | "dev-master": "2.7-dev" 1530 | } 1531 | }, 1532 | "autoload": { 1533 | "psr-4": { 1534 | "Symfony\\Component\\Routing\\": "" 1535 | } 1536 | }, 1537 | "notification-url": "https://packagist.org/downloads/", 1538 | "license": [ 1539 | "MIT" 1540 | ], 1541 | "authors": [ 1542 | { 1543 | "name": "Fabien Potencier", 1544 | "email": "fabien@symfony.com" 1545 | }, 1546 | { 1547 | "name": "Symfony Community", 1548 | "homepage": "https://symfony.com/contributors" 1549 | } 1550 | ], 1551 | "description": "Symfony Routing Component", 1552 | "homepage": "https://symfony.com", 1553 | "keywords": [ 1554 | "router", 1555 | "routing", 1556 | "uri", 1557 | "url" 1558 | ], 1559 | "time": "2015-10-27 15:38:06" 1560 | }, 1561 | { 1562 | "name": "symfony/translation", 1563 | "version": "v2.7.6", 1564 | "source": { 1565 | "type": "git", 1566 | "url": "https://github.com/symfony/translation.git", 1567 | "reference": "6ccd9289ec1c71d01a49d83480de3b5293ce30c8" 1568 | }, 1569 | "dist": { 1570 | "type": "zip", 1571 | "url": "https://api.github.com/repos/symfony/translation/zipball/6ccd9289ec1c71d01a49d83480de3b5293ce30c8", 1572 | "reference": "6ccd9289ec1c71d01a49d83480de3b5293ce30c8", 1573 | "shasum": "" 1574 | }, 1575 | "require": { 1576 | "php": ">=5.3.9" 1577 | }, 1578 | "conflict": { 1579 | "symfony/config": "<2.7" 1580 | }, 1581 | "require-dev": { 1582 | "psr/log": "~1.0", 1583 | "symfony/config": "~2.7", 1584 | "symfony/intl": "~2.4", 1585 | "symfony/yaml": "~2.2" 1586 | }, 1587 | "suggest": { 1588 | "psr/log": "To use logging capability in translator", 1589 | "symfony/config": "", 1590 | "symfony/yaml": "" 1591 | }, 1592 | "type": "library", 1593 | "extra": { 1594 | "branch-alias": { 1595 | "dev-master": "2.7-dev" 1596 | } 1597 | }, 1598 | "autoload": { 1599 | "psr-4": { 1600 | "Symfony\\Component\\Translation\\": "" 1601 | } 1602 | }, 1603 | "notification-url": "https://packagist.org/downloads/", 1604 | "license": [ 1605 | "MIT" 1606 | ], 1607 | "authors": [ 1608 | { 1609 | "name": "Fabien Potencier", 1610 | "email": "fabien@symfony.com" 1611 | }, 1612 | { 1613 | "name": "Symfony Community", 1614 | "homepage": "https://symfony.com/contributors" 1615 | } 1616 | ], 1617 | "description": "Symfony Translation Component", 1618 | "homepage": "https://symfony.com", 1619 | "time": "2015-10-27 15:38:06" 1620 | }, 1621 | { 1622 | "name": "symfony/var-dumper", 1623 | "version": "v2.7.6", 1624 | "source": { 1625 | "type": "git", 1626 | "url": "https://github.com/symfony/var-dumper.git", 1627 | "reference": "eb033050050916b6bfa51be71009ef67b16046c9" 1628 | }, 1629 | "dist": { 1630 | "type": "zip", 1631 | "url": "https://api.github.com/repos/symfony/var-dumper/zipball/eb033050050916b6bfa51be71009ef67b16046c9", 1632 | "reference": "eb033050050916b6bfa51be71009ef67b16046c9", 1633 | "shasum": "" 1634 | }, 1635 | "require": { 1636 | "php": ">=5.3.9" 1637 | }, 1638 | "suggest": { 1639 | "ext-symfony_debug": "" 1640 | }, 1641 | "type": "library", 1642 | "extra": { 1643 | "branch-alias": { 1644 | "dev-master": "2.7-dev" 1645 | } 1646 | }, 1647 | "autoload": { 1648 | "files": [ 1649 | "Resources/functions/dump.php" 1650 | ], 1651 | "psr-4": { 1652 | "Symfony\\Component\\VarDumper\\": "" 1653 | } 1654 | }, 1655 | "notification-url": "https://packagist.org/downloads/", 1656 | "license": [ 1657 | "MIT" 1658 | ], 1659 | "authors": [ 1660 | { 1661 | "name": "Nicolas Grekas", 1662 | "email": "p@tchwork.com" 1663 | }, 1664 | { 1665 | "name": "Symfony Community", 1666 | "homepage": "https://symfony.com/contributors" 1667 | } 1668 | ], 1669 | "description": "Symfony mechanism for exploring and dumping PHP variables", 1670 | "homepage": "https://symfony.com", 1671 | "keywords": [ 1672 | "debug", 1673 | "dump" 1674 | ], 1675 | "time": "2015-10-25 17:17:38" 1676 | }, 1677 | { 1678 | "name": "vlucas/phpdotenv", 1679 | "version": "v1.1.1", 1680 | "source": { 1681 | "type": "git", 1682 | "url": "https://github.com/vlucas/phpdotenv.git", 1683 | "reference": "0cac554ce06277e33ddf9f0b7ade4b8bbf2af3fa" 1684 | }, 1685 | "dist": { 1686 | "type": "zip", 1687 | "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/0cac554ce06277e33ddf9f0b7ade4b8bbf2af3fa", 1688 | "reference": "0cac554ce06277e33ddf9f0b7ade4b8bbf2af3fa", 1689 | "shasum": "" 1690 | }, 1691 | "require": { 1692 | "php": ">=5.3.2" 1693 | }, 1694 | "require-dev": { 1695 | "phpunit/phpunit": "~4.0" 1696 | }, 1697 | "type": "library", 1698 | "autoload": { 1699 | "psr-0": { 1700 | "Dotenv": "src/" 1701 | } 1702 | }, 1703 | "notification-url": "https://packagist.org/downloads/", 1704 | "license": [ 1705 | "BSD" 1706 | ], 1707 | "authors": [ 1708 | { 1709 | "name": "Vance Lucas", 1710 | "email": "vance@vancelucas.com", 1711 | "homepage": "http://www.vancelucas.com" 1712 | } 1713 | ], 1714 | "description": "Loads environment variables from `.env` to `getenv()`, `$_ENV` and `$_SERVER` automagically.", 1715 | "homepage": "http://github.com/vlucas/phpdotenv", 1716 | "keywords": [ 1717 | "dotenv", 1718 | "env", 1719 | "environment" 1720 | ], 1721 | "time": "2015-05-30 15:59:26" 1722 | } 1723 | ], 1724 | "packages-dev": [ 1725 | { 1726 | "name": "doctrine/instantiator", 1727 | "version": "1.0.5", 1728 | "source": { 1729 | "type": "git", 1730 | "url": "https://github.com/doctrine/instantiator.git", 1731 | "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d" 1732 | }, 1733 | "dist": { 1734 | "type": "zip", 1735 | "url": "https://api.github.com/repos/doctrine/instantiator/zipball/8e884e78f9f0eb1329e445619e04456e64d8051d", 1736 | "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d", 1737 | "shasum": "" 1738 | }, 1739 | "require": { 1740 | "php": ">=5.3,<8.0-DEV" 1741 | }, 1742 | "require-dev": { 1743 | "athletic/athletic": "~0.1.8", 1744 | "ext-pdo": "*", 1745 | "ext-phar": "*", 1746 | "phpunit/phpunit": "~4.0", 1747 | "squizlabs/php_codesniffer": "~2.0" 1748 | }, 1749 | "type": "library", 1750 | "extra": { 1751 | "branch-alias": { 1752 | "dev-master": "1.0.x-dev" 1753 | } 1754 | }, 1755 | "autoload": { 1756 | "psr-4": { 1757 | "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" 1758 | } 1759 | }, 1760 | "notification-url": "https://packagist.org/downloads/", 1761 | "license": [ 1762 | "MIT" 1763 | ], 1764 | "authors": [ 1765 | { 1766 | "name": "Marco Pivetta", 1767 | "email": "ocramius@gmail.com", 1768 | "homepage": "http://ocramius.github.com/" 1769 | } 1770 | ], 1771 | "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", 1772 | "homepage": "https://github.com/doctrine/instantiator", 1773 | "keywords": [ 1774 | "constructor", 1775 | "instantiate" 1776 | ], 1777 | "time": "2015-06-14 21:17:01" 1778 | }, 1779 | { 1780 | "name": "phpdocumentor/reflection-docblock", 1781 | "version": "2.0.4", 1782 | "source": { 1783 | "type": "git", 1784 | "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", 1785 | "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8" 1786 | }, 1787 | "dist": { 1788 | "type": "zip", 1789 | "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/d68dbdc53dc358a816f00b300704702b2eaff7b8", 1790 | "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8", 1791 | "shasum": "" 1792 | }, 1793 | "require": { 1794 | "php": ">=5.3.3" 1795 | }, 1796 | "require-dev": { 1797 | "phpunit/phpunit": "~4.0" 1798 | }, 1799 | "suggest": { 1800 | "dflydev/markdown": "~1.0", 1801 | "erusev/parsedown": "~1.0" 1802 | }, 1803 | "type": "library", 1804 | "extra": { 1805 | "branch-alias": { 1806 | "dev-master": "2.0.x-dev" 1807 | } 1808 | }, 1809 | "autoload": { 1810 | "psr-0": { 1811 | "phpDocumentor": [ 1812 | "src/" 1813 | ] 1814 | } 1815 | }, 1816 | "notification-url": "https://packagist.org/downloads/", 1817 | "license": [ 1818 | "MIT" 1819 | ], 1820 | "authors": [ 1821 | { 1822 | "name": "Mike van Riel", 1823 | "email": "mike.vanriel@naenius.com" 1824 | } 1825 | ], 1826 | "time": "2015-02-03 12:10:50" 1827 | }, 1828 | { 1829 | "name": "phpspec/prophecy", 1830 | "version": "v1.5.0", 1831 | "source": { 1832 | "type": "git", 1833 | "url": "https://github.com/phpspec/prophecy.git", 1834 | "reference": "4745ded9307786b730d7a60df5cb5a6c43cf95f7" 1835 | }, 1836 | "dist": { 1837 | "type": "zip", 1838 | "url": "https://api.github.com/repos/phpspec/prophecy/zipball/4745ded9307786b730d7a60df5cb5a6c43cf95f7", 1839 | "reference": "4745ded9307786b730d7a60df5cb5a6c43cf95f7", 1840 | "shasum": "" 1841 | }, 1842 | "require": { 1843 | "doctrine/instantiator": "^1.0.2", 1844 | "phpdocumentor/reflection-docblock": "~2.0", 1845 | "sebastian/comparator": "~1.1" 1846 | }, 1847 | "require-dev": { 1848 | "phpspec/phpspec": "~2.0" 1849 | }, 1850 | "type": "library", 1851 | "extra": { 1852 | "branch-alias": { 1853 | "dev-master": "1.4.x-dev" 1854 | } 1855 | }, 1856 | "autoload": { 1857 | "psr-0": { 1858 | "Prophecy\\": "src/" 1859 | } 1860 | }, 1861 | "notification-url": "https://packagist.org/downloads/", 1862 | "license": [ 1863 | "MIT" 1864 | ], 1865 | "authors": [ 1866 | { 1867 | "name": "Konstantin Kudryashov", 1868 | "email": "ever.zet@gmail.com", 1869 | "homepage": "http://everzet.com" 1870 | }, 1871 | { 1872 | "name": "Marcello Duarte", 1873 | "email": "marcello.duarte@gmail.com" 1874 | } 1875 | ], 1876 | "description": "Highly opinionated mocking framework for PHP 5.3+", 1877 | "homepage": "https://github.com/phpspec/prophecy", 1878 | "keywords": [ 1879 | "Double", 1880 | "Dummy", 1881 | "fake", 1882 | "mock", 1883 | "spy", 1884 | "stub" 1885 | ], 1886 | "time": "2015-08-13 10:07:40" 1887 | }, 1888 | { 1889 | "name": "phpunit/php-code-coverage", 1890 | "version": "2.2.4", 1891 | "source": { 1892 | "type": "git", 1893 | "url": "https://github.com/sebastianbergmann/php-code-coverage.git", 1894 | "reference": "eabf68b476ac7d0f73793aada060f1c1a9bf8979" 1895 | }, 1896 | "dist": { 1897 | "type": "zip", 1898 | "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/eabf68b476ac7d0f73793aada060f1c1a9bf8979", 1899 | "reference": "eabf68b476ac7d0f73793aada060f1c1a9bf8979", 1900 | "shasum": "" 1901 | }, 1902 | "require": { 1903 | "php": ">=5.3.3", 1904 | "phpunit/php-file-iterator": "~1.3", 1905 | "phpunit/php-text-template": "~1.2", 1906 | "phpunit/php-token-stream": "~1.3", 1907 | "sebastian/environment": "^1.3.2", 1908 | "sebastian/version": "~1.0" 1909 | }, 1910 | "require-dev": { 1911 | "ext-xdebug": ">=2.1.4", 1912 | "phpunit/phpunit": "~4" 1913 | }, 1914 | "suggest": { 1915 | "ext-dom": "*", 1916 | "ext-xdebug": ">=2.2.1", 1917 | "ext-xmlwriter": "*" 1918 | }, 1919 | "type": "library", 1920 | "extra": { 1921 | "branch-alias": { 1922 | "dev-master": "2.2.x-dev" 1923 | } 1924 | }, 1925 | "autoload": { 1926 | "classmap": [ 1927 | "src/" 1928 | ] 1929 | }, 1930 | "notification-url": "https://packagist.org/downloads/", 1931 | "license": [ 1932 | "BSD-3-Clause" 1933 | ], 1934 | "authors": [ 1935 | { 1936 | "name": "Sebastian Bergmann", 1937 | "email": "sb@sebastian-bergmann.de", 1938 | "role": "lead" 1939 | } 1940 | ], 1941 | "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", 1942 | "homepage": "https://github.com/sebastianbergmann/php-code-coverage", 1943 | "keywords": [ 1944 | "coverage", 1945 | "testing", 1946 | "xunit" 1947 | ], 1948 | "time": "2015-10-06 15:47:00" 1949 | }, 1950 | { 1951 | "name": "phpunit/php-file-iterator", 1952 | "version": "1.4.1", 1953 | "source": { 1954 | "type": "git", 1955 | "url": "https://github.com/sebastianbergmann/php-file-iterator.git", 1956 | "reference": "6150bf2c35d3fc379e50c7602b75caceaa39dbf0" 1957 | }, 1958 | "dist": { 1959 | "type": "zip", 1960 | "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/6150bf2c35d3fc379e50c7602b75caceaa39dbf0", 1961 | "reference": "6150bf2c35d3fc379e50c7602b75caceaa39dbf0", 1962 | "shasum": "" 1963 | }, 1964 | "require": { 1965 | "php": ">=5.3.3" 1966 | }, 1967 | "type": "library", 1968 | "extra": { 1969 | "branch-alias": { 1970 | "dev-master": "1.4.x-dev" 1971 | } 1972 | }, 1973 | "autoload": { 1974 | "classmap": [ 1975 | "src/" 1976 | ] 1977 | }, 1978 | "notification-url": "https://packagist.org/downloads/", 1979 | "license": [ 1980 | "BSD-3-Clause" 1981 | ], 1982 | "authors": [ 1983 | { 1984 | "name": "Sebastian Bergmann", 1985 | "email": "sb@sebastian-bergmann.de", 1986 | "role": "lead" 1987 | } 1988 | ], 1989 | "description": "FilterIterator implementation that filters files based on a list of suffixes.", 1990 | "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", 1991 | "keywords": [ 1992 | "filesystem", 1993 | "iterator" 1994 | ], 1995 | "time": "2015-06-21 13:08:43" 1996 | }, 1997 | { 1998 | "name": "phpunit/php-text-template", 1999 | "version": "1.2.1", 2000 | "source": { 2001 | "type": "git", 2002 | "url": "https://github.com/sebastianbergmann/php-text-template.git", 2003 | "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" 2004 | }, 2005 | "dist": { 2006 | "type": "zip", 2007 | "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", 2008 | "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", 2009 | "shasum": "" 2010 | }, 2011 | "require": { 2012 | "php": ">=5.3.3" 2013 | }, 2014 | "type": "library", 2015 | "autoload": { 2016 | "classmap": [ 2017 | "src/" 2018 | ] 2019 | }, 2020 | "notification-url": "https://packagist.org/downloads/", 2021 | "license": [ 2022 | "BSD-3-Clause" 2023 | ], 2024 | "authors": [ 2025 | { 2026 | "name": "Sebastian Bergmann", 2027 | "email": "sebastian@phpunit.de", 2028 | "role": "lead" 2029 | } 2030 | ], 2031 | "description": "Simple template engine.", 2032 | "homepage": "https://github.com/sebastianbergmann/php-text-template/", 2033 | "keywords": [ 2034 | "template" 2035 | ], 2036 | "time": "2015-06-21 13:50:34" 2037 | }, 2038 | { 2039 | "name": "phpunit/php-timer", 2040 | "version": "1.0.7", 2041 | "source": { 2042 | "type": "git", 2043 | "url": "https://github.com/sebastianbergmann/php-timer.git", 2044 | "reference": "3e82f4e9fc92665fafd9157568e4dcb01d014e5b" 2045 | }, 2046 | "dist": { 2047 | "type": "zip", 2048 | "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/3e82f4e9fc92665fafd9157568e4dcb01d014e5b", 2049 | "reference": "3e82f4e9fc92665fafd9157568e4dcb01d014e5b", 2050 | "shasum": "" 2051 | }, 2052 | "require": { 2053 | "php": ">=5.3.3" 2054 | }, 2055 | "type": "library", 2056 | "autoload": { 2057 | "classmap": [ 2058 | "src/" 2059 | ] 2060 | }, 2061 | "notification-url": "https://packagist.org/downloads/", 2062 | "license": [ 2063 | "BSD-3-Clause" 2064 | ], 2065 | "authors": [ 2066 | { 2067 | "name": "Sebastian Bergmann", 2068 | "email": "sb@sebastian-bergmann.de", 2069 | "role": "lead" 2070 | } 2071 | ], 2072 | "description": "Utility class for timing", 2073 | "homepage": "https://github.com/sebastianbergmann/php-timer/", 2074 | "keywords": [ 2075 | "timer" 2076 | ], 2077 | "time": "2015-06-21 08:01:12" 2078 | }, 2079 | { 2080 | "name": "phpunit/php-token-stream", 2081 | "version": "1.4.8", 2082 | "source": { 2083 | "type": "git", 2084 | "url": "https://github.com/sebastianbergmann/php-token-stream.git", 2085 | "reference": "3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da" 2086 | }, 2087 | "dist": { 2088 | "type": "zip", 2089 | "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da", 2090 | "reference": "3144ae21711fb6cac0b1ab4cbe63b75ce3d4e8da", 2091 | "shasum": "" 2092 | }, 2093 | "require": { 2094 | "ext-tokenizer": "*", 2095 | "php": ">=5.3.3" 2096 | }, 2097 | "require-dev": { 2098 | "phpunit/phpunit": "~4.2" 2099 | }, 2100 | "type": "library", 2101 | "extra": { 2102 | "branch-alias": { 2103 | "dev-master": "1.4-dev" 2104 | } 2105 | }, 2106 | "autoload": { 2107 | "classmap": [ 2108 | "src/" 2109 | ] 2110 | }, 2111 | "notification-url": "https://packagist.org/downloads/", 2112 | "license": [ 2113 | "BSD-3-Clause" 2114 | ], 2115 | "authors": [ 2116 | { 2117 | "name": "Sebastian Bergmann", 2118 | "email": "sebastian@phpunit.de" 2119 | } 2120 | ], 2121 | "description": "Wrapper around PHP's tokenizer extension.", 2122 | "homepage": "https://github.com/sebastianbergmann/php-token-stream/", 2123 | "keywords": [ 2124 | "tokenizer" 2125 | ], 2126 | "time": "2015-09-15 10:49:45" 2127 | }, 2128 | { 2129 | "name": "phpunit/phpunit", 2130 | "version": "4.8.16", 2131 | "source": { 2132 | "type": "git", 2133 | "url": "https://github.com/sebastianbergmann/phpunit.git", 2134 | "reference": "625f8c345606ed0f3a141dfb88f4116f0e22978e" 2135 | }, 2136 | "dist": { 2137 | "type": "zip", 2138 | "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/625f8c345606ed0f3a141dfb88f4116f0e22978e", 2139 | "reference": "625f8c345606ed0f3a141dfb88f4116f0e22978e", 2140 | "shasum": "" 2141 | }, 2142 | "require": { 2143 | "ext-dom": "*", 2144 | "ext-json": "*", 2145 | "ext-pcre": "*", 2146 | "ext-reflection": "*", 2147 | "ext-spl": "*", 2148 | "php": ">=5.3.3", 2149 | "phpspec/prophecy": "^1.3.1", 2150 | "phpunit/php-code-coverage": "~2.1", 2151 | "phpunit/php-file-iterator": "~1.4", 2152 | "phpunit/php-text-template": "~1.2", 2153 | "phpunit/php-timer": ">=1.0.6", 2154 | "phpunit/phpunit-mock-objects": "~2.3", 2155 | "sebastian/comparator": "~1.1", 2156 | "sebastian/diff": "~1.2", 2157 | "sebastian/environment": "~1.3", 2158 | "sebastian/exporter": "~1.2", 2159 | "sebastian/global-state": "~1.0", 2160 | "sebastian/version": "~1.0", 2161 | "symfony/yaml": "~2.1|~3.0" 2162 | }, 2163 | "suggest": { 2164 | "phpunit/php-invoker": "~1.1" 2165 | }, 2166 | "bin": [ 2167 | "phpunit" 2168 | ], 2169 | "type": "library", 2170 | "extra": { 2171 | "branch-alias": { 2172 | "dev-master": "4.8.x-dev" 2173 | } 2174 | }, 2175 | "autoload": { 2176 | "classmap": [ 2177 | "src/" 2178 | ] 2179 | }, 2180 | "notification-url": "https://packagist.org/downloads/", 2181 | "license": [ 2182 | "BSD-3-Clause" 2183 | ], 2184 | "authors": [ 2185 | { 2186 | "name": "Sebastian Bergmann", 2187 | "email": "sebastian@phpunit.de", 2188 | "role": "lead" 2189 | } 2190 | ], 2191 | "description": "The PHP Unit Testing framework.", 2192 | "homepage": "https://phpunit.de/", 2193 | "keywords": [ 2194 | "phpunit", 2195 | "testing", 2196 | "xunit" 2197 | ], 2198 | "time": "2015-10-23 06:48:33" 2199 | }, 2200 | { 2201 | "name": "phpunit/phpunit-mock-objects", 2202 | "version": "2.3.8", 2203 | "source": { 2204 | "type": "git", 2205 | "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", 2206 | "reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983" 2207 | }, 2208 | "dist": { 2209 | "type": "zip", 2210 | "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/ac8e7a3db35738d56ee9a76e78a4e03d97628983", 2211 | "reference": "ac8e7a3db35738d56ee9a76e78a4e03d97628983", 2212 | "shasum": "" 2213 | }, 2214 | "require": { 2215 | "doctrine/instantiator": "^1.0.2", 2216 | "php": ">=5.3.3", 2217 | "phpunit/php-text-template": "~1.2", 2218 | "sebastian/exporter": "~1.2" 2219 | }, 2220 | "require-dev": { 2221 | "phpunit/phpunit": "~4.4" 2222 | }, 2223 | "suggest": { 2224 | "ext-soap": "*" 2225 | }, 2226 | "type": "library", 2227 | "extra": { 2228 | "branch-alias": { 2229 | "dev-master": "2.3.x-dev" 2230 | } 2231 | }, 2232 | "autoload": { 2233 | "classmap": [ 2234 | "src/" 2235 | ] 2236 | }, 2237 | "notification-url": "https://packagist.org/downloads/", 2238 | "license": [ 2239 | "BSD-3-Clause" 2240 | ], 2241 | "authors": [ 2242 | { 2243 | "name": "Sebastian Bergmann", 2244 | "email": "sb@sebastian-bergmann.de", 2245 | "role": "lead" 2246 | } 2247 | ], 2248 | "description": "Mock Object library for PHPUnit", 2249 | "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/", 2250 | "keywords": [ 2251 | "mock", 2252 | "xunit" 2253 | ], 2254 | "time": "2015-10-02 06:51:40" 2255 | }, 2256 | { 2257 | "name": "sebastian/comparator", 2258 | "version": "1.2.0", 2259 | "source": { 2260 | "type": "git", 2261 | "url": "https://github.com/sebastianbergmann/comparator.git", 2262 | "reference": "937efb279bd37a375bcadf584dec0726f84dbf22" 2263 | }, 2264 | "dist": { 2265 | "type": "zip", 2266 | "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/937efb279bd37a375bcadf584dec0726f84dbf22", 2267 | "reference": "937efb279bd37a375bcadf584dec0726f84dbf22", 2268 | "shasum": "" 2269 | }, 2270 | "require": { 2271 | "php": ">=5.3.3", 2272 | "sebastian/diff": "~1.2", 2273 | "sebastian/exporter": "~1.2" 2274 | }, 2275 | "require-dev": { 2276 | "phpunit/phpunit": "~4.4" 2277 | }, 2278 | "type": "library", 2279 | "extra": { 2280 | "branch-alias": { 2281 | "dev-master": "1.2.x-dev" 2282 | } 2283 | }, 2284 | "autoload": { 2285 | "classmap": [ 2286 | "src/" 2287 | ] 2288 | }, 2289 | "notification-url": "https://packagist.org/downloads/", 2290 | "license": [ 2291 | "BSD-3-Clause" 2292 | ], 2293 | "authors": [ 2294 | { 2295 | "name": "Jeff Welch", 2296 | "email": "whatthejeff@gmail.com" 2297 | }, 2298 | { 2299 | "name": "Volker Dusch", 2300 | "email": "github@wallbash.com" 2301 | }, 2302 | { 2303 | "name": "Bernhard Schussek", 2304 | "email": "bschussek@2bepublished.at" 2305 | }, 2306 | { 2307 | "name": "Sebastian Bergmann", 2308 | "email": "sebastian@phpunit.de" 2309 | } 2310 | ], 2311 | "description": "Provides the functionality to compare PHP values for equality", 2312 | "homepage": "http://www.github.com/sebastianbergmann/comparator", 2313 | "keywords": [ 2314 | "comparator", 2315 | "compare", 2316 | "equality" 2317 | ], 2318 | "time": "2015-07-26 15:48:44" 2319 | }, 2320 | { 2321 | "name": "sebastian/diff", 2322 | "version": "1.3.0", 2323 | "source": { 2324 | "type": "git", 2325 | "url": "https://github.com/sebastianbergmann/diff.git", 2326 | "reference": "863df9687835c62aa423a22412d26fa2ebde3fd3" 2327 | }, 2328 | "dist": { 2329 | "type": "zip", 2330 | "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/863df9687835c62aa423a22412d26fa2ebde3fd3", 2331 | "reference": "863df9687835c62aa423a22412d26fa2ebde3fd3", 2332 | "shasum": "" 2333 | }, 2334 | "require": { 2335 | "php": ">=5.3.3" 2336 | }, 2337 | "require-dev": { 2338 | "phpunit/phpunit": "~4.2" 2339 | }, 2340 | "type": "library", 2341 | "extra": { 2342 | "branch-alias": { 2343 | "dev-master": "1.3-dev" 2344 | } 2345 | }, 2346 | "autoload": { 2347 | "classmap": [ 2348 | "src/" 2349 | ] 2350 | }, 2351 | "notification-url": "https://packagist.org/downloads/", 2352 | "license": [ 2353 | "BSD-3-Clause" 2354 | ], 2355 | "authors": [ 2356 | { 2357 | "name": "Kore Nordmann", 2358 | "email": "mail@kore-nordmann.de" 2359 | }, 2360 | { 2361 | "name": "Sebastian Bergmann", 2362 | "email": "sebastian@phpunit.de" 2363 | } 2364 | ], 2365 | "description": "Diff implementation", 2366 | "homepage": "http://www.github.com/sebastianbergmann/diff", 2367 | "keywords": [ 2368 | "diff" 2369 | ], 2370 | "time": "2015-02-22 15:13:53" 2371 | }, 2372 | { 2373 | "name": "sebastian/environment", 2374 | "version": "1.3.2", 2375 | "source": { 2376 | "type": "git", 2377 | "url": "https://github.com/sebastianbergmann/environment.git", 2378 | "reference": "6324c907ce7a52478eeeaede764f48733ef5ae44" 2379 | }, 2380 | "dist": { 2381 | "type": "zip", 2382 | "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/6324c907ce7a52478eeeaede764f48733ef5ae44", 2383 | "reference": "6324c907ce7a52478eeeaede764f48733ef5ae44", 2384 | "shasum": "" 2385 | }, 2386 | "require": { 2387 | "php": ">=5.3.3" 2388 | }, 2389 | "require-dev": { 2390 | "phpunit/phpunit": "~4.4" 2391 | }, 2392 | "type": "library", 2393 | "extra": { 2394 | "branch-alias": { 2395 | "dev-master": "1.3.x-dev" 2396 | } 2397 | }, 2398 | "autoload": { 2399 | "classmap": [ 2400 | "src/" 2401 | ] 2402 | }, 2403 | "notification-url": "https://packagist.org/downloads/", 2404 | "license": [ 2405 | "BSD-3-Clause" 2406 | ], 2407 | "authors": [ 2408 | { 2409 | "name": "Sebastian Bergmann", 2410 | "email": "sebastian@phpunit.de" 2411 | } 2412 | ], 2413 | "description": "Provides functionality to handle HHVM/PHP environments", 2414 | "homepage": "http://www.github.com/sebastianbergmann/environment", 2415 | "keywords": [ 2416 | "Xdebug", 2417 | "environment", 2418 | "hhvm" 2419 | ], 2420 | "time": "2015-08-03 06:14:51" 2421 | }, 2422 | { 2423 | "name": "sebastian/exporter", 2424 | "version": "1.2.1", 2425 | "source": { 2426 | "type": "git", 2427 | "url": "https://github.com/sebastianbergmann/exporter.git", 2428 | "reference": "7ae5513327cb536431847bcc0c10edba2701064e" 2429 | }, 2430 | "dist": { 2431 | "type": "zip", 2432 | "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/7ae5513327cb536431847bcc0c10edba2701064e", 2433 | "reference": "7ae5513327cb536431847bcc0c10edba2701064e", 2434 | "shasum": "" 2435 | }, 2436 | "require": { 2437 | "php": ">=5.3.3", 2438 | "sebastian/recursion-context": "~1.0" 2439 | }, 2440 | "require-dev": { 2441 | "phpunit/phpunit": "~4.4" 2442 | }, 2443 | "type": "library", 2444 | "extra": { 2445 | "branch-alias": { 2446 | "dev-master": "1.2.x-dev" 2447 | } 2448 | }, 2449 | "autoload": { 2450 | "classmap": [ 2451 | "src/" 2452 | ] 2453 | }, 2454 | "notification-url": "https://packagist.org/downloads/", 2455 | "license": [ 2456 | "BSD-3-Clause" 2457 | ], 2458 | "authors": [ 2459 | { 2460 | "name": "Jeff Welch", 2461 | "email": "whatthejeff@gmail.com" 2462 | }, 2463 | { 2464 | "name": "Volker Dusch", 2465 | "email": "github@wallbash.com" 2466 | }, 2467 | { 2468 | "name": "Bernhard Schussek", 2469 | "email": "bschussek@2bepublished.at" 2470 | }, 2471 | { 2472 | "name": "Sebastian Bergmann", 2473 | "email": "sebastian@phpunit.de" 2474 | }, 2475 | { 2476 | "name": "Adam Harvey", 2477 | "email": "aharvey@php.net" 2478 | } 2479 | ], 2480 | "description": "Provides the functionality to export PHP variables for visualization", 2481 | "homepage": "http://www.github.com/sebastianbergmann/exporter", 2482 | "keywords": [ 2483 | "export", 2484 | "exporter" 2485 | ], 2486 | "time": "2015-06-21 07:55:53" 2487 | }, 2488 | { 2489 | "name": "sebastian/global-state", 2490 | "version": "1.1.1", 2491 | "source": { 2492 | "type": "git", 2493 | "url": "https://github.com/sebastianbergmann/global-state.git", 2494 | "reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4" 2495 | }, 2496 | "dist": { 2497 | "type": "zip", 2498 | "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bc37d50fea7d017d3d340f230811c9f1d7280af4", 2499 | "reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4", 2500 | "shasum": "" 2501 | }, 2502 | "require": { 2503 | "php": ">=5.3.3" 2504 | }, 2505 | "require-dev": { 2506 | "phpunit/phpunit": "~4.2" 2507 | }, 2508 | "suggest": { 2509 | "ext-uopz": "*" 2510 | }, 2511 | "type": "library", 2512 | "extra": { 2513 | "branch-alias": { 2514 | "dev-master": "1.0-dev" 2515 | } 2516 | }, 2517 | "autoload": { 2518 | "classmap": [ 2519 | "src/" 2520 | ] 2521 | }, 2522 | "notification-url": "https://packagist.org/downloads/", 2523 | "license": [ 2524 | "BSD-3-Clause" 2525 | ], 2526 | "authors": [ 2527 | { 2528 | "name": "Sebastian Bergmann", 2529 | "email": "sebastian@phpunit.de" 2530 | } 2531 | ], 2532 | "description": "Snapshotting of global state", 2533 | "homepage": "http://www.github.com/sebastianbergmann/global-state", 2534 | "keywords": [ 2535 | "global state" 2536 | ], 2537 | "time": "2015-10-12 03:26:01" 2538 | }, 2539 | { 2540 | "name": "sebastian/recursion-context", 2541 | "version": "1.0.1", 2542 | "source": { 2543 | "type": "git", 2544 | "url": "https://github.com/sebastianbergmann/recursion-context.git", 2545 | "reference": "994d4a811bafe801fb06dccbee797863ba2792ba" 2546 | }, 2547 | "dist": { 2548 | "type": "zip", 2549 | "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/994d4a811bafe801fb06dccbee797863ba2792ba", 2550 | "reference": "994d4a811bafe801fb06dccbee797863ba2792ba", 2551 | "shasum": "" 2552 | }, 2553 | "require": { 2554 | "php": ">=5.3.3" 2555 | }, 2556 | "require-dev": { 2557 | "phpunit/phpunit": "~4.4" 2558 | }, 2559 | "type": "library", 2560 | "extra": { 2561 | "branch-alias": { 2562 | "dev-master": "1.0.x-dev" 2563 | } 2564 | }, 2565 | "autoload": { 2566 | "classmap": [ 2567 | "src/" 2568 | ] 2569 | }, 2570 | "notification-url": "https://packagist.org/downloads/", 2571 | "license": [ 2572 | "BSD-3-Clause" 2573 | ], 2574 | "authors": [ 2575 | { 2576 | "name": "Jeff Welch", 2577 | "email": "whatthejeff@gmail.com" 2578 | }, 2579 | { 2580 | "name": "Sebastian Bergmann", 2581 | "email": "sebastian@phpunit.de" 2582 | }, 2583 | { 2584 | "name": "Adam Harvey", 2585 | "email": "aharvey@php.net" 2586 | } 2587 | ], 2588 | "description": "Provides functionality to recursively process PHP variables", 2589 | "homepage": "http://www.github.com/sebastianbergmann/recursion-context", 2590 | "time": "2015-06-21 08:04:50" 2591 | }, 2592 | { 2593 | "name": "sebastian/version", 2594 | "version": "1.0.6", 2595 | "source": { 2596 | "type": "git", 2597 | "url": "https://github.com/sebastianbergmann/version.git", 2598 | "reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6" 2599 | }, 2600 | "dist": { 2601 | "type": "zip", 2602 | "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/58b3a85e7999757d6ad81c787a1fbf5ff6c628c6", 2603 | "reference": "58b3a85e7999757d6ad81c787a1fbf5ff6c628c6", 2604 | "shasum": "" 2605 | }, 2606 | "type": "library", 2607 | "autoload": { 2608 | "classmap": [ 2609 | "src/" 2610 | ] 2611 | }, 2612 | "notification-url": "https://packagist.org/downloads/", 2613 | "license": [ 2614 | "BSD-3-Clause" 2615 | ], 2616 | "authors": [ 2617 | { 2618 | "name": "Sebastian Bergmann", 2619 | "email": "sebastian@phpunit.de", 2620 | "role": "lead" 2621 | } 2622 | ], 2623 | "description": "Library that helps with managing the version number of Git-hosted PHP projects", 2624 | "homepage": "https://github.com/sebastianbergmann/version", 2625 | "time": "2015-06-21 13:59:46" 2626 | }, 2627 | { 2628 | "name": "symfony/yaml", 2629 | "version": "v2.7.6", 2630 | "source": { 2631 | "type": "git", 2632 | "url": "https://github.com/symfony/yaml.git", 2633 | "reference": "eca9019c88fbe250164affd107bc8057771f3f4d" 2634 | }, 2635 | "dist": { 2636 | "type": "zip", 2637 | "url": "https://api.github.com/repos/symfony/yaml/zipball/eca9019c88fbe250164affd107bc8057771f3f4d", 2638 | "reference": "eca9019c88fbe250164affd107bc8057771f3f4d", 2639 | "shasum": "" 2640 | }, 2641 | "require": { 2642 | "php": ">=5.3.9" 2643 | }, 2644 | "type": "library", 2645 | "extra": { 2646 | "branch-alias": { 2647 | "dev-master": "2.7-dev" 2648 | } 2649 | }, 2650 | "autoload": { 2651 | "psr-4": { 2652 | "Symfony\\Component\\Yaml\\": "" 2653 | } 2654 | }, 2655 | "notification-url": "https://packagist.org/downloads/", 2656 | "license": [ 2657 | "MIT" 2658 | ], 2659 | "authors": [ 2660 | { 2661 | "name": "Fabien Potencier", 2662 | "email": "fabien@symfony.com" 2663 | }, 2664 | { 2665 | "name": "Symfony Community", 2666 | "homepage": "https://symfony.com/contributors" 2667 | } 2668 | ], 2669 | "description": "Symfony Yaml Component", 2670 | "homepage": "https://symfony.com", 2671 | "time": "2015-10-11 09:39:48" 2672 | } 2673 | ], 2674 | "aliases": [], 2675 | "minimum-stability": "stable", 2676 | "stability-flags": [], 2677 | "prefer-stable": false, 2678 | "prefer-lowest": false, 2679 | "platform": { 2680 | "php": ">=5.4.0" 2681 | }, 2682 | "platform-dev": [] 2683 | } -------------------------------------------------------------------------------- /phpunit.xml: -------------------------------------------------------------------------------- 1 | 2 | 15 | 16 | 17 | ./tests 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/Commands/GenerateInclude.php: -------------------------------------------------------------------------------- 1 | option('umd'); 35 | $multipleFiles = $this->option('multi'); 36 | $withVendor = $this->option('with-vendor'); 37 | $fileName = $this->option('file-name'); 38 | $langFiles = $this->option('lang-files'); 39 | $format = $this->option('format'); 40 | $multipleLocales = $this->option('multi-locales'); 41 | 42 | if ($umd) { 43 | // if the --umd option is set, set the $format to 'umd' 44 | $format = 'umd'; 45 | } 46 | 47 | if (!$this->isValidFormat($format)) { 48 | throw new \RuntimeException('Invalid format passed: ' . $format); 49 | } 50 | 51 | if ($multipleFiles || $multipleLocales) { 52 | $files = (new Generator($config)) 53 | ->generateMultiple($root, $format, $multipleLocales); 54 | 55 | if ($config['showOutputMessages']) { 56 | $this->info("Written to : " . $files); 57 | } 58 | 59 | return; 60 | } 61 | 62 | if ($langFiles) { 63 | $langFiles = explode(',', $langFiles); 64 | } 65 | 66 | $data = (new Generator($config)) 67 | ->generateFromPath($root, $format, $withVendor, $langFiles); 68 | 69 | 70 | $jsFile = $this->getFileName($fileName); 71 | file_put_contents($jsFile, $data); 72 | 73 | if ($config['showOutputMessages']) { 74 | $this->info("Written to : " . $jsFile); 75 | } 76 | } 77 | 78 | /** 79 | * @param string $fileNameOption 80 | * @return string 81 | */ 82 | private function getFileName($fileNameOption) 83 | { 84 | if (isset($fileNameOption)) { 85 | return base_path() . $fileNameOption; 86 | } 87 | 88 | return base_path() . config('vue-i18n-generator.jsFile'); 89 | } 90 | 91 | /** 92 | * @param string $format 93 | * @return boolean 94 | */ 95 | private function isValidFormat($format) 96 | { 97 | $supportedFormats = ['es6', 'umd', 'json']; 98 | return in_array($format, $supportedFormats); 99 | } 100 | } 101 | -------------------------------------------------------------------------------- /src/Generator.php: -------------------------------------------------------------------------------- 1 | config = $config; 37 | } 38 | 39 | /** 40 | * @param string $path 41 | * @param string $format 42 | * @param boolean $withVendor 43 | * @return string 44 | * @throws Exception 45 | */ 46 | public function generateFromPath($path, $format = 'es6', $withVendor = false, $langFiles = []) 47 | { 48 | if (!is_dir($path)) { 49 | throw new Exception('Directory not found: ' . $path); 50 | } 51 | 52 | $this->langFiles = $langFiles; 53 | 54 | $locales = []; 55 | $files = []; 56 | $dir = new DirectoryIterator($path); 57 | $jsBody = ''; 58 | foreach ($dir as $fileinfo) { 59 | if (!$fileinfo->isDot()) { 60 | if(!$withVendor 61 | && in_array($fileinfo->getFilename(), array_merge(['vendor'], $this->config['excludes'])) 62 | ) { 63 | continue; 64 | } 65 | 66 | $files[] = $fileinfo->getRealPath(); 67 | } 68 | } 69 | asort($files); 70 | 71 | foreach ($files as $fileName) { 72 | $fileinfo = new \SplFileInfo($fileName); 73 | 74 | $noExt = $this->removeExtension($fileinfo->getFilename()); 75 | if ($noExt !== '') { 76 | if (class_exists('App')) { 77 | App::setLocale($noExt); 78 | } 79 | 80 | if ($fileinfo->isDir()) { 81 | $local = $this->allocateLocaleArray($fileinfo->getRealPath()); 82 | } else { 83 | $local = $this->allocateLocaleJSON($fileinfo->getRealPath()); 84 | if ($local === null) continue; 85 | } 86 | 87 | if (isset($locales[$noExt])) { 88 | $locales[$noExt] = array_merge($local, $locales[$noExt]); 89 | } else { 90 | $locales[$noExt] = $local; 91 | } 92 | } 93 | } 94 | 95 | $locales = $this->adjustVendor($locales); 96 | 97 | $jsonLocales = json_encode($locales, JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES) . PHP_EOL; 98 | 99 | if (json_last_error() !== JSON_ERROR_NONE) { 100 | throw new Exception('Could not generate JSON, error code '.json_last_error()); 101 | } 102 | 103 | // formats other than 'es6' and 'umd' will become plain JSON 104 | if ($format === 'es6') { 105 | $jsBody = $this->getES6Module($jsonLocales); 106 | } elseif ($format === 'umd') { 107 | $jsBody = $this->getUMDModule($jsonLocales); 108 | } else { 109 | $jsBody = $jsonLocales; 110 | } 111 | 112 | return $jsBody; 113 | } 114 | 115 | /** 116 | * @param string $path 117 | * @param string $format 118 | * @return string 119 | * @throws Exception 120 | */ 121 | public function generateMultiple($path, $format = 'es6', $multiLocales = false) 122 | { 123 | if (!is_dir($path)) { 124 | throw new Exception('Directory not found: ' . $path); 125 | } 126 | $jsPath = base_path() . $this->config['jsPath']; 127 | $locales = []; 128 | $fileToCreate = ''; 129 | $createdFiles = ''; 130 | $dir = new DirectoryIterator($path); 131 | $jsBody = ''; 132 | foreach ($dir as $fileinfo) { 133 | if (!$fileinfo->isDot() 134 | && !in_array($fileinfo->getFilename(), array_merge(['vendor'], $this->config['excludes'])) 135 | && $fileinfo !== '' 136 | ) { 137 | $noExt = $this->removeExtension($fileinfo->getFilename()); 138 | if ($noExt !== '') { 139 | if (class_exists('App')) { 140 | App::setLocale($noExt); 141 | } 142 | if (!in_array($noExt, $this->availableLocales)) { 143 | $this->availableLocales[] = $noExt; 144 | } 145 | if ($fileinfo->isDir()) { 146 | $local = $this->allocateLocaleArray($fileinfo->getRealPath(), $multiLocales); 147 | } else { 148 | $local = $this->allocateLocaleJSON($fileinfo->getRealPath()); 149 | if ($local === null) continue; 150 | } 151 | 152 | if (isset($locales[$noExt])) { 153 | $locales[$noExt] = array_merge($local, $locales[$noExt]); 154 | } else { 155 | $locales[$noExt] = $local; 156 | } 157 | } 158 | } 159 | } 160 | foreach ($this->filesToCreate as $fileName => $data) { 161 | $fileToCreate = $jsPath . $fileName . '.js'; 162 | $createdFiles .= $fileToCreate . PHP_EOL; 163 | $jsonLocales = json_encode($data, JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES) . PHP_EOL; 164 | if (json_last_error() !== JSON_ERROR_NONE) { 165 | throw new Exception('Could not generate JSON, error code '.json_last_error()); 166 | } 167 | if ($format === 'es6') { 168 | $jsBody = $this->getES6Module($jsonLocales); 169 | } elseif ($format === 'umd') { 170 | $jsBody = $this->getUMDModule($jsonLocales); 171 | } else { 172 | $jsBody = $jsonLocales; 173 | } 174 | 175 | if (!is_dir(dirname($fileToCreate))) { 176 | mkdir(dirname($fileToCreate), 0777, true); 177 | } 178 | 179 | file_put_contents($fileToCreate, $jsBody); 180 | } 181 | return $createdFiles; 182 | } 183 | 184 | 185 | /** 186 | * @param string $path 187 | * @return array 188 | */ 189 | private function allocateLocaleJSON($path) 190 | { 191 | // Ignore non *.json files (ex.: .gitignore, vim swap files etc.) 192 | if (pathinfo($path, PATHINFO_EXTENSION) !== 'json') { 193 | return null; 194 | } 195 | $tmp = (array)json_decode(file_get_contents($path), true); 196 | if (gettype($tmp) !== "array") { 197 | throw new Exception('Unexpected data while processing ' . $path); 198 | } 199 | 200 | return $this->adjustArray($tmp); 201 | } 202 | 203 | /** 204 | * @param string $path 205 | * @return array 206 | */ 207 | private function allocateLocaleArray($path, $multiLocales = false) 208 | { 209 | $data = []; 210 | $dir = new DirectoryIterator($path); 211 | $lastLocale = last($this->availableLocales); 212 | foreach ($dir as $fileinfo) { 213 | // Do not mess with dotfiles at all. 214 | if ($fileinfo->isDot()) { 215 | continue; 216 | } 217 | 218 | if ($fileinfo->isDir()) { 219 | // Recursivley iterate through subdirs, until everything is allocated. 220 | 221 | $data[$fileinfo->getFilename()] = $this->allocateLocaleArray($path . DIRECTORY_SEPARATOR . $fileinfo->getFilename()); 222 | } else { 223 | $noExt = $this->removeExtension($fileinfo->getFilename()); 224 | $fileName = $path . DIRECTORY_SEPARATOR . $fileinfo->getFilename(); 225 | 226 | // Ignore non *.php files (ex.: .gitignore, vim swap files etc.) 227 | if (pathinfo($fileName, PATHINFO_EXTENSION) !== 'php') { 228 | continue; 229 | } 230 | 231 | if ($this->shouldIgnoreLangFile($noExt)) { 232 | continue; 233 | } 234 | 235 | $tmp = include($fileName); 236 | 237 | if (gettype($tmp) !== "array") { 238 | throw new Exception('Unexpected data while processing ' . $fileName); 239 | continue; 240 | } 241 | if ($lastLocale !== false) { 242 | $root = realpath(base_path() . $this->config['langPath'] . DIRECTORY_SEPARATOR . $lastLocale); 243 | $filePath = $this->removeExtension(str_replace('\\', '_', ltrim(str_replace($root, '', realpath($fileName)), '\\'))); 244 | if($filePath[0] === DIRECTORY_SEPARATOR) { 245 | $filePath = substr($filePath, 1); 246 | } 247 | if ($multiLocales) { 248 | $this->filesToCreate[$lastLocale][$lastLocale][$filePath] = $this->adjustArray($tmp); 249 | } else { 250 | $this->filesToCreate[$filePath][$lastLocale] = $this->adjustArray($tmp); 251 | } 252 | } 253 | 254 | $data[$noExt] = $this->adjustArray($tmp); 255 | } 256 | } 257 | return $data; 258 | } 259 | 260 | /** 261 | * @param string $noExt 262 | * @return boolean 263 | */ 264 | private function shouldIgnoreLangFile($noExt) 265 | { 266 | // langFiles passed by option have priority 267 | if (isset($this->langFiles) && !empty($this->langFiles)) { 268 | return !in_array($noExt, $this->langFiles); 269 | } 270 | 271 | return (isset($this->config['langFiles']) && !empty($this->config['langFiles']) && !in_array($noExt, $this->config['langFiles'])) 272 | || (isset($this->config['excludes']) && in_array($noExt, $this->config['excludes'])); 273 | } 274 | 275 | /** 276 | * @param array $arr 277 | * @return array 278 | */ 279 | private function adjustArray(array $arr) 280 | { 281 | $res = []; 282 | foreach ($arr as $key => $val) { 283 | $key = $this->removeEscapeCharacter($this->adjustString($key)); 284 | 285 | if (is_array($val)) { 286 | $res[$key] = $this->adjustArray($val); 287 | } else { 288 | $res[$key] = $this->removeEscapeCharacter($this->adjustString($val)); 289 | } 290 | } 291 | return $res; 292 | } 293 | 294 | /** 295 | * Adjust vendor index placement. 296 | * 297 | * @param array $locales 298 | * 299 | * @return array 300 | */ 301 | private function adjustVendor($locales) 302 | { 303 | if (isset($locales['vendor'])) { 304 | foreach ($locales['vendor'] as $vendor => $data) { 305 | foreach ($data as $key => $group) { 306 | foreach ($group as $locale => $lang) { 307 | $locales[$key]['vendor'][$vendor][$locale] = $lang; 308 | } 309 | } 310 | } 311 | 312 | unset($locales['vendor']); 313 | } 314 | 315 | return $locales; 316 | } 317 | 318 | /** 319 | * Turn Laravel style ":link" into vue-i18n style "{link}" or vuex-i18n style ":::". 320 | * 321 | * @param string $s 322 | * @return string 323 | */ 324 | private function adjustString($s) 325 | { 326 | if (!is_string($s)) { 327 | return $s; 328 | } 329 | 330 | if ($this->config['i18nLib'] === self::VUEX_I18N) { 331 | $searchPipePattern = '/(\s)*(\|)(\s)*/'; 332 | $threeColons = ' ::: '; 333 | $s = preg_replace($searchPipePattern, $threeColons, $s); 334 | } 335 | 336 | $escaped_escape_char = preg_quote($this->config['escape_char'], '/'); 337 | return preg_replace_callback( 338 | "/(?config['escape_char'], '/'); 356 | return preg_replace_callback( 357 | "/{$escaped_escape_char}(:\w+)/", 358 | function ($matches) { 359 | return mb_substr($matches[0], 1); 360 | }, 361 | $s 362 | ); 363 | } 364 | 365 | /** 366 | * Returns filename, with extension stripped 367 | * @param string $filename 368 | * @return string 369 | */ 370 | private function removeExtension($filename) 371 | { 372 | $pos = mb_strrpos($filename, '.'); 373 | if ($pos === false) { 374 | return $filename; 375 | } 376 | 377 | return mb_substr($filename, 0, $pos); 378 | } 379 | 380 | /** 381 | * Returns an UMD style module 382 | * @param string $body 383 | * @return string 384 | */ 385 | private function getUMDModule($body) 386 | { 387 | $js = <<app->singleton('vue-i18n.generate', function () { 22 | return new Commands\GenerateInclude; 23 | }); 24 | 25 | $this->commands( 26 | 'vue-i18n.generate' 27 | ); 28 | 29 | $this->publishes([ 30 | __DIR__.'/config/vue-i18n-generator.php' => config_path('vue-i18n-generator.php'), 31 | ]); 32 | 33 | $this->mergeConfigFrom( 34 | __DIR__.'/config/vue-i18n-generator.php', 35 | 'vue-i18n-generator' 36 | ); 37 | } 38 | 39 | /** 40 | * Register the service provider. 41 | * 42 | * @return void 43 | */ 44 | public function register() 45 | { 46 | } 47 | 48 | /** 49 | * Get the services provided by the provider. 50 | * 51 | * @return array 52 | */ 53 | public function provides() 54 | { 55 | return ['vue-i18n-generator']; 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /src/config/vue-i18n-generator.php: -------------------------------------------------------------------------------- 1 | '/resources/lang', 15 | 16 | /* 17 | |-------------------------------------------------------------------------- 18 | | Laravel translation files 19 | |-------------------------------------------------------------------------- 20 | | 21 | | You can choose which translation files to be generated. 22 | | Note: leave this empty for all the translation files to be generated. 23 | | 24 | */ 25 | 26 | 'langFiles' => [ 27 | /* 28 | 'pagination', 29 | 'passwords' 30 | */ 31 | ], 32 | 33 | /* 34 | |-------------------------------------------------------------------------- 35 | | Excluded files & folders 36 | |-------------------------------------------------------------------------- 37 | | 38 | | Exclude translation files, generic files or folders you don't need. 39 | | 40 | */ 41 | 'excludes' => [ 42 | /* 43 | 'validation', 44 | 'example.file', 45 | 'example-folder', 46 | */ 47 | ], 48 | 49 | /* 50 | |-------------------------------------------------------------------------- 51 | | Output file 52 | |-------------------------------------------------------------------------- 53 | | 54 | | The javascript path where I will place the generated file. 55 | | Note: the path will be prepended to point to the App directory. 56 | | 57 | */ 58 | 'jsPath' => '/resources/js/langs/', 59 | 'jsFile' => '/resources/js/vue-i18n-locales.generated.js', 60 | 61 | /* 62 | |-------------------------------------------------------------------------- 63 | | i18n library 64 | |-------------------------------------------------------------------------- 65 | | 66 | | Specify the library you use for localization. 67 | | Options are vue-i18n or vuex-i18n. 68 | | 69 | */ 70 | 'i18nLib' => 'vue-i18n', 71 | 72 | /* 73 | |-------------------------------------------------------------------------- 74 | | Output messages 75 | |-------------------------------------------------------------------------- 76 | | 77 | | Specify if the library should show "written to" messages 78 | | after generating json files. 79 | | 80 | */ 81 | 'showOutputMessages' => false, 82 | 83 | /* 84 | |-------------------------------------------------------------------------- 85 | | Escape character 86 | |-------------------------------------------------------------------------- 87 | | 88 | | Allows to escape translations strings that should not be treated as a 89 | | variable 90 | | 91 | */ 92 | 'escape_char' => '!', 93 | ]; 94 | -------------------------------------------------------------------------------- /tests/GenerateTest.php: -------------------------------------------------------------------------------- 1 | $val) { 16 | 17 | if (!is_dir($root . '/' . $key)) { 18 | mkdir($root . '/' . $key); 19 | } 20 | 21 | foreach ($val as $group => $content) { 22 | $outFile = $root . '/'. $key . '/' . $group . '.php'; 23 | file_put_contents($outFile, ' $val) { 33 | 34 | foreach ($val as $group => $content) { 35 | $outFile = $root . '/'. $key . '/' . $group . '.php'; 36 | if (file_exists($outFile)) { 37 | unlink($outFile); 38 | } 39 | } 40 | 41 | if (is_dir($root . '/' . $key)) { 42 | rmdir($root . '/' . $key); 43 | } 44 | 45 | } 46 | 47 | if (is_dir($root)) { 48 | rmdir($root); 49 | } 50 | } 51 | 52 | function testBasic() 53 | { 54 | $arr = [ 55 | 'en' => [ 56 | 'help' => [ 57 | 'yes' => 'yes', 58 | 'no' => 'no', 59 | ] 60 | ], 61 | 'sv' => [ 62 | 'help' => [ 63 | 'yes' => 'ja', 64 | 'no' => 'nej', 65 | ] 66 | ] 67 | ]; 68 | 69 | $root = $this->generateLocaleFilesFrom($arr); 70 | $this->assertEquals( 71 | 'export default {' . PHP_EOL 72 | . ' "en": {' . PHP_EOL 73 | . ' "help": {' . PHP_EOL 74 | . ' "yes": "yes",' . PHP_EOL 75 | . ' "no": "no"' . PHP_EOL 76 | . ' }' . PHP_EOL 77 | . ' },' . PHP_EOL 78 | . ' "sv": {' . PHP_EOL 79 | . ' "help": {' . PHP_EOL 80 | . ' "yes": "ja",' . PHP_EOL 81 | . ' "no": "nej"' . PHP_EOL 82 | . ' }' . PHP_EOL 83 | . ' }' . PHP_EOL 84 | . '}' . PHP_EOL, 85 | (new Generator([]))->generateFromPath($root)); 86 | $this->destroyLocaleFilesFrom($arr, $root); 87 | } 88 | 89 | function testBasicES6Format() 90 | { 91 | $format = 'es6'; 92 | 93 | $arr = [ 94 | 'en' => [ 95 | 'help' => [ 96 | 'yes' => 'yes', 97 | 'no' => 'no', 98 | ] 99 | ], 100 | 'sv' => [ 101 | 'help' => [ 102 | 'yes' => 'ja', 103 | 'no' => 'nej', 104 | ] 105 | ] 106 | ]; 107 | 108 | $root = $this->generateLocaleFilesFrom($arr); 109 | $this->assertEquals( 110 | 'export default {' . PHP_EOL 111 | . ' "en": {' . PHP_EOL 112 | . ' "help": {' . PHP_EOL 113 | . ' "yes": "yes",' . PHP_EOL 114 | . ' "no": "no"' . PHP_EOL 115 | . ' }' . PHP_EOL 116 | . ' },' . PHP_EOL 117 | . ' "sv": {' . PHP_EOL 118 | . ' "help": {' . PHP_EOL 119 | . ' "yes": "ja",' . PHP_EOL 120 | . ' "no": "nej"' . PHP_EOL 121 | . ' }' . PHP_EOL 122 | . ' }' . PHP_EOL 123 | . '}' . PHP_EOL, 124 | (new Generator([]))->generateFromPath($root, $format)); 125 | $this->destroyLocaleFilesFrom($arr, $root); 126 | } 127 | 128 | function testBasicWithUMDFormat() 129 | { 130 | $format = 'umd'; 131 | $arr = [ 132 | 'en' => [ 133 | 'help' => [ 134 | 'yes' => 'yes', 135 | 'no' => 'no', 136 | ] 137 | ], 138 | 'sv' => [ 139 | 'help' => [ 140 | 'yes' => 'ja', 141 | 'no' => 'nej', 142 | ] 143 | ] 144 | ]; 145 | 146 | $root = $this->generateLocaleFilesFrom($arr); 147 | $this->assertEquals( 148 | '(function (global, factory) {' . PHP_EOL 149 | . ' typeof exports === \'object\' && typeof module !== \'undefined\' ? module.exports = factory() :' . PHP_EOL 150 | . ' typeof define === \'function\' && define.amd ? define(factory) :' . PHP_EOL 151 | . ' typeof global.vuei18nLocales === \'undefined\' ? global.vuei18nLocales = factory() : Object.keys(factory()).forEach(function (key) {global.vuei18nLocales[key] = factory()[key]});' . PHP_EOL 152 | . '}(this, (function () { \'use strict\';' . PHP_EOL 153 | . ' return {' . PHP_EOL 154 | . ' "en": {' . PHP_EOL 155 | . ' "help": {' . PHP_EOL 156 | . ' "yes": "yes",' . PHP_EOL 157 | . ' "no": "no"' . PHP_EOL 158 | . ' }' . PHP_EOL 159 | . ' },' . PHP_EOL 160 | . ' "sv": {' . PHP_EOL 161 | . ' "help": {' . PHP_EOL 162 | . ' "yes": "ja",' . PHP_EOL 163 | . ' "no": "nej"' . PHP_EOL 164 | . ' }' . PHP_EOL 165 | . ' }' . PHP_EOL 166 | . '}' . PHP_EOL 167 | . PHP_EOL 168 | . '})));', 169 | (new Generator([]))->generateFromPath($root, $format)); 170 | $this->destroyLocaleFilesFrom($arr, $root); 171 | } 172 | 173 | function testBasicWithJSONFormat() 174 | { 175 | $format = 'json'; 176 | $arr = [ 177 | 'en' => [ 178 | 'help' => [ 179 | 'yes' => 'yes', 180 | 'no' => 'no', 181 | ] 182 | ], 183 | 'sv' => [ 184 | 'help' => [ 185 | 'yes' => 'ja', 186 | 'no' => 'nej', 187 | ] 188 | ] 189 | ]; 190 | 191 | $root = $this->generateLocaleFilesFrom($arr); 192 | $this->assertEquals( 193 | '{' . PHP_EOL 194 | . ' "en": {' . PHP_EOL 195 | . ' "help": {' . PHP_EOL 196 | . ' "yes": "yes",' . PHP_EOL 197 | . ' "no": "no"' . PHP_EOL 198 | . ' }' . PHP_EOL 199 | . ' },' . PHP_EOL 200 | . ' "sv": {' . PHP_EOL 201 | . ' "help": {' . PHP_EOL 202 | . ' "yes": "ja",' . PHP_EOL 203 | . ' "no": "nej"' . PHP_EOL 204 | . ' }' . PHP_EOL 205 | . ' }' . PHP_EOL 206 | . '}' . PHP_EOL, 207 | (new Generator([]))->generateFromPath($root, $format)); 208 | $this->destroyLocaleFilesFrom($arr, $root); 209 | } 210 | 211 | function testInvalidFormat() 212 | { 213 | $format = 'es5'; 214 | $arr = []; 215 | 216 | $root = $this->generateLocaleFilesFrom($arr); 217 | try { 218 | (new Generator([]))->generateFromPath($root, $format); 219 | } catch(RuntimeException $e) { 220 | $this->assertEquals('Invalid format passed: ' . $format, $e->getMessage()); 221 | 222 | } 223 | $this->destroyLocaleFilesFrom($arr, $root); 224 | } 225 | 226 | function testBasicWithTranslationString() 227 | { 228 | $arr = [ 229 | 'en' => [ 230 | 'main' => [ 231 | 'hello :name' => 'Hello :name', 232 | ] 233 | ], 234 | ]; 235 | 236 | $root = $this->generateLocaleFilesFrom($arr); 237 | $this->assertEquals( 238 | 'export default {' . PHP_EOL 239 | . ' "en": {' . PHP_EOL 240 | . ' "main": {' . PHP_EOL 241 | . ' "hello {name}": "Hello {name}"' . PHP_EOL 242 | . ' }' . PHP_EOL 243 | . ' }' . PHP_EOL 244 | . '}' . PHP_EOL, 245 | (new Generator([]))->generateFromPath($root)); 246 | $this->destroyLocaleFilesFrom($arr, $root); 247 | } 248 | 249 | function testBasicWithEscapedTranslationString() 250 | { 251 | $arr = [ 252 | 'en' => [ 253 | 'main' => [ 254 | 'hello :name' => 'Hello :name', 255 | 'time test 10!:00' => 'Time test 10!:00', 256 | ] 257 | ], 258 | ]; 259 | 260 | $root = $this->generateLocaleFilesFrom($arr); 261 | $this->assertEquals( 262 | 'export default {' . PHP_EOL 263 | . ' "en": {' . PHP_EOL 264 | . ' "main": {' . PHP_EOL 265 | . ' "hello {name}": "Hello {name}",' . PHP_EOL 266 | . ' "time test 10:00": "Time test 10:00"' . PHP_EOL 267 | . ' }' . PHP_EOL 268 | . ' }' . PHP_EOL 269 | . '}' . PHP_EOL, 270 | (new Generator([]))->generateFromPath($root)); 271 | $this->destroyLocaleFilesFrom($arr, $root); 272 | } 273 | 274 | function testBasicWithVendor() 275 | { 276 | $arr = [ 277 | 'en' => [ 278 | 'help' => [ 279 | 'yes' => 'yes', 280 | 'no' => 'no', 281 | ] 282 | ], 283 | 'sv' => [ 284 | 'help' => [ 285 | 'yes' => 'ja', 286 | 'no' => 'nej', 287 | ] 288 | ], 289 | 'vendor' => [ 290 | 'test-vendor' => [ 291 | 'en' => [ 292 | 'test-lang' => [ 293 | 'maybe' => 'maybe' 294 | ] 295 | ], 296 | 'sv' => [ 297 | 'test-lang' => [ 298 | 'maybe' => 'kanske' 299 | ] 300 | ] 301 | ] 302 | ], 303 | ]; 304 | 305 | $root = $this->generateLocaleFilesFrom($arr); 306 | 307 | $this->assertEquals( 308 | 'export default {' . PHP_EOL 309 | . ' "en": {' . PHP_EOL 310 | . ' "help": {' . PHP_EOL 311 | . ' "yes": "yes",' . PHP_EOL 312 | . ' "no": "no"' . PHP_EOL 313 | . ' },' . PHP_EOL 314 | . ' "vendor": {' . PHP_EOL 315 | . ' "test-vendor": {' . PHP_EOL 316 | . ' "test-lang": {' . PHP_EOL 317 | . ' "maybe": "maybe"' . PHP_EOL 318 | . ' }' . PHP_EOL 319 | . ' }' . PHP_EOL 320 | . ' }' . PHP_EOL 321 | . ' },' . PHP_EOL 322 | . ' "sv": {' . PHP_EOL 323 | . ' "help": {' . PHP_EOL 324 | . ' "yes": "ja",' . PHP_EOL 325 | . ' "no": "nej"' . PHP_EOL 326 | . ' },' . PHP_EOL 327 | . ' "vendor": {' . PHP_EOL 328 | . ' "test-vendor": {' . PHP_EOL 329 | . ' "test-lang": {' . PHP_EOL 330 | . ' "maybe": "kanske"' . PHP_EOL 331 | . ' }' . PHP_EOL 332 | . ' }' . PHP_EOL 333 | . ' }' . PHP_EOL 334 | . ' }' . PHP_EOL 335 | . '}' . PHP_EOL, 336 | (new Generator([]))->generateFromPath($root, 'es6', true)); 337 | 338 | $this->destroyLocaleFilesFrom($arr, $root); 339 | } 340 | 341 | function testBasicWithVuexLib() 342 | { 343 | $arr = [ 344 | 'en' => [ 345 | 'help' => [ 346 | 'yes' => 'yes', 347 | 'no' => 'no', 348 | ] 349 | ], 350 | 'sv' => [ 351 | 'help' => [ 352 | 'yes' => 'ja', 353 | 'no' => 'nej', 354 | ] 355 | ] 356 | ]; 357 | 358 | $root = $this->generateLocaleFilesFrom($arr); 359 | 360 | $this->assertEquals( 361 | 'export default {' . PHP_EOL 362 | . ' "en": {' . PHP_EOL 363 | . ' "help": {' . PHP_EOL 364 | . ' "yes": "yes",' . PHP_EOL 365 | . ' "no": "no"' . PHP_EOL 366 | . ' }' . PHP_EOL 367 | . ' },' . PHP_EOL 368 | . ' "sv": {' . PHP_EOL 369 | . ' "help": {' . PHP_EOL 370 | . ' "yes": "ja",' . PHP_EOL 371 | . ' "no": "nej"' . PHP_EOL 372 | . ' }' . PHP_EOL 373 | . ' }' . PHP_EOL 374 | . '}' . PHP_EOL, 375 | (new Generator([]))->generateFromPath($root)); 376 | 377 | $this->destroyLocaleFilesFrom($arr, $root); 378 | } 379 | 380 | function testNamed() 381 | { 382 | $arr = [ 383 | 'en' => [ 384 | 'help' => [ 385 | 'yes' => 'see :link y :lonk', 386 | 'no' => [ 387 | 'one' => 'see :link', 388 | ] 389 | ] 390 | ] 391 | ]; 392 | 393 | $root = $this->generateLocaleFilesFrom($arr); 394 | 395 | $this->assertEquals( 396 | 'export default {' . PHP_EOL 397 | . ' "en": {' . PHP_EOL 398 | . ' "help": {' . PHP_EOL 399 | . ' "yes": "see {link} y {lonk}",' . PHP_EOL 400 | . ' "no": {' . PHP_EOL 401 | . ' "one": "see {link}"' . PHP_EOL 402 | . ' }' . PHP_EOL 403 | . ' }' . PHP_EOL 404 | . ' }' . PHP_EOL 405 | . '}' . PHP_EOL, 406 | (new Generator([]))->generateFromPath($root)); 407 | 408 | $this->destroyLocaleFilesFrom($arr, $root); 409 | } 410 | 411 | function testNamedWithEscaped() 412 | { 413 | $arr = [ 414 | 'en' => [ 415 | 'help' => [ 416 | 'yes' => 'see :link y :lonk at 08!:00', 417 | 'no' => [ 418 | 'one' => 'see :link', 419 | ] 420 | ] 421 | ] 422 | ]; 423 | 424 | $root = $this->generateLocaleFilesFrom($arr); 425 | 426 | $this->assertEquals( 427 | 'export default {' . PHP_EOL 428 | . ' "en": {' . PHP_EOL 429 | . ' "help": {' . PHP_EOL 430 | . ' "yes": "see {link} y {lonk} at 08:00",' . PHP_EOL 431 | . ' "no": {' . PHP_EOL 432 | . ' "one": "see {link}"' . PHP_EOL 433 | . ' }' . PHP_EOL 434 | . ' }' . PHP_EOL 435 | . ' }' . PHP_EOL 436 | . '}' . PHP_EOL, 437 | (new Generator([]))->generateFromPath($root)); 438 | 439 | $this->destroyLocaleFilesFrom($arr, $root); 440 | } 441 | 442 | function testEscapedEscapeCharacter() 443 | { 444 | $arr = [ 445 | 'en' => [ 446 | 'help' => [ 447 | 'test escaped' => 'escaped escape char not !!:touched', 448 | ] 449 | ] 450 | ]; 451 | 452 | $root = $this->generateLocaleFilesFrom($arr); 453 | 454 | $this->assertEquals( 455 | 'export default {' . PHP_EOL 456 | . ' "en": {' . PHP_EOL 457 | . ' "help": {' . PHP_EOL 458 | . ' "test escaped": "escaped escape char not !:touched"' . PHP_EOL 459 | . ' }' . PHP_EOL 460 | . ' }' . PHP_EOL 461 | . '}' . PHP_EOL, 462 | (new Generator([]))->generateFromPath($root)); 463 | 464 | $this->destroyLocaleFilesFrom($arr, $root); 465 | } 466 | 467 | function testShouldNotTouchHtmlTags() 468 | { 469 | $arr = [ 470 | 'en' => [ 471 | 'help' => [ 472 | 'yes' => 'see ', 473 | 'no' => 'see ', 474 | 'maybe' => 'It is a Test ok!', 475 | ] 476 | ] 477 | ]; 478 | 479 | $root = $this->generateLocaleFilesFrom($arr); 480 | 481 | $this->assertEquals( 482 | 'export default {' . PHP_EOL 483 | . ' "en": {' . PHP_EOL 484 | . ' "help": {' . PHP_EOL 485 | . ' "yes": "see ",' . PHP_EOL 486 | . ' "no": "see ",' . PHP_EOL 487 | . ' "maybe": "It is a Test ok!"' . PHP_EOL 488 | . ' }' . PHP_EOL 489 | . ' }' . PHP_EOL 490 | . '}' . PHP_EOL, 491 | (new Generator([]))->generateFromPath($root)); 492 | 493 | $this->destroyLocaleFilesFrom($arr, $root); 494 | } 495 | 496 | function testPluralization() 497 | { 498 | $arr = [ 499 | 'en' => [ 500 | 'plural' => [ 501 | 'one' => 'There is one apple|There are many apples', 502 | 'two' => 'There is one apple | There are many apples', 503 | 'five' => [ 504 | 'three' => 'There is one apple | There are many apples', 505 | 'four' => 'There is one apple | There are many apples', 506 | ] 507 | ] 508 | ] 509 | ]; 510 | 511 | $root = $this->generateLocaleFilesFrom($arr); 512 | 513 | // vue-i18n 514 | $this->assertEquals( 515 | 'export default {' . PHP_EOL 516 | . ' "en": {' . PHP_EOL 517 | . ' "plural": {' . PHP_EOL 518 | . ' "one": "There is one apple|There are many apples",' . PHP_EOL 519 | . ' "two": "There is one apple | There are many apples",' . PHP_EOL 520 | . ' "five": {' . PHP_EOL 521 | . ' "three": "There is one apple | There are many apples",' . PHP_EOL 522 | . ' "four": "There is one apple | There are many apples"' . PHP_EOL 523 | . ' }' . PHP_EOL 524 | . ' }' . PHP_EOL 525 | . ' }' . PHP_EOL 526 | . '}' . PHP_EOL, 527 | (new Generator(['i18nLib' => 'vue-i18n']))->generateFromPath($root)); 528 | 529 | // vuex-i18n 530 | $this->assertEquals( 531 | 'export default {' . PHP_EOL 532 | . ' "en": {' . PHP_EOL 533 | . ' "plural": {' . PHP_EOL 534 | . ' "one": "There is one apple ::: There are many apples",' . PHP_EOL 535 | . ' "two": "There is one apple ::: There are many apples",' . PHP_EOL 536 | . ' "five": {' . PHP_EOL 537 | . ' "three": "There is one apple ::: There are many apples",' . PHP_EOL 538 | . ' "four": "There is one apple ::: There are many apples"' . PHP_EOL 539 | . ' }' . PHP_EOL 540 | . ' }' . PHP_EOL 541 | . ' }' . PHP_EOL 542 | . '}' . PHP_EOL, 543 | (new Generator(['i18nLib' => 'vuex-i18n']))->generateFromPath($root)); 544 | 545 | $this->destroyLocaleFilesFrom($arr, $root); 546 | } 547 | } 548 | --------------------------------------------------------------------------------