Create phar and installer
Similar to Gush, Bldr, and Composer. A phar file, and an installer would make this a lot easier to install
@aequasi I tried but had some issue with the symlinks of each project example (bin/phpunit, bin/php-cs-fixer) when added to the phar file.
I will create a branch to start working on this feature and do some tests.
I would also suggest using symfony console and you can use the box framework to create the phar file. thanks.
@geshan:
- This project currently uses
symfony/consoleas you can see on thecomposer.jsonfile => https://github.com/jmolivas/phpqa/blob/master/composer.json#L16 - And as mentioned below, I tried to use
boxbut had some issues with the symlinks of each project example (bin/phpunit,bin/php-cs-fixer) when added to thepharfile.
Also as mentioned below too, I will create a branch to start working on this feature and do some tests.
thanks for letting me know @jmolivas , appreciated.
@aequasi and @geshan
I just push a new branch build-phar => https://github.com/jmolivas/phpqa/tree/build-phar
This branch includes a box.json file => https://github.com/jmolivas/phpqa/blob/build-phar/box.json with this content
{
"alias": "phpqa.phar",
"chmod": "0755",
"directories": [
"config",
"src",
"bin"
],
"files": [
"phpqa.yml",
"bin/phpqa.php",
"config/.php_cs",
"config/phpunit.xml.dist",
"vendor/autoload.php"
],
"finder": [
{
"name": "/(\\.php|\\.json|\\.yml)$/",
"exclude": ["Tests","tests", "docs"],
"in": "vendor"
}
],
"main": "bin/phpqa.php",
"output": "phpqa.phar",
"stub": true
}
I ran the box project to build the phar using:
$ box build
And then extract the file phpqa.phar content using:
$ box extract phpqa.phar
After listing the bin directory, I found, the binary symlinks are no longer symlinks after building the phar file:

Because of this, the execution of this project, throws the following exception

are you including the symlink locations in the phar file? (vendor/bin/phpunit)
The box.json It's including the vendor directory but applying some filters
https://github.com/jmolivas/phpqa/blob/build-phar/box.json#L20
I will take a look at the extracted pharcontents and comment with the results