PHPackages                             mnocon/composer-checkout - 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. mnocon/composer-checkout

ActiveComposer-plugin[Utility &amp; Helpers](/categories/utility)

mnocon/composer-checkout
========================

Tool to easily checkout dependencies

v0.2.5(2y ago)33423[4 issues](https://github.com/mnocon/composer-checkout/issues)MITPHPPHP ^7.1 || ^8.0

Since May 4Pushed 1y ago1 watchersCompare

[ Source](https://github.com/mnocon/composer-checkout)[ Packagist](https://packagist.org/packages/mnocon/composer-checkout)[ RSS](/packages/mnocon-composer-checkout/feed)WikiDiscussions master Synced yesterday

READMEChangelog (5)Dependencies (6)Versions (8)Used By (0)

Composer Checkout Plugin
========================

[](#composer-checkout-plugin)

Description
-----------

[](#description)

This Composer plugin allows you to add a Pull Request from GitHub as a Composer dependency without thinking about repositories and branch aliases. Forget about meddling with the `vendor` directory as well ;)

Simply run `composer checkout  [...]` and the rest will be taken care of automatically.

[![Example usage of the command](example.png "Example usage")](example.png)

There is also a `apply-patch` command that deals with diffs generated from Pull Requests.

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

[](#installation)

It's recommended to do the global installation: `composer global require mnocon/composer-checkout`which will make the new commands available in each project.

For a local install run: `composer require mnocon/composer-checkout`

This packages requires at least PHP 7.1 and Composer 2.

Usage
-----

[](#usage)

There are two new Composer commands:

### `composer checkout`

[](#composer-checkout)

Adds a Composer dependency based on GitHub Pull Request.

Example usage:

```
composer checkout https://github.com/symfony/symfony/pull/41105

```

or interactively:

```
 composer checkout

 Please enter the number of Pull Requests [1]:
 > 1

 Link to Pull Request:
 > https://github.com/symfony/symfony/pull/41105

```

In both cases the output will be similar to this one:

```
Checking out dependency: symfony/symfony:dev-inflector-edges as 4.4.x-dev
./composer.json has been updated
Running composer update symfony/symfony
Loading composer repositories with package information
Updating dependencies
Lock file operations: 25 installs, 0 updates, 0 removals
  - Locking doctrine/annotations (1.12.1)
  - Locking doctrine/cache (1.11.0)
  - Locking doctrine/collections (1.6.7)
  - Locking doctrine/event-manager (1.1.1)
  - Locking doctrine/lexer (1.2.1)
  - Locking doctrine/persistence (2.1.0)
  - Locking friendsofphp/proxy-manager-lts (v1.0.3)
  - Locking laminas/laminas-code (4.2.1)
  - Locking laminas/laminas-eventmanager (3.3.1)
  - Locking laminas/laminas-zendframework-bridge (1.2.0)
  - Locking psr/cache (1.0.1)
  - Locking psr/container (1.1.1)
  - Locking psr/link (1.0.0)
  - Locking psr/log (1.1.4)
  - Locking symfony/contracts (v1.1.10)
  - Locking symfony/polyfill-ctype (v1.22.1)
  - Locking symfony/polyfill-intl-icu (v1.22.1)
  - Locking symfony/polyfill-intl-idn (v1.22.1)
  - Locking symfony/polyfill-intl-normalizer (v1.22.1)
  - Locking symfony/polyfill-mbstring (v1.22.1)
  - Locking symfony/polyfill-php72 (v1.22.1)
  - Locking symfony/polyfill-php73 (v1.22.1)
  - Locking symfony/polyfill-php80 (v1.22.1)
  - Locking symfony/symfony (dev-inflector-edges 8b2c097)
  - Locking twig/twig (v3.3.0)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 25 installs, 0 updates, 0 removals
  - Syncing symfony/symfony (dev-inflector-edges 8b2c097) into cache
  - Installing doctrine/lexer (1.2.1): Extracting archive
  - Installing doctrine/annotations (1.12.1): Extracting archive
  - Installing doctrine/cache (1.11.0): Extracting archive
  - Installing doctrine/collections (1.6.7): Extracting archive
  - Installing laminas/laminas-zendframework-bridge (1.2.0): Extracting archive
  - Installing laminas/laminas-eventmanager (3.3.1): Extracting archive
  - Installing laminas/laminas-code (4.2.1): Extracting archive
  - Installing symfony/polyfill-intl-normalizer (v1.22.1): Extracting archive
  - Installing symfony/polyfill-mbstring (v1.22.1): Extracting archive
  - Installing symfony/polyfill-ctype (v1.22.1): Extracting archive
  - Installing twig/twig (v3.3.0): Extracting archive
  - Installing symfony/polyfill-php80 (v1.22.1): Extracting archive
  - Installing symfony/polyfill-php73 (v1.22.1): Extracting archive
  - Installing symfony/polyfill-php72 (v1.22.1): Extracting archive
  - Installing symfony/polyfill-intl-idn (v1.22.1): Extracting archive
  - Installing symfony/polyfill-intl-icu (v1.22.1): Extracting archive
  - Installing psr/container (1.1.1): Extracting archive
  - Installing psr/cache (1.0.1): Extracting archive
  - Installing symfony/contracts (v1.1.10): Extracting archive
  - Installing psr/log (1.1.4): Extracting archive
  - Installing psr/link (1.0.0): Extracting archive
  - Installing symfony/symfony (dev-inflector-edges 8b2c097): Cloning 8b2c097950 from cache
  - Installing friendsofphp/proxy-manager-lts (v1.0.3): Extracting archive
  - Installing doctrine/event-manager (1.1.1): Extracting archive
  - Installing doctrine/persistence (2.1.0): Extracting archive
5 package suggestions were added by new dependencies, use `composer suggest` to see details.
Generating autoload files
17 packages you are using are looking for funding.
Use the `composer fund` command to find out more!

```

To revert changes remove added line in composer.json

[![Example usage reversion](example2.png "Example of reversion")](example2.png)

and run:

```
composer u ibexa/name-of-the-package-with-checkout-applied

```

to update only the package for which checkout was applied or run:

```
composer update

```

to update all the packages.

### composer apply-patch

[](#composer-apply-patch)

Applies a diff from a Pull Request using the `patch` command.

Example usage:

```
composer apply-patch https://github.com/symfony/symfony/pull/41105

```

or interactively:

```
 composer apply-patch

 Please enter the number of Pull Requests [1]:
 > 1

 Link to Pull Request:
 > https://github.com/symfony/symfony/pull/41105

```

In both cases the output will be similar to this one:

```

 [OK] Downloaded patch: patch_symfony-symfony-41105

Running command: patch -d vendor/symfony/symfony -i ../../../patch_symfony-symfony-41105 -Np1
patching file src/Symfony/Component/Inflector/Inflector.php
patching file src/Symfony/Component/Inflector/Tests/InflectorTest.php

 [OK] Applied patch!

```

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance12

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 87% 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 ~163 days

Recently: every ~101 days

Total

7

Last Release

854d ago

PHP version history (2 changes)v0.1.0PHP ^7.1

v0.2.2PHP ^7.1 || ^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/55190e7571f100d9d9a587cb28210575e1065275933cb691d79a58430432a9cf?d=identicon)[mnocon](/maintainers/mnocon)

---

Top Contributors

[![mnocon](https://avatars.githubusercontent.com/u/10993858?v=4)](https://github.com/mnocon "mnocon (20 commits)")[![ibexa-yuna](https://avatars.githubusercontent.com/u/67897517?v=4)](https://github.com/ibexa-yuna "ibexa-yuna (2 commits)")[![adamwojs](https://avatars.githubusercontent.com/u/211967?v=4)](https://github.com/adamwojs "adamwojs (1 commits)")

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/mnocon-composer-checkout/health.svg)

```
[![Health](https://phpackages.com/badges/mnocon-composer-checkout/health.svg)](https://phpackages.com/packages/mnocon-composer-checkout)
```

###  Alternatives

[vaimo/composer-patches

Applies a patch from a local or remote file to any package that is part of a given composer project. Patches can be defined both on project and on package level. Optional support for patch versioning, sequencing, custom patch applier configuration and patch command for testing/troubleshooting added patches.

2994.3M16](/packages/vaimo-composer-patches)[mglaman/composer-drupal-lenient

1317.4M15](/packages/mglaman-composer-drupal-lenient)[drupal/core-composer-scaffold

A flexible Composer project scaffold builder.

5341.9M446](/packages/drupal-core-composer-scaffold)[drupal/core-project-message

Adds a message after Composer installation.

2122.6M172](/packages/drupal-core-project-message)[olvlvl/composer-attribute-collector

A convenient and near zero-cost way to retrieve targets of PHP 8 attributes

184108.8k8](/packages/olvlvl-composer-attribute-collector)[lullabot/drainpipe

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

41716.4k2](/packages/lullabot-drainpipe)

PHPackages © 2026

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