svanderburg / composer2nix

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

Modernize PHP and clean up some things #10

Closed etu closed 4 years ago

etu commented 4 years ago

Heya, I'm at the NixCon hackday and picked up some of the work on composer2nix and bringing it to nixpkgs in https://github.com/NixOS/nixpkgs/pull/72066

This doesn't really change any features of composer2nix. It's mostly an upgrade of composer and a lot of cleanup. But I will do more things to actually change things in a future PR.

I've applied the PSR-2 codestyle on the entire PHP project which is one of the most widely used and widely accepted codestyles for PHP as a whole community.

etu commented 4 years ago

I've also just found out about #9, I noticed the issue myself and updated composer to resolve that.

But I have a branch that cherry-picks #9 on top of this branch to resolve it in the better way. So if that's interesting I can push it on this PR.

delirehberi commented 4 years ago

please do not use auto-formatter. I want to review your commits but it's not much clearer.

etu commented 4 years ago

That's why I broke things up in separate commits, I consider phpcbf changes safe from plenty of use. So those changes shouldn't need to be reviewed as carefully.

And auto formatters to follow codestyle is a good thing for consistency across projects.

delirehberi commented 4 years ago

I do not agree with you @etu. Everyone has own style for coding. You have to send an .editorconfig file if you want to lock that styling. How I trust the any commit which has a lot of styling changes if there is not any agreed standard for styling? Everyone comes with own style corrections, someone wants 2-space tabs, the other one wants 4-space tabs.

I mean, that project has not any styling standard. You need to follow rules if you want to change this. Of course, you can add a standard for styling, but not like that. You have to send an .editorconfig or something like this first. In this way, we will know what you intend.

Please, do not misunderstand me. Just I want to explain why I said before.

All of the above about just "styling" changes.

If I have to say something about "phpcbf"; this has a lot of configuration parameters. It would be nice if you write a git hook for runs that checks with the same parameters.

Otherwise, making any "modernization" attempts are pointless.

etu commented 4 years ago

We each has our own opinions. But since this was long forgotten by me and it has conflicts in several places I'm just going to drop it. :slightly_smiling_face: