Skip to content

Commit 2796680

Browse files
authored
Merge pull request #13 from macocci7/dev_1.2.0
Dev 1.2.0
2 parents 015ef02 + 001dca6 commit 2796680

24 files changed

Lines changed: 89 additions & 3456 deletions

.github/workflows/tag_meged_pull_request.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
tools: composer:v2
2424

2525
- name: Checkout code
26-
uses: actions/checkout@v3
26+
uses: actions/checkout@v4
2727
with:
2828
fetch-depth: 0
2929

.github/workflows/test_pull_request.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
tools: composer:v2
1616

1717
- name: Checkout code
18-
uses: actions/checkout@v3
18+
uses: actions/checkout@v4
1919
with:
2020
fetch-depth: 0
2121

@@ -63,12 +63,12 @@ jobs:
6363
tools: composer:v2
6464

6565
- name: Set up Node
66-
uses: actions/setup-node@v3
66+
uses: actions/setup-node@v4
6767
with:
6868
node-version: '14.x'
6969

7070
- name: Checkout code
71-
uses: actions/checkout@v3
71+
uses: actions/checkout@v4
7272
with:
7373
fetch-depth: 0
7474

@@ -126,25 +126,25 @@ jobs:
126126
tools: composer:v2
127127

128128
- name: Set up Node
129-
uses: actions/setup-node@v3
129+
uses: actions/setup-node@v4
130130
with:
131131
node-version: '14.x'
132132

133133
- name: Checkout code
134-
uses: actions/checkout@v3
134+
uses: actions/checkout@v4
135135
with:
136136
fetch-depth: 0
137137

138138
- name: Run Composer
139139
run: composer install --no-interaction
140140

141141
- name: Update PHPUnit for Code Coverage
142-
run: composer require phpunit/phpunit:^9.6 phploc/phploc:* sebastian/version:* --with-all-dependencies
142+
run: composer require phpunit/phpunit:^10.5 sebastian/version:* --with-all-dependencies
143143

144144
- name: PHP Lint
145145
run: ./vendor/bin/parallel-lint src tests examples
146146

147147
- name: Unit tests
148148
run: |
149149
mkdir -p build/logs
150-
./vendor/bin/phpunit ./tests/ --coverage-clover build/logs/clover.xml
150+
XDEBUG_MODE=coverage ./vendor/bin/phpunit ./tests/ --coverage-clover build/logs/clover.xml --coverage-filter=./src/

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
/vendor/
2+
composer.lock
3+
.php-version

.php-version

Lines changed: 0 additions & 1 deletion
This file was deleted.

README.md

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,8 @@ composer require macocci7/php-scatterplot
6161

6262
```php
6363
<?php
64-
require('../vendor/autoload.php');
64+
65+
require_once __DIR__ . '/../vendor/autoload.php';
6566

6667
use Macocci7\PhpScatterplot\Scatterplot;
6768

@@ -82,7 +83,7 @@ composer require macocci7/php-scatterplot
8283
<a href="examples/img/BasicUsage.png"><img src="examples/img/BasicUsage.png" width="400" /></a>
8384

8485
- Details:
85-
- Import Autoloader: `require_once('../vendor/autoload.php')`
86+
- Import Autoloader: `require_once __DIR__ . '/../vendor/autoload.php'`
8687
- Declare: `use Macocci7\PhpScatterplot`
8788
- Prepare Data: `$layers = [ $layer ]`
8889
- `$layers`: `array<int|string, array<string, list<int|float>>>`
@@ -100,7 +101,7 @@ composer require macocci7/php-scatterplot
100101
```php
101102
<?php
102103

103-
require('../vendor/autoload.php');
104+
require_once __DIR__ . '/../vendor/autoload.php';
104105

105106
use Macocci7\PhpScatterplot\Scatterplot;
106107

@@ -153,7 +154,7 @@ composer require macocci7/php-scatterplot
153154
```php
154155
<?php
155156

156-
require('../vendor/autoload.php');
157+
require_once __DIR__ . '/../vendor/autoload.php';
157158

158159
use Macocci7\PhpScatterplot\Scatterplot;
159160

@@ -326,7 +327,7 @@ Second, Code PHP like this:
326327
```php
327328
<?php
328329

329-
require('../vendor/autoload.php');
330+
require_once __DIR__ . '/../vendor/autoload.php';
330331

331332
use Macocci7\PhpScatterplot\Scatterplot;
332333

@@ -368,7 +369,7 @@ Then, run the PHP code.
368369
```php
369370
<?php
370371

371-
require('../vendor/autoload.php');
372+
require_once __DIR__ . '/../vendor/autoload.php';
372373

373374
use Macocci7\PhpScatterplot\Scatterplot;
374375

@@ -475,7 +476,7 @@ Then, run the PHP code.
475476
```php
476477
<?php
477478

478-
require('../vendor/autoload.php');
479+
require_once __DIR__ . '/../vendor/autoload.php';
479480

480481
use Macocci7\PhpScatterplot\Scatterplot;
481482

@@ -518,7 +519,8 @@ Then, run the PHP code.
518519

519520
```php
520521
<?php
521-
require('../vendor/autoload.php');
522+
523+
require_once __DIR__ . '/../vendor/autoload.php';
522524

523525
use Macocci7\PhpScatterplot\Analyzer;
524526

@@ -657,6 +659,6 @@ Then, run the PHP code.
657659

658660
*Document written: 2023/06/06*
659661

660-
*Document updated: 2024/03/10*
662+
*Document updated: 2024/04/18*
661663

662664
Copyright 2023 - 2024 macocci7.

bin/TestAndLint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ test_and_lint() {
5555
echo "-----------------------------------------------------------"
5656
echo "[PHP $1][phpunit]"
5757
./vendor/bin/phpunit ./tests/ \
58-
--color auto
58+
--color=auto
5959
echo "-----------------------------------------------------------"
6060
}
6161

composer.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "macocci7/php-scatterplot",
33
"description": "it's easy to use for creating scatter plots.",
4-
"version": "1.1.1",
4+
"version": "1.2.0",
55
"type": "library",
66
"license": "MIT",
77
"autoload": {
@@ -17,18 +17,18 @@
1717
],
1818
"minimum-stability": "stable",
1919
"require": {
20-
"intervention/image": "^3.4",
21-
"macocci7/php-frequency-table": "^1.2",
20+
"php": ">=8.1",
21+
"intervention/image": "^3.5",
22+
"macocci7/php-frequency-table": "^1.3",
2223
"macocci7/php-csv": "^1.0",
2324
"macocci7/php-combination": "^1.0",
2425
"nette/neon": "^3.4"
2526
},
2627
"require-dev": {
2728
"squizlabs/php_codesniffer": "^3.7",
2829
"phpmd/phpmd": "^2.15",
29-
"phpunit/phpunit": "^9.6",
30+
"phpunit/phpunit": "^10.5",
3031
"phpstan/phpstan": "^1.10",
31-
"phploc/phploc": "^7.0",
3232
"php-parallel-lint/php-parallel-lint": "^1.3"
3333
}
3434
}

0 commit comments

Comments
 (0)