PHPackages                             seferov/composer-env-script - 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. seferov/composer-env-script

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

seferov/composer-env-script
===========================

Composer script for handling gitignored env files

v1.0.0(3y ago)1139.0k↓17.4%MITPHPPHP ^7.4 || ^8.0

Since Sep 29Pushed 3y ago1 watchersCompare

[ Source](https://github.com/seferov/composer-env-script)[ Packagist](https://packagist.org/packages/seferov/composer-env-script)[ RSS](/packages/seferov-composer-env-script/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (2)Versions (2)Used By (0)

Composer Env File Script
========================

[](#composer-env-file-script)

The package allows creating or updating ignored env file (ex: `.env.local`) based on a default env file (ex: `.env`) interactively.

[![demo](assets/demo.gif)](assets/demo.gif)

---

### Installation

[](#installation)

```
composer require seferov/composer-env-script
```

Modify your `composer.json` file:

```
{
  "scripts": {
    "post-install-cmd": [
      "Seferov\\ComposerEnvScript\\ScriptHandler::buildEnv"
    ],
    "post-update-cmd": [
      "Seferov\\ComposerEnvScript\\ScriptHandler::buildEnv"
    ]
  }
}
```

### Configuration

[](#configuration)

By default, the package generates/updates `.env.local` file based on `.env`. This can be changed trough composer.json extra. The configuration also allows managing multiple .env files:

```
{
  "extra": {
    "seferov-env": [
      {
        "from-file": ".env",
        "to-file": ".env.local"
      },
      {
        "from-file": "somepath/.env.test",
        "to-file": "somepath/.env.test.local"
      }
    ]
  }
}
```

### Credits

[](#credits)

The package is highly inspired by  which is for managing ignored parameters.

###  Health Score

32

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity34

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 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

Unknown

Total

1

Last Release

1327d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/610bd2fde1711e53582ff2e311a6a40c5fbf4056b30930720e3f315fdb39ae06?d=identicon)[ferhad](/maintainers/ferhad)

---

Top Contributors

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

---

Tags

composerdotenv

### Embed Badge

![Health badge](/badges/seferov-composer-env-script/health.svg)

```
[![Health](https://phpackages.com/badges/seferov-composer-env-script/health.svg)](https://phpackages.com/packages/seferov-composer-env-script)
```

###  Alternatives

[mis3085/tiktoken-for-laravel

This is tiktoken-php (yethee/tiktoken) wrapper for Laravel

25544.1k](/packages/mis3085-tiktoken-for-laravel)[aniftyco/skeletor

Summon Skeletor's minion: a Composer companion to unleash extra functionality with every `create-project` command.

961.6k2](/packages/aniftyco-skeletor)[96qbhy/agora

声网php-SDK

121.5k](/packages/96qbhy-agora)

PHPackages © 2026

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