2017 © Pedro Peláez
 

library laravel-envloader

Laravel 5 environment loader

image

jenky/laravel-envloader

Laravel 5 environment loader

  • Friday, September 15, 2017
  • by Milano
  • Repository
  • 1 Watchers
  • 0 Stars
  • 462 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 9 Versions
  • 3 % Grown

The README.md

Laravel 5 environment loader

Latest Stable Version Total Downloads License, (*1)

Load configs, providers, aliases based on the APP_ENV name in .env., (*2)

Installation

Require this package with composer:, (*3)

composer require jenky/laravel-envloader ~1.0

or add this to composer.json, (*4)

"jenky/laravel-envloader": "~1.0"

After updating composer, add the ServiceProvider to the providers array in config/app.php. Make sure the EnvLoaderServiceProvider is loaded before other app service providers., (*5)

'Jenky\LaravelEnvLoader\EnvLoaderServiceProvider',
// or 
Jenky\LaravelEnvLoader\EnvLoaderServiceProvider::class, // PHP 5.5

/*
 * Application Service Providers...
 */
App\Providers\AppServiceProvider::class,
App\Providers\EventServiceProvider::class,
App\Providers\RouteServiceProvider::class,
// ... 

Copy the package config to your local config with the publish command:, (*6)

php artisan vendor:publish

The config files will be published to config/app/env, (*7)

Usage

Modify the config files in config/app/env to suite your needs, (*8)

/* configs.php */

return [
    'local' => [
        'app' => [
            'url' => 'http://myapp.local',
        ],
    ],
    'sandbox' => [
        'app' => [
            'url' => 'http://sandbox.myapp.com',
        ],
    ],
    'testing' => [
        'session' => [
            'driver' => 'file',
        ],
    ],
];

Multiple environments may be delimited using a "pipe" character, (*9)

/* aliases.php */

return [
    'local|staging' => [
        'Debugbar' => 'Barryvdh\Debugbar\Facade',
    ],
];

The Versions

15/09 2017

dev-master

9999999-dev

Laravel 5 environment loader

  Sources   Download

MIT

The Requires

 

by Linh Tran

laravel framework

15/09 2017

1.2.0

1.2.0.0

Laravel 5 environment loader

  Sources   Download

MIT

The Requires

 

by Linh Tran

laravel framework

10/08 2016

1.1.5

1.1.5.0

Laravel 5 environment loader

  Sources   Download

MIT

The Requires

 

by Linh Tran

laravel framework

22/12 2015

1.1.4

1.1.4.0

Laravel 5 environment loader

  Sources   Download

MIT

The Requires

 

by Linh Tran

laravel framework

11/06 2015

1.1.3

1.1.3.0

Laravel 5 environment loader

  Sources   Download

MIT

The Requires

 

by Linh Tran

laravel framework

14/04 2015

1.1.2

1.1.2.0

Laravel 5 environment loader

  Sources   Download

MIT

The Requires

 

by Linh Tran

laravel framework

03/04 2015

1.1.1

1.1.1.0

  Sources   Download

The Requires

 

by Linh Tran

02/04 2015

1.1.0

1.1.0.0

  Sources   Download

The Requires

 

by Linh Tran

01/04 2015

1.0.1

1.0.1.0

  Sources   Download

The Requires

 

by Linh Tran