PHPackages                             itk-dev/composer-virtualenv - 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. itk-dev/composer-virtualenv

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

itk-dev/composer-virtualenv
===========================

A simple virtual environment for composer

1.0.0(8y ago)013.5k↓64.1%MIT

Since Jun 9Pushed 8y ago3 watchersCompare

[ Source](https://github.com/itk-dev/composer-virtualenv)[ Packagist](https://packagist.org/packages/itk-dev/composer-virtualenv)[ RSS](/packages/itk-dev-composer-virtualenv/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependenciesVersions (2)Used By (0)

Composer virtualenv
===================

[](#composer-virtualenv)

A simple virtual environment for `composer`.

Inspired by Python's [`virtualenv`](https://virtualenv.pypa.io/en/stable/), this package adds a script for prepending `vendor/bin` to the `PATH` variable to make it easier to run commands installed via `composer`.

Background
----------

[](#background)

Assume your `composer.json` contains

```
    "require-dev": {
        "phpunit/phpunit": "^6.5",
        "drush/drush": "^9.2"
    }
```

After running `composer install` you have to make sure to run `vendor/bin/phpunit` or `vendor/bin/drush`, respectively, to run the right command. If you just run `phpunit` you'll will run any globally installed version of `phpunit` (or get an error if `phpunit` is not installed).

Composer virtualenv, helps you run the right commands, i.e. the ones installed using `composer`, without having to (remember to) type `vendor/bin/` every time.

Installation
------------

[](#installation)

```
composer require itk-dev/composer-virtualenv "^1.0"
```

Activating the virtual environment
----------------------------------

[](#activating-the-virtual-environment)

To deactivate the virtual environment, run

```
source vendor/bin/activate
```

**Note**: It is important to `source` the script – it will not work if it is run.

This prepends the path `vendor/bin` to the `PATH` environment variable, and any command installed using `composer` will be run instead of any globally available command of the same name.

Deactivating the virtual environment
------------------------------------

[](#deactivating-the-virtual-environment)

To deactivate the virtual environment and restore the `PATH`variable to its original value, run

```
deactivate
```

###  Health Score

33

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity25

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity63

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

Unknown

Total

1

Last Release

2946d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/9d838759fdace714b1c00ca64212935cb06568a6d641169301aa2ed05eed16f9?d=identicon)[rimi-itk](/maintainers/rimi-itk)

---

Top Contributors

[![rimi-itk](https://avatars.githubusercontent.com/u/11267554?v=4)](https://github.com/rimi-itk "rimi-itk (2 commits)")

### Embed Badge

![Health badge](/badges/itk-dev-composer-virtualenv/health.svg)

```
[![Health](https://phpackages.com/badges/itk-dev-composer-virtualenv/health.svg)](https://phpackages.com/packages/itk-dev-composer-virtualenv)
```

###  Alternatives

[yarovikov/gutengood

Base for yours blocks

141.8k](/packages/yarovikov-gutengood)

PHPackages © 2026

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