Download the PHP package sven/env-providers without Composer

On this page you can find all versions of the php package sven/env-providers. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package env-providers

env-providers

Laravel EnvProviders

Latest Version on Packagist Total Downloads Build Status StyleCI

A more finetuned way of managing your service providers in Laravel. This package allows you to configure the environment certain service providers and aliases are loaded in.

Installation

Via composer:

Or add the package to your dependencies in composer.json and run composer update to download the package:

Next, add the ServiceProvider to your providers array in config/app.php:

Usage

You must publish this package's configuration file for it to work properly. To do so, run the following command:

After that, you should see the file config/providers.php. In the created configuration file you can see 2 pre-defined provider groups that will help you set up what providers and aliases should be loaded when the application is in any of the configured environments.

Environments

In the environments array you can define what are known as "environment aliases". For example, if you use more than one name for local development (eg. dev, development, and local), you can alias all of these to one name to use in this package's configuration.

Note: You can set your application's environment in either config/app.php under env or via your .env file. If you want to manage your .env file via php artisan, you can check out sven/flex-env.

Groups

The groups key in the configration is used to load in service providers and aliases (also know as facades) in one of the previously defined environments. You can use * as a wildcard here to always load that group, regardless of the application's environment.

Providers

The providers array is where you can put the providers you want to have loaded in the defined environment. This should be pretty straight forward as it is similar to how you would register service providers in config/app.php.

Aliases

In the aliases array you may define all your aliases (facades). As with the providers, this is the same as how you would register aliases in the default config/app.php configuration file.

Example

Notice how we're only loading the Debugbar ServiceProvider and facade when our application's environment is either local, development, or dev. This means we can't use the Debugbar facade in our project when the environment doesn't match any of those.

Contributing

All contributions (pull requests, issues and feature requests) are welcome. Make sure to read through the CONTRIBUTING.md first, though. See the contributors page for all contributors.

License

sven/env-providers is licensed under the MIT License (MIT). Please see the license file for more information.


All versions of env-providers with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
illuminate/support Version ^10.0|^11.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package sven/env-providers contains the following files

Loading the files please wait ....