Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/carsonf/composer-rm-plugin
Composer plugin that removes vendor files/directories on install/update
https://github.com/carsonf/composer-rm-plugin
composer composer-plugin php
Last synced: about 2 months ago
JSON representation
Composer plugin that removes vendor files/directories on install/update
- Host: GitHub
- URL: https://github.com/carsonf/composer-rm-plugin
- Owner: CarsonF
- License: mit
- Created: 2017-08-17T22:12:03.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2021-01-22T21:38:50.000Z (almost 4 years ago)
- Last Synced: 2024-04-02T02:44:37.356Z (9 months ago)
- Topics: composer, composer-plugin, php
- Language: PHP
- Homepage:
- Size: 1.95 KB
- Stars: 4
- Watchers: 3
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Composer Rm Plugin
This Composer plugin removes vendor files/directories on install/update.
This is useful when packages add "cruft" that you do not need.
My use case is Intellij picks up these files when I'm inspecting, searching, etc.
Specifically says there are duplicate class definitions, very annoying.
With this plugin, I just add those annoying paths to my global composer config file
and they are removed after every install/update for all of my local projects, beautiful!# Installation
Require it:
```bash
$ composer global require full/composer-rm-plugin
```Open your global composer config, which can be found here:
```bash
$ echo $(composer config --global data-dir)/config.json
```Or just to open it in your default editor:
```bash
$ composer config --global --editor
```Then add your paths to remove (paths are relative to vendor directory):
```json
{
"config": {
"rm-paths": [
"phpunit/phpunit/build",
"twig/twig/test/bootstrap.php"
]
}
}
```
Paths do not have to exist, so if PHPUnit or Twig are not installed then they are just skipped.