pachabhaiya / nepali-calendar

Nepali calendar - Converts Gregorian calendar (A.D.) to Bikram Sambat (B.S.) and vice-versa.
MIT License
8 stars 7 forks source link

Reformat #5

Closed ghost closed 9 years ago

ghost commented 9 years ago

Refactor without changing any logic, just structure.

Few things: 1.) Delete unused test cases 2.) Reduced Namespace for easier typing 3.) psr-4 type folder structure with simplified one. 4.) psr-1 & pasr-2 coding standard :package:

and sorry got rid of you name in Namespace. The library is already packaged under your Namespace, so, I don't deem its necessary to have it in the file, as it'd save someone some typing space :)

ojhaujjwal commented 9 years ago

+1

pachabhaiya commented 9 years ago

:+1: Thanks @rajibmp for refactoring the codes.

In PSR-0 autoloading standard,

A fully-qualified namespace and class must have the following structure \<Vendor Name>\(<Namespace>\)*<Class Name>

So, I used Pachabhaiya to meet the standard.

As of PSR-4, we no longer need this, so can be removed. I'm positive.

Looks good to me. Merging this pull request. Going to rename /lib to /src after merging it.

ojhaujjwal commented 9 years ago

@pachabhaiya You are getting it wrong. PSR-4 does not state that vendor namespace should be removed. PSR-4 is an improvement to PSR-0 to avoid creating useless folders. This line is taken from PSR-4 specification:

The fully qualified class name MUST have a top-level namespace name, also known as a "vendor namespace".

ojhaujjwal commented 9 years ago

Also, renaming /lib to /src does not make any difference.