https://github.com/eghojansu/project-compress
Compress project with PHP and 7zip
https://github.com/eghojansu/project-compress
Last synced: 2 months ago
JSON representation
Compress project with PHP and 7zip
- Host: GitHub
- URL: https://github.com/eghojansu/project-compress
- Owner: eghojansu
- License: mit
- Created: 2021-09-03T04:17:19.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2021-09-30T12:29:27.000Z (over 3 years ago)
- Last Synced: 2025-02-09T12:43:12.564Z (4 months ago)
- Language: PHP
- Size: 15.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PHP Compress Tool
Compress project folder
## Installation and Usage
`composer require --dev eghojansu/project-compress:dev-master`
Use in your project: `vendor/bin/compress`
## Options
Create `compress.json` or `compress.json.dist` in current working directory.
Default options:
```json
{
"bin": null,
"dest": "{cwd}/dist",
"dir": "{cwd}",
"exclude_extensions": ["7z", "bak", "db", "env", "gz", "zip", "rar"],
"exclude_recursives": ["~$*"],
"exclude_extras": null,
"excludes": [".git", ".vs", "dist", "node_modules", "var", "vendor"],
"extension": null,
"format": "7z",
"name": null,
"options": "-mx=9 -m0=lzma2",
"overrides": null
}
```_Please refers to 7zip for `format` and `options` option._
_Overrides consists of environment and overriden option as below._
```json
{
"overrides": {
"prod": {
"exclude_extras": "exclude/other/directory-or-files"
}
}
}
```Then run command with `vendor/bin/compress --env=prod`.
The configuration in `overrides.prod` will be merged with the main configuration.## Supported compressor
* [7zip](https://www.7-zip.org/)