Skip to content

Commit 48ab1b5

Browse files
authored
Normalize the composer.json files (#247)
* Normalize the composer.json files * Normalize tagInterop
1 parent 3286617 commit 48ab1b5

26 files changed

Lines changed: 396 additions & 373 deletions

File tree

composer.json

Lines changed: 46 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -22,87 +22,89 @@
2222
],
2323
"require": {
2424
"php": "^5.6 || ^7.0 || ^8.0",
25+
"doctrine/cache": "^1.3",
26+
"league/flysystem": "^1.0",
2527
"psr/cache": "^1.0",
2628
"psr/log": "^1.0",
27-
"doctrine/cache": "^1.3",
28-
"psr/simple-cache": "^1.0",
29-
"league/flysystem": "^1.0"
30-
},
31-
"require-dev": {
32-
"defuse/php-encryption": "^2.0",
33-
"phpunit/phpunit": "^5.7.21",
34-
"mockery/mockery": "^1.0",
35-
"cache/integration-tests": "^0.16",
36-
"predis/predis": "^1.1",
37-
"symfony/cache": "^3.1",
38-
"symfony/polyfill-php70": "^1.6",
39-
"illuminate/cache": "^5.4 || ^5.5 || ^5.6"
40-
},
41-
"suggest": {
42-
"ext-apc": "APC extension is required to use the APC Adapter",
43-
"ext-apcu": "APCu extension is required to use the APCu Adapter",
44-
"ext-memcache": "Memcache extension is required to use the Memcache Adapter",
45-
"ext-memcached": "Memcached extension is required to use the Memcached Adapter",
46-
"ext-redis": "Redis extension is required to use the Redis adapter",
47-
"ext-mongodb": "Mongodb extension required to use the Mongodb adapter",
48-
"mongodb/mongodb": "Mongodb lib required to use the Mongodb adapter"
29+
"psr/simple-cache": "^1.0"
4930
},
5031
"replace": {
32+
"cache/adapter-common": "^1",
5133
"cache/apc-adapter": "^1",
5234
"cache/apcu-adapter": "^1",
35+
"cache/array-adapter": "^1",
5336
"cache/chain-adapter": "^1",
54-
"cache/adapter-common": "^1",
5537
"cache/doctrine-adapter": "^1",
5638
"cache/filesystem-adapter": "^1",
39+
"cache/hierarchical-cache": "^1",
40+
"cache/illuminate-adapter": "^1",
5741
"cache/memcache-adapter": "^1",
5842
"cache/memcached-adapter": "^1",
5943
"cache/mongodb-adapter": "^1",
60-
"cache/array-adapter": "^1",
6144
"cache/predis-adapter": "^1",
62-
"cache/redis-adapter": "^1",
63-
"cache/void-adapter": "^1",
6445
"cache/psr-6-doctrine-bridge": "^1",
65-
"cache/hierarchical-cache": "^1",
46+
"cache/redis-adapter": "^1",
6647
"cache/session-handler": "^1",
6748
"cache/taggable-cache": "^1",
68-
"cache/illuminate-adapter": "^1",
69-
"cache/util": "^1"
49+
"cache/util": "^1",
50+
"cache/void-adapter": "^1"
7051
},
7152
"conflict": {
53+
"cache/adapter-common": "<1",
7254
"cache/apc-adapter": "<1",
7355
"cache/apcu-adapter": "<1",
56+
"cache/array-adapter": "<1",
7457
"cache/chain-adapter": "<1",
75-
"cache/adapter-common": "<1",
7658
"cache/doctrine-adapter": "<1",
7759
"cache/filesystem-adapter": "<1",
60+
"cache/hierarchical-cache": "<1",
61+
"cache/illuminate-adapter": "<1",
7862
"cache/memcache-adapter": "<1",
7963
"cache/memcached-adapter": "<1",
8064
"cache/mongodb-adapter": "<1",
81-
"cache/array-adapter": "<1",
8265
"cache/predis-adapter": "<1",
83-
"cache/redis-adapter": "<1",
84-
"cache/void-adapter": "<1",
8566
"cache/psr-6-doctrine-bridge": "<1",
86-
"cache/hierarchical-cache": "<1",
67+
"cache/redis-adapter": "<1",
8768
"cache/session-handler": "<1",
8869
"cache/taggable-cache": "<1",
89-
"cache/illuminate-adapter": "<1",
90-
"cache/util": "<1"
70+
"cache/util": "<1",
71+
"cache/void-adapter": "<1"
72+
},
73+
"require-dev": {
74+
"cache/integration-tests": "^0.16",
75+
"defuse/php-encryption": "^2.0",
76+
"illuminate/cache": "^5.4 || ^5.5 || ^5.6",
77+
"mockery/mockery": "^1.0",
78+
"phpunit/phpunit": "^5.7.21",
79+
"predis/predis": "^1.1",
80+
"symfony/cache": "^3.1",
81+
"symfony/polyfill-php70": "^1.6"
82+
},
83+
"suggest": {
84+
"ext-apc": "APC extension is required to use the APC Adapter",
85+
"ext-apcu": "APCu extension is required to use the APCu Adapter",
86+
"ext-memcache": "Memcache extension is required to use the Memcache Adapter",
87+
"ext-memcached": "Memcached extension is required to use the Memcached Adapter",
88+
"ext-mongodb": "Mongodb extension required to use the Mongodb adapter",
89+
"ext-redis": "Redis extension is required to use the Redis adapter",
90+
"mongodb/mongodb": "Mongodb lib required to use the Mongodb adapter"
91+
},
92+
"extra": {
93+
"branch-alias": {
94+
"dev-master": "1.1-dev"
95+
}
9196
},
92-
"minimum-stability": "dev",
93-
"prefer-stable": true,
9497
"autoload": {
9598
"psr-4": {
9699
"Cache\\": "src/"
97100
},
98-
"files": ["src/inc.php"],
101+
"files": [
102+
"src/inc.php"
103+
],
99104
"exclude-from-classmap": [
100105
"**/Tests/"
101106
]
102107
},
103-
"extra": {
104-
"branch-alias": {
105-
"dev-master": "1.1-dev"
106-
}
107-
}
108+
"minimum-stability": "dev",
109+
"prefer-stable": true
108110
}

