PHPackages                             hotmeteor/eco-env - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. hotmeteor/eco-env

ActiveProject[Utility &amp; Helpers](/categories/utility)

hotmeteor/eco-env
=================

.env file writer

v1.1.0(4y ago)253.2k1PHPPHP ^7.4|^8.0

Since Sep 22Pushed 4y agoCompare

[ Source](https://github.com/hotmeteor/eco-env)[ Packagist](https://packagist.org/packages/hotmeteor/eco-env)[ RSS](/packages/hotmeteor-eco-env/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (2)Versions (4)Used By (1)

Eco Env
=======

[](#eco-env)

A small set of tools for easily manipulating your project .env files.

[![Latest Stable Version](https://camo.githubusercontent.com/05157aae94ae352d8d7f385aba61f5d2fe6bd1b39485fbdc9f4cd7bf4136ce01/68747470733a2f2f706f7365722e707567782e6f72672f686f746d6574656f722f65636f2d656e762f76)](//packagist.org/packages/hotmeteor/eco-env)

### Installation

[](#installation)

```
composer require hotmeteor/eco-env
```

### Usage

[](#usage)

For most of the methods you'll need to provide the relative or absolute `$file` path to your `.env` file.

In a Laravel app, this is as easy as `base_path('.env')`.

All `$key` values, for all methods, is case-insensitive. Keys will always be set in uppercase.

**Note:** The Env `set` and `unset` methods will actually *change* your .env file.

#### Get

[](#get)

`Env::get($file, $key)`

Returns the full key/value string.

#### Set

[](#set)

`Env::set($file, $key, $value)`

Sets a value by key.

#### Unset

[](#unset)

`Env::unset($file, $key, $value)`

Removes a value by key.

#### Has

[](#has)

`Env::has($file, $key, $value)`

Checks if a value exists, by key.

#### Format

[](#format)

`Env::formatValue($value)`

Exposes the internal method for formatting an .env value.

### Notes

[](#notes)

This package isn't intended to be used instead of the fabulous [Dotenv](https://github.com/vlucas/phpdotenv) package. Dotenv is for automagically loading environment variables, Eco Env is for manipulating them.

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity32

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity61

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~131 days

Total

3

Last Release

1802d ago

PHP version history (2 changes)v1.0PHP ^7.2

v1.1.0PHP ^7.4|^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/9a359353ddbcb93df5c0ad8a00e25d54443ea6e8edaef61a3fea5c64ac7774d3?d=identicon)[hotmeteor](/maintainers/hotmeteor)

---

Top Contributors

[![hotmeteor](https://avatars.githubusercontent.com/u/378585?v=4)](https://github.com/hotmeteor "hotmeteor (9 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/hotmeteor-eco-env/health.svg)

```
[![Health](https://phpackages.com/badges/hotmeteor-eco-env/health.svg)](https://phpackages.com/packages/hotmeteor-eco-env)
```

###  Alternatives

[roots/bedrock

WordPress boilerplate with Composer, easier configuration, and an improved folder structure

6.5k441.8k2](/packages/roots-bedrock)[akaunting/laravel-money

Currency formatting and conversion package for Laravel

7825.3M18](/packages/akaunting-laravel-money)[cognesy/instructor-php

The complete AI toolkit for PHP: unified LLM API, structured outputs, agents, and coding agent control

310107.9k1](/packages/cognesy-instructor-php)[blair2004/nexopos

The Free Modern Point Of Sale System build with Laravel, TailwindCSS and Vue.js.

1.2k2.3k](/packages/blair2004-nexopos)[lullabot/drainpipe

An automated build tool to allow projects to have a set standardized operations scripts.

41716.4k2](/packages/lullabot-drainpipe)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

245.2k](/packages/aedart-athenaeum)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
