PHPackages                             topfloor2/composer-cleanup-vcs-dirs - 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. topfloor2/composer-cleanup-vcs-dirs

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

topfloor2/composer-cleanup-vcs-dirs
===================================

Automatically deletes .git directories in newly installed or updated dependencies.

02PHP

Since May 7Pushed 2y agoCompare

[ Source](https://github.com/liuchenrang/composer-cleanup-vcs-dirs)[ Packagist](https://packagist.org/packages/topfloor2/composer-cleanup-vcs-dirs)[ RSS](/packages/topfloor2-composer-cleanup-vcs-dirs/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

composer-cleanup-vcs-dirs
=========================

[](#composer-cleanup-vcs-dirs)

If you're stuck needing to commit your composer dependencies, you might find you need to delete some extra .git directories after every time you install or update something with Composer.

While not a best practice, sometimes it's simply a requirement.

How to use the plugin
---------------------

[](#how-to-use-the-plugin)

When required in composer.json, the plugin will automatically search for any .git directories in installed or updated dependencies and delete them immediately.

There's nothing else you need to do after requiring this plugin in your main composer.json file.

Running the command directly
----------------------------

[](#running-the-command-directly)

You can also run the cleanup-vcs-dirs command directly in Composer.

To do so, simply run:

```
composer cleanup-vcs-dirs

```

Your entire project will be scanned, and all child .git directories under the project directory will be deleted.

composer config

```
    "post-install-cmd": [
      "composer cleanup-vcs-dirs"
    ],
    "post-update-cmd": [
      "composer cleanup-vcs-dirs"
    ],
```

###  Health Score

12

—

LowBetter than 0% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity2

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity18

Early-stage or recently created project

 Bus Factor1

Top contributor holds 73.7% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/4ce10d2147f714ea78a7b1845a1747cdf9b6c7dbebd3120d9ec819251906785b?d=identicon)[xinghuo](/maintainers/xinghuo)

---

Top Contributors

[![ReplicaObscura](https://avatars.githubusercontent.com/u/277977?v=4)](https://github.com/ReplicaObscura "ReplicaObscura (14 commits)")[![liuchenrang](https://avatars.githubusercontent.com/u/2784214?v=4)](https://github.com/liuchenrang "liuchenrang (3 commits)")[![jacks0n](https://avatars.githubusercontent.com/u/469696?v=4)](https://github.com/jacks0n "jacks0n (2 commits)")

### Embed Badge

![Health badge](/badges/topfloor2-composer-cleanup-vcs-dirs/health.svg)

```
[![Health](https://phpackages.com/badges/topfloor2-composer-cleanup-vcs-dirs/health.svg)](https://phpackages.com/packages/topfloor2-composer-cleanup-vcs-dirs)
```

###  Alternatives

[bootflat/bootflat

An open source Flat UI KIT based on Bootstrap (3.3.0). A faster, easier and less repetitive way for web developers to create elegant web apps.

4.2k3.3k](/packages/bootflat-bootflat)[francescomalatesta/laravel-circuit-breaker

A circuit breaker pattern implementation for the Laravel framework

2919.2k2](/packages/francescomalatesta-laravel-circuit-breaker)[jstewmc/usps-address

A simple PHP class for United States Postal Service (USPS) addresses

1211.0k](/packages/jstewmc-usps-address)[techworker/ssml

A PHP library to generate SSML.

1110.1k1](/packages/techworker-ssml)

PHPackages © 2026

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