diff --git a/.env.example b/.env.example index d2cde90..f0267e2 100644 --- a/.env.example +++ b/.env.example @@ -12,13 +12,18 @@ QUEUE_DRIVER=sync # Your Team Slack Token SLACK_TOKEN=YOUR-SLACK-TOKEN-WITH-ADMIN-PRIVILEGIES -# Web Socket Server +##################################################################################### +## Language Detector Configurations ## +## see https://github.com/vluzrmos/laravel-language-detector ## +##################################################################################### -#Web Socket Server Hostname, Empty will use same of http server (ex.: http://localhost) -WS_HOST= - -#Web Socket Server Port -WS_PORT=8080 - -# Interval to check slack status -SLACK_STATUS_INTERVAL=3000 +#Indicates whenever should autodetect the language (it could be removed) +LANG_DETECTOR_AUTODETECT=true +#The driver to use, default is browser +LANG_DETECTOR_DRIVER="browser" +#The segment to use in uri or subdomain driver, default 0 (it could be removed) +LANG_DETECTOR_SEGMENT=0 +#A comma-separated list of available languages on application +LANG_DETECTOR_LANGUAGES="en,pt_BR" +#To aliase the language use the notation ":", "=", ":=" or "=>" to separate the alias and its value. +# LANG_DETECTOR_LANGUAGES="en, en-us:en, pt-br:pt_BR" diff --git a/bootstrap/app.php b/bootstrap/app.php index ad21d88..f9d8726 100644 --- a/bootstrap/app.php +++ b/bootstrap/app.php @@ -78,8 +78,6 @@ | */ -$app->configure('lang-detector'); - $app->register('App\Providers\AppServiceProvider'); $app->register('App\Providers\ValidationServiceProvider'); $app->register('App\Providers\TranslatorServiceProvider'); diff --git a/composer.lock b/composer.lock index e0dfbf2..ad73bc1 100644 --- a/composer.lock +++ b/composer.lock @@ -1617,16 +1617,16 @@ }, { "name": "laravel/lumen-framework", - "version": "v5.1.2", + "version": "v5.1.3", "source": { "type": "git", "url": "https://github.com/laravel/lumen-framework.git", - "reference": "f5d6c5e9fd43abf2d3904607c95dc2864c761945" + "reference": "0ec7ffaf1e61a7fb15f24656d2d63ea7e216447d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/lumen-framework/zipball/f5d6c5e9fd43abf2d3904607c95dc2864c761945", - "reference": "f5d6c5e9fd43abf2d3904607c95dc2864c761945", + "url": "https://api.github.com/repos/laravel/lumen-framework/zipball/0ec7ffaf1e61a7fb15f24656d2d63ea7e216447d", + "reference": "0ec7ffaf1e61a7fb15f24656d2d63ea7e216447d", "shasum": "" }, "require": { @@ -1698,7 +1698,7 @@ "laravel", "lumen" ], - "time": "2015-07-12 02:19:42" + "time": "2015-07-19 18:25:14" }, { "name": "monolog/monolog", @@ -2045,16 +2045,16 @@ }, { "name": "psy/psysh", - "version": "v0.5.1", + "version": "v0.5.2", "source": { "type": "git", "url": "https://github.com/bobthecow/psysh.git", - "reference": "e5a46a767928e85f1f47dda654beda8c680ddd94" + "reference": "aaf8772ade08b5f0f6830774a5d5c2f800415975" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/bobthecow/psysh/zipball/e5a46a767928e85f1f47dda654beda8c680ddd94", - "reference": "e5a46a767928e85f1f47dda654beda8c680ddd94", + "url": "https://api.github.com/repos/bobthecow/psysh/zipball/aaf8772ade08b5f0f6830774a5d5c2f800415975", + "reference": "aaf8772ade08b5f0f6830774a5d5c2f800415975", "shasum": "" }, "require": { @@ -2113,7 +2113,7 @@ "interactive", "shell" ], - "time": "2015-07-03 16:48:00" + "time": "2015-07-16 15:26:57" }, { "name": "react/promise", @@ -2891,16 +2891,16 @@ }, { "name": "vluzrmos/language-detector", - "version": "v1.0.0", + "version": "v1.0.8", "source": { "type": "git", "url": "https://github.com/vluzrmos/laravel-language-detector.git", - "reference": "e9a776c70c79f304a409431d63871bea367f455a" + "reference": "f678199a5a93f0ccf7d4feb544ec8e8ce442bd3b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vluzrmos/laravel-language-detector/zipball/e9a776c70c79f304a409431d63871bea367f455a", - "reference": "e9a776c70c79f304a409431d63871bea367f455a", + "url": "https://api.github.com/repos/vluzrmos/laravel-language-detector/zipball/f678199a5a93f0ccf7d4feb544ec8e8ce442bd3b", + "reference": "f678199a5a93f0ccf7d4feb544ec8e8ce442bd3b", "shasum": "" }, "require": { @@ -2930,7 +2930,7 @@ "email": "vluzrmos@gmail.com" } ], - "description": "A Laravel and Lumen Language Detector.", + "description": "Detect the language for your application using browser preferences, subdomains or route prefixes.", "keywords": [ "i18n", "language", @@ -2938,7 +2938,7 @@ "locale", "lumen" ], - "time": "2015-07-15 04:55:59" + "time": "2015-07-22 12:13:23" }, { "name": "vluzrmos/slack-api", diff --git a/config/lang-detector.php b/config/lang-detector.php deleted file mode 100644 index a882cf5..0000000 --- a/config/lang-detector.php +++ /dev/null @@ -1,30 +0,0 @@ - true, - - /* - * Default driver to use to detect the request language. - * - * Available: browser, subdomain, uri. - */ - 'driver' => 'browser', - - /* - * Used on subdomain and uri drivers. That indicates which segment should be used - * to verify the language. - */ - 'segment' => 0, - - /* - * Languages available on the application. - */ - 'languages' => [ - 'en', - 'pt_BR', - 'pt-br' => 'pt_BR', - ], -];