svanderburg / composer2nix

Generate Nix expressions to build PHP composer packages
MIT License
88 stars 25 forks source link

Parse error when running `composer2nix` #31

Open WolfangAukang opened 2 years ago

WolfangAukang commented 2 years ago

When I run composer2nix (got it by installing through composer globally) on a PHP project, it seems everything is running fine, but it stops at the following error:

Parse error: syntax error, unexpected '|', expecting variable (T_VARIABLE) in /home/bjorn/.config/composer/vendor/svanderburg/pndp/src/PNDP/AST/NixFunction.php on line 19

WolfangAukang commented 2 years ago

Found the issue. I am currently using PHP 7.4 and it does not support mixed types. Not sure if it is a good idea to specify the necessary PHP version on the composer.json file.