norm.sh

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#!/bin/bash
2+
3+
CURRENT_DIR=$(pwd)
4+
ok=0
5+
for PACKAGE in $(find src -maxdepth 4 -type f -name phpunit.xml.dist -exec dirname {} \; | sort)
6+
do
7+
echo ::group::$PACKAGE
8+
echo "$CURRENT_DIR/$PACKAGE"
9+
cd "$CURRENT_DIR/$PACKAGE"
10+
11+
localExit=0
12+
composer update --no-interaction --prefer-dist --optimize-autoloader $COMPOSER_OPTIONS || localExit=1
13+
ok=$(( $localExit || $ok ))
14+
echo ::endgroup::
15+
if [ $localExit -ne 0 ]; then
16+
echo "::error::$PACKAGE error"
17+
fi
18+
composer normalize
19+
done

src/Adapter/Apc/composer.json

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
{
22
"name": "cache/apc-adapter",
3-
"description": "A PSR-6 cache implementation using apc. This implementation supports tags",
43
"type": "library",
5-
"license": "MIT",
6-
"minimum-stability": "dev",
7-
"prefer-stable": true,
4+
"description": "A PSR-6 cache implementation using apc. This implementation supports tags",
85
"keywords": [
96
"cache",
107
"psr-6",
118
"apc"
129
],
1310
"homepage": "http://www.php-cache.com/en/latest/",
11+
"license": "MIT",
1412
"authors": [
1513
{
1614
"name": "Aaron Scherer",
@@ -25,21 +23,26 @@
2523
],
2624
"require": {
2725
"php": "^5.6 || ^7.0 || ^8.0",
26+
"cache/adapter-common": "^1.0",
2827
"psr/cache": "^1.0",
29-
"psr/simple-cache": "^1.0",
30-
"cache/adapter-common": "^1.0"
31-
},
32-
"suggest": {
33-
"ext-apc": "The extension required to use this pool."
34-
},
35-
"require-dev": {
36-
"phpunit/phpunit": "^5.7.21",
37-
"cache/integration-tests": "^0.16"
28+
"psr/simple-cache": "^1.0"
3829
},
3930
"provide": {
4031
"psr/cache-implementation": "^1.0",
4132
"psr/simple-cache-implementation": "^1.0"
4233
},
34+
"require-dev": {
35+
"cache/integration-tests": "^0.16",
36+
"phpunit/phpunit": "^5.7.21"
37+
},
38+
"suggest": {
39+
"ext-apc": "The extension required to use this pool."
40+
},
41+
"extra": {
42+
"branch-alias": {
43+
"dev-master": "1.1-dev"
44+
}
45+
},
4346
"autoload": {
4447
"psr-4": {
4548
"Cache\\Adapter\\Apc\\": ""
@@ -48,9 +51,6 @@
4851
"/Tests/"
4952
]
5053
},
51-
"extra": {
52-
"branch-alias": {
53-
"dev-master": "1.1-dev"
54-
}
55-
}
54+
"minimum-stability": "dev",
55+
"prefer-stable": true
5656
}

src/Adapter/Apcu/composer.json

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
11
{
22
"name": "cache/apcu-adapter",
3-
"description": "A PSR-6 cache implementation using apcu. This implementation supports tags",
43
"type": "library",
5-
"license": "MIT",
6-
"minimum-stability": "dev",
7-
"prefer-stable": true,
4+
"description": "A PSR-6 cache implementation using apcu. This implementation supports tags",
85
"keywords": [
96
"cache",
107
"psr-6",
118
"apcu"
129
],
1310
"homepage": "http://www.php-cache.com/en/latest/",
11+
"license": "MIT",
1412
"authors": [
1513
{
1614
"name": "Aaron Scherer",
@@ -25,20 +23,25 @@
2523
],
2624
"require": {
2725
"php": "^5.6 || ^7.0 || ^8.0",
26+
"cache/adapter-common": "^1.0",
2827
"psr/cache": "^1.0",
29-
"psr/simple-cache": "^1.0",
30-
"cache/adapter-common": "^1.0"
28+
"psr/simple-cache": "^1.0"
29+
},
30+
"provide": {
31+
"psr/cache-implementation": "^1.0",
32+
"psr/simple-cache-implementation": "^1.0"
3133
},
3234
"require-dev": {
33-
"phpunit/phpunit": "^5.7.21",
34-
"cache/integration-tests": "^0.16"
35+
"cache/integration-tests": "^0.16",
36+
"phpunit/phpunit": "^5.7.21"
3537
},
3638
"suggest": {
3739
"ext-apcu": "The extension required to use this pool."
3840
},
39-
"provide": {
40-
"psr/cache-implementation": "^1.0",
41-
"psr/simple-cache-implementation": "^1.0"
41+
"extra": {
42+
"branch-alias": {
43+
"dev-master": "1.1-dev"
44+
}
4245
},
4346
"autoload": {
4447
"psr-4": {
@@ -48,9 +51,6 @@
4851
"/Tests/"
4952
]
5053
},
51-
"extra": {
52-
"branch-alias": {
53-
"dev-master": "1.1-dev"
54-
}
55-
}
54+
"minimum-stability": "dev",
55+
"prefer-stable": true
5656
}

src/Adapter/Chain/composer.json

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,15 @@
11
{
22
"name": "cache/chain-adapter",
3-
"description": "A PSR-6 cache implementation using chain. This implementation supports tags",
43
"type": "library",
5-
"license": "MIT",
6-
"minimum-stability": "dev",
7-
"prefer-stable": true,
4+
"description": "A PSR-6 cache implementation using chain. This implementation supports tags",
85
"keywords": [
96
"cache",
107
"psr-6",
118
"chain",
129
"tag"
1310
],
1411
"homepage": "http://www.php-cache.com/en/latest/",
12+
"license": "MIT",
1513
"authors": [
1614
{
1715
"name": "Aaron Scherer",
@@ -26,19 +24,24 @@
2624
],
2725
"require": {
2826
"php": "^5.6 || ^7.0 || ^8.0",
29-
"psr/cache": "^1.0",
30-
"psr/log": "^1.0",
3127
"cache/adapter-common": "^1.0",
32-
"cache/tag-interop": "^1.0"
28+
"cache/tag-interop": "^1.0",
29+
"psr/cache": "^1.0",
30+
"psr/log": "^1.0"
31+
},
32+
"provide": {
33+
"psr/cache-implementation": "^1.0"
3334
},
3435
"require-dev": {
35-
"phpunit/phpunit": "^5.7.21",
36-
"cache/filesystem-adapter": "^1.0",
3736
"cache/array-adapter": "^1.0",
38-
"cache/integration-tests": "^0.16"
37+
"cache/filesystem-adapter": "^1.0",
38+
"cache/integration-tests": "^0.16",
39+
"phpunit/phpunit": "^5.7.21"
3940
},
40-
"provide": {
41-
"psr/cache-implementation": "^1.0"
41+
"extra": {
42+
"branch-alias": {
43+
"dev-master": "1.1-dev"
44+
}
4245
},
4346
"autoload": {
4447
"psr-4": {
@@ -48,9 +51,6 @@
4851
"/Tests/"
4952
]
5053
},
51-
"extra": {
52-
"branch-alias": {
53-
"dev-master": "1.1-dev"
54-
}
55-
}
54+
"minimum-stability": "dev",
55+
"prefer-stable": true
5656
}

0 commit comments

Comments
 (0)