Skip to content

Commit 289656f

Browse files
committed
Updated contributing.md + added coding guideline
1 parent d3d7fe9 commit 289656f

File tree

2 files changed

+26
-8
lines changed

2 files changed

+26
-8
lines changed

.github/CONTRIBUTING.md

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,4 @@ resolved in a timely manner.
1616
Contributing policy
1717
-------------------
1818

19-
Fork the project, create a feature branch, and send us a pull request.
20-
21-
To ensure a consistent code base, you should make sure the code follows
22-
the [PSR-2 Coding Standards](http://www.php-fig.org/psr/psr-2/). You can also
23-
run [php-cs-fixer](https://github.com/FriendsOfPHP/PHP-CS-Fixer) with the
24-
configuration file that can be found in the project root directory.
25-
26-
If you would like to help, take a look at the [list of open issues](https://github.com/PHPSocialNetwork/phpfastcache/issues).
19+
Our contributing policy is described in our [Coding Guideline](https://github.com/PHPSocialNetwork/phpfastcache/blob/v7/CODING_GUIDELINE.md)

CODING_GUIDELINE.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
CODING GUIDELINE
2+
-------------------
3+
4+
Fork the project, create a feature branch, and send us a pull request.
5+
Preferably on a distinct branch.
6+
7+
To ensure a consistent code base, you should make sure the code follows
8+
the [PSR-2 Coding Standards](http://www.php-fig.org/psr/psr-2/). You can also
9+
run [php-cs-fixer](https://github.com/FriendsOfPHP/PHP-CS-Fixer) with the
10+
configuration file that can be found in the project root directory.
11+
12+
If you would like to help, take a look at the [list of open issues](https://github.com/PHPSocialNetwork/phpfastcache/issues).
13+
14+
PHPFASTCACHE's specialties
15+
-------------------
16+
As of the V7 your contributions MUST comply the following standards:
17+
18+
- **PHP CORE FUNCTIONS**
19+
- To improve opcode efficiency, you MUST prefix core function by a '\\'
20+
- E.g: `$var = \str_replace('value', '', $var);`
21+
- **PHP CORE CLASSES**
22+
- Do not imports non-namespaced classes, use an absolute path instead:
23+
- E.g: `$date = new \DateTime();`
24+
25+
This list is non-exhaustive and will may subject to evolve at any time.

0 commit comments

Comments
 (0)