Skip to content

Commit

Permalink
No longer bundle bdk/http-message ! It is now a dependency. Root proj…
Browse files Browse the repository at this point in the history
…ect may require psr/http-message ^1.1 || ^2.0 and we must coexist
  • Loading branch information
bkdotcom committed Jul 12, 2024
1 parent f04acb2 commit e850788
Show file tree
Hide file tree
Showing 48 changed files with 17 additions and 10,153 deletions.
17 changes: 2 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Browser/javascript like console class for PHP

## Installation

This library supports PHP 5.4 - 8.3 and has no userland dependencies.
This library supports PHP 5.4 - 8.3

It is installable and autoloadable via [Composer](https://getcomposer.org/) as [bdk/debug](https://packagist.org/packages/bdk/debug).

Expand All @@ -49,19 +49,7 @@ It is installable and autoloadable via [Composer](https://getcomposer.org/) as [

**installation without Composer**

* [download a release](https://github.com/bkdotcom/PHPDebugConsole/releases) or clone this repository.
* include Autoloader and Debug in your code

```php
// Step 1: include and register our autoloader
require 'path-to/src/Debug/Autoloader.php';
$autoloader = new \bdk\Debug\Autoloader();
$autoloader->register();
// Step 2: you can now instantiate and user Debug
$debug = new \bdk\Debug();
```

See <http://www.bradkent.com/php/debug> for more information
As of v3.3 this is no longer officially supported due to now requiring one or more dependencies.

## Usage

Expand Down Expand Up @@ -114,7 +102,6 @@ $monolog->critical('all your base are belong to them');

## Tests / Quality

![No Dependencies](https://img.shields.io/badge/dependencies-none-333333.svg)
![Supported PHP versions](https://img.shields.io/static/v1?label=PHP&message=5.4%20-%208.3&color=blue)
![Build Status](https://img.shields.io/github/actions/workflow/status/bkdotcom/PHPDebugConsole/phpunit.yml.svg?branch=master&logo=github)
[![Codacy Score](https://img.shields.io/codacy/grade/e950849edfd9463b993386080d39875e/master.svg?logo=codacy)](https://app.codacy.com/gh/bkdotcom/PHPDebugConsole/dashboard)
Expand Down
23 changes: 10 additions & 13 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,10 @@
"bdk\\CurlHttpMessage\\": "src/CurlHttpMessage/",
"bdk\\Debug\\": "src/Debug/",
"bdk\\ErrorHandler\\": "src/ErrorHandler/",
"bdk\\HttpMessage\\": "src/HttpMessage/",
"bdk\\Promise\\": "src/Promise/",
"bdk\\PubSub\\": "src/PubSub/",
"bdk\\Slack\\": "src/Slack/",
"bdk\\Teams\\": "src/Teams/",
"Psr\\Http\\Message\\": "src/Psr7/"
"bdk\\Teams\\": "src/Teams/"
}
},
"autoload-dev": {
Expand All @@ -47,29 +45,28 @@
}
},
"replace": {
"bdk/backtrace": "2.2.1",
"bdk/backtrace": "2.2.2",
"bdk/curl-http-message": "1.0",
"bdk/errorhandler": "3.3.2",
"bdk/http-message": "1.1",
"bdk/errorhandler": "3.3.3",
"bdk/promise": "1.0",
"bdk/pubsub": "3.2.1",
"bdk/pubsub": "3.2",
"bdk/slack": "1.0",
"bdk/teams": "1.0",
"psr/http-message": "1.0.1"
"bdk/teams": "1.0"
},
"require": {
"php": ">=5.4.0"
"php": ">=5.4.0",
"bdk/http-message": "^1.2 || ^2.0 || ^3.0",
},
"require-dev": {
"bdk/devutil": "dev-master",
"bdk/wamp-publisher": "dev-master",
"doctrine/dbal": "^2.5.0",
"guzzlehttp/psr7": "^1.6",
"jdorn/sql-formatter": "^1.2",
"monolog/monolog": "^1.0 | ^2.0 | ^3.0",
"monolog/monolog": "^1.0 || ^2.0 || ^3.0",
"php-curl-class/php-curl-class": ">=8.6",
"phpunit/phpunit": "^4.0 | ^5.0 | ^6.0 | ^7.0 | ^8.0 | ^9.0",
"psr/log": "^1.0 | ^2.0 | ^3.0",
"phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0",
"psr/log": "^1.0 || ^2.0 || ^3.0",
"psr/simple-cache": "^1.0",
"slim/slim": "^2.0",
"squizlabs/php_codesniffer": "^3.6",
Expand Down
4 changes: 0 additions & 4 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
-->
<exclude>
<file>src/Debug/Dump/charData.php</file>
<file>src/HttpMessage/Factory.php</file>
<directory>src/Debug/Framework</directory>
<directory>src/Debug/node_modules</directory>
<directory>src/Psr7</directory>
Expand Down Expand Up @@ -62,9 +61,6 @@
<testsuite name="ErrorHandler">
<directory>tests/ErrorHandler</directory>
</testsuite>
<testsuite name="HttpMessage">
<directory>tests/HttpMessage</directory>
</testsuite>
<testsuite name="Promise">
<directory>tests/Promise</directory>
<file phpVersion="7.0.0" phpVersionOperator=">=">tests/PromisePhpCond/CoroutineTest.php</file>
Expand Down
2 changes: 1 addition & 1 deletion src/Backtrace/Context.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public static function add(array $backtrace, $length = 19)
*/
public static function getFileLines($file, $start = null, $length = null)
{
if (\file_exists($file) === false) {
if (!$file || \file_exists($file) === false) {
return false;
}
$lines = \file($file);
Expand Down
2 changes: 0 additions & 2 deletions src/Debug/Autoloader.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,11 @@ public function register()
'bdk\\CurlHttpMessage\\' => __DIR__ . '/../CurlHttpMessage',
'bdk\\Debug\\' => __DIR__,
'bdk\\ErrorHandler\\' => __DIR__ . '/../ErrorHandler',
'bdk\\HttpMessage\\' => __DIR__ . '/../HttpMessage',
'bdk\\Promise\\' => __DIR__ . '/../Promise',
'bdk\\PubSub\\' => __DIR__ . '/../PubSub',
'bdk\\Slack\\' => __DIR__ . '/../Slack',
'bdk\\Teams\\' => __DIR__ . '/../Teams',
'bdk\\Test\\Debug\\' => __DIR__ . '/../../tests/Debug',
'Psr\\Http\\Message\\' => __DIR__ . '/../Psr7',
);
return \spl_autoload_register(array($this, 'autoload'));
}
Expand Down
142 changes: 0 additions & 142 deletions src/HttpMessage/AbstractStream.php

This file was deleted.

Loading

0 comments on commit e850788

Please sign in to comment.