Skip to content
This repository has been archived by the owner on Aug 14, 2018. It is now read-only.

Implement PSR-2 compability in code #1

Closed
seyfer opened this issue Jan 15, 2015 · 7 comments
Closed

Implement PSR-2 compability in code #1

seyfer opened this issue Jan 15, 2015 · 7 comments

Comments

@seyfer
Copy link

seyfer commented Jan 15, 2015

It's just about code style (braces, spaces, etc.)
Now code style not PSR and it's make code reading hard, because most developers use PSR style.

@alle, If it's okay, I can do this and will made pull request.

@alle
Copy link
Owner

alle commented Jan 15, 2015

@seyfer, I "inherited" the code, since it is a fork of SupersonicAds/kohana-restful-api.
This code is mainly written following the Kohana's Conventions and Coding Styles, which are followed by the Kohana Developers and Kohana Modules Developers.
I highly appreciate PSR initiatives and directives (I tend to follow them in my projects that does not involve Kohana). IMHO, any Kohana module should follow the Kohana's Conventions and Coding Styles.
Your opinion is welcome.

@seyfer
Copy link
Author

seyfer commented Jan 15, 2015

@alle , okay, you are right with coding style for Kohana.

But as my opinion there is no place for other standards, because PSR exists and if any framework will invent and follow own code style - PSR has no meaning in that case.
PSR is for all php code, no matter which library or framework used.

Also developers IDE must be configured to PSR formatting by default (it's already in PhpStorm and NetBeans with small changes)

I think Kohana community should change their mind.

So, this is just my opinion. If you reject this issue, i'am understand your decision.

@alle
Copy link
Owner

alle commented Jan 15, 2015

@seyfer, I agree with you: "Kohana community should change their mind".

Infact, if I code for Kohana, I have to switch my IDE formatting settings to the "Kohana" preset.
At the office, I inherited a coding style I should adhere to (no PSR, no Kohana, nothing); and I have to switch my IDE to that formatting preset. And so on.
Having the possibility to deal with an unique coding standard is like a kimera, if you want to respect other developers (even if other developers don't respect you).

Anyway, the code in this repo is for Kohana Developers. So, if you don't mind, I would prefer to keep the code formatting as is, for now.

@seyfer
Copy link
Author

seyfer commented Jan 15, 2015

@alle , Okay. Thank you for answer and explanation.

@seyfer seyfer closed this as completed Jan 15, 2015
@alle
Copy link
Owner

alle commented Jan 15, 2015

Thank you to you, Sir.

-- 
Alessandro Frangioni
Il giorno 15 gennaio 2015 @ 10:57:14, Oleg Abrazhaev ([email protected]) ha scritto:

Closed #1.


Reply to this email directly or view it on GitHub.

@seyfer
Copy link
Author

seyfer commented Jan 19, 2015

I'm started discussion here. Join if you wish.

kohana/core#597

@alle
Copy link
Owner

alle commented Jan 19, 2015

Thanks for reporting it to me.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants