Skip to content

Commit 0cbe6bc

Browse files
committed
First commit!
0 parents  commit 0cbe6bc

File tree

8 files changed

+177
-0
lines changed

8 files changed

+177
-0
lines changed

.docheader

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
/**
2+
* This file is part of php-fast-forward/http-message.
3+
*
4+
* This source file is subject to the license bundled
5+
* with this source code in the file LICENSE.
6+
*
7+
* @link https://github.com/php-fast-forward/http-message
8+
* @copyright Copyright (c) 2025-%year% Felipe Sayão Lobato Abreu <[email protected]>
9+
* @license https://opensource.org/licenses/MIT MIT License
10+
*/

.editorconfig

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
root = true
2+
3+
[*]
4+
indent_style = space
5+
indent_size = 4
6+
end_of_line = lf
7+
charset = utf-8
8+
trim_trailing_whitespace = true
9+
insert_final_newline = true
10+
11+
[*.md]
12+
trim_trailing_whitespace = false

.gitattributes

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
* text=auto
2+
/.github/ export-ignore
3+
/tests/ export-ignore
4+
/.docheader export-ignore
5+
/.dockerignore export-ignore
6+
/.editorconfig export-ignore
7+
/.gitattributes export-ignore
8+
/.gitignore export-ignore
9+
/.php-cs-fixer.php export-ignore
10+
/docker-compose export-ignore
11+
/Dockerfile export-ignore
12+
/infection.json5 export-ignore
13+
/phpunit.xml export-ignore

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
.idea/
2+
public/
3+
vendor/
4+
composer.lock
5+
*.cache

.php-cs-fixer.php

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
/**
6+
* This file is part of php-fast-forward/http-message.
7+
*
8+
* This source file is subject to the license bundled
9+
* with this source code in the file LICENSE.
10+
*
11+
* @link https://github.com/php-fast-forward/http-message
12+
* @copyright Copyright (c) 2025 Felipe Sayão Lobato Abreu <[email protected]>
13+
* @license https://opensource.org/licenses/MIT MIT License
14+
*/
15+
16+
use CoiSA\PhpCsFixer\PhpCsFixer;
17+
18+
$paths = [
19+
__FILE__,
20+
__DIR__,
21+
];
22+
23+
$header = file_get_contents(__DIR__ . '/.docheader');
24+
25+
return PhpCsFixer::create($paths, $header);

LICENSE

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
Copyright (c) 2025 Felipe Sayão Lobato Abreu
2+
3+
Permission is hereby granted, free of charge, to any person obtaining a copy
4+
of this software and associated documentation files (the "Software"), to deal
5+
in the Software without restriction, including without limitation the rights
6+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7+
copies of the Software, and to permit persons to whom the Software is furnished
8+
to do so, subject to the following conditions:
9+
10+
The above copyright notice and this permission notice shall be included in all
11+
copies or substantial portions of the Software.
12+
13+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19+
THE SOFTWARE.

composer.json

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
{
2+
"name": "fast-forward/http",
3+
"description": "Fast Forward HTTP is a toolkit for building HTTP applications in PHP.",
4+
"license": "MIT",
5+
"type": "library",
6+
"authors": [
7+
{
8+
"name": "Felipe Sayão Lobato Abreu",
9+
"email": "[email protected]"
10+
}
11+
],
12+
"homepage": "https://github.com/php-fast-forward",
13+
"support": {
14+
"issues": "https://github.com/php-fast-forward/http/issues",
15+
"source": "https://github.com/php-fast-forward/http"
16+
},
17+
"require": {
18+
"php": "^8.2",
19+
"fast-forward/http-client": "^1.0",
20+
"fast-forward/http-factory": "^1.1",
21+
"middlewares/utils": "^4.0"
22+
},
23+
"require-dev": {
24+
"coisa/php-cs-fixer": "^2.1",
25+
"phpspec/prophecy-phpunit": "^2.3",
26+
"phpunit/phpunit": "^9.6 || ^10.5 || ^11.5"
27+
},
28+
"minimum-stability": "stable",
29+
"autoload": {
30+
"psr-4": {
31+
"FastForward\\Http\\": "src/"
32+
}
33+
},
34+
"autoload-dev": {
35+
"psr-4": {
36+
"FastForward\\Http\\Tests\\": "tests/"
37+
}
38+
},
39+
"config": {
40+
"sort-packages": true
41+
},
42+
"extra": {
43+
"branch-alias": {
44+
"dev-main": "1.x-dev"
45+
}
46+
},
47+
"scripts": {
48+
"cs-check": "php-cs-fixer fix --dry-run --diff",
49+
"cs-fix": "php-cs-fixer fix",
50+
"mutation-testing": "infection --threads=4",
51+
"pre-commit": [
52+
"@cs-check",
53+
"@static-analysis",
54+
"@tests"
55+
],
56+
"static-analysis": "phpstan analyse --level 5 src",
57+
"tests": "phpunit --testdox"
58+
}
59+
}

phpunit.xml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xsi:noNamespaceSchemaLocation="vendor/phpunit/phpunit/phpunit.xsd"
4+
bootstrap="vendor/autoload.php"
5+
executionOrder="depends,defects"
6+
shortenArraysForExportThreshold="10"
7+
requireCoverageMetadata="true"
8+
beStrictAboutCoverageMetadata="true"
9+
beStrictAboutOutputDuringTests="true"
10+
displayDetailsOnPhpunitDeprecations="true"
11+
failOnPhpunitDeprecation="true"
12+
failOnRisky="true"
13+
failOnWarning="true">
14+
<testsuites>
15+
<testsuite name="Fast Forward Http Message Test Suite">
16+
<directory>tests</directory>
17+
</testsuite>
18+
</testsuites>
19+
<source ignoreIndirectDeprecations="true" restrictNotices="true" restrictWarnings="true">
20+
<include>
21+
<directory>src</directory>
22+
</include>
23+
</source>
24+
<coverage>
25+
<report>
26+
<clover outputFile="public/coverage/clover.xml"/>
27+
<html outputDirectory="public/coverage" lowUpperBound="35" highLowerBound="70"/>
28+
<text outputFile="php://stdout"/>
29+
</report>
30+
</coverage>
31+
<logging>
32+
<testdoxHtml outputFile="public/coverage/testdox.html"/>
33+
</logging>
34+
</phpunit>

0 commit comments

Comments
 (0)