Download the PHP package zablose/dotenv without Composer
On this page you can find all versions of the php package zablose/dotenv. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package dotenv
DotEnv
Read '.env' file or files to a static array.
Installation
Usage
Read '.env' file(s)
Probably in your index.php
after autoloader.
Get ENV
Or
Works, if helper function is in use - added to the project's composer
autoload -> files
section.
What is supported?
Look at ENVs testing examples for more info.
Variables
USER=username
EMAIL=${USER}@domain.com
Arrays
PROTECTED_0=_token
PROTECTED_1=password
Value Types
Type | Example |
---|---|
Boolean | DEBUG_ON=true |
Float | PI=3.14 |
Integer | RAM=128 |
String | GREETING=Welcome back! |
Development
Check submodule's readme for more details about development environment used.
Quick start
$ git clone -b 'dev' --single-branch --depth 1 https://github.com/zablose/dotenv.git dotenv
$ cd dotenv
$ git submodule update --init
# Copy env file, then ammend it to your needs.
$ cp .env.example .env
# Copy docker compose file, then ammend it, if needed.
$ cp docker-compose.example.yml docker-compose.yml
$ docker-compose up -d
# To see post-script logs, while container is starting.
$ tail -f ./logs/all.log
# To enter container, using Bash shell.
$ docker exec -it dotenv-php-fpm bash
(dotenv-php-fpm)$ php vendor/bin/phpunit
Build
- Merge changes from your branch to
master
; - Create a new branch from updated
master
called likebuild-2.0.0
; - Run
php vendor/bin/phing prepare
to remove all irrelevant files and folders; - Commit changes with message like
Prepare build.
; - Merge branch
build-2.0.0
tobuild
branch; - Delete
build-*
branch; - Use tag
2.0.0
onbuild
branch to do the release.
Obviously, replace example
2.0.0
version with yours.
All versions of dotenv with dependencies
PHP Build Version
Package Version
Requires
php Version
^8.3
The package zablose/dotenv contains the following files
Loading the files please wait ....