diff --git a/NOTICE b/NOTICE index 5e96ab6c..f15d3486 100644 --- a/NOTICE +++ b/NOTICE @@ -1,3 +1,5 @@ Limoncello framework Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Application/NOTICE b/components/Application/NOTICE index 6f091818..2363e7fb 100644 --- a/components/Application/NOTICE +++ b/components/Application/NOTICE @@ -1,3 +1,5 @@ Application utility components Copyright 2015-2020 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Application/composer.json b/components/Application/composer.json index 476e664d..8e8a14d1 100644 --- a/components/Application/composer.json +++ b/components/Application/composer.json @@ -1,16 +1,20 @@ { - "name": "limoncello-php/application", + "name": "lolltec/limoncello-php-component-application", "description": "PHP application components (PSR-7).", "keywords": ["limoncello", "framework", "PSR-7", "PSR7"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Application", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Application", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { @@ -19,11 +23,11 @@ "doctrine/dbal": "^2.6.3", "monolog/monolog": "^2.0", "neomerx/cors-psr7": "^2.0.0", - "limoncello-php/contracts": "^0.10.0", - "limoncello-php/core": "^0.10.0", - "limoncello-php/auth": "^0.10.0", - "limoncello-php/l10n": "^0.10.0", - "limoncello-php/validation": "^0.10.0" + "lolltec/limoncello-php-component-contracts": "dev-master", + "lolltec/limoncello-php-component-core": "dev-master", + "lolltec/limoncello-php-component-auth": "dev-master", + "lolltec/limoncello-php-component-l10n": "dev-master", + "lolltec/limoncello-php-component-validation": "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -49,14 +53,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Application/docker-compose.yml b/components/Application/docker-compose.yml index 2b5004c0..baebf17c 100644 --- a/components/Application/docker-compose.yml +++ b/components/Application/docker-compose.yml @@ -4,6 +4,22 @@ # https://docs.docker.com/compose/overview/ # https://docs.docker.com/compose/compose-file/ +cli_7_1_php: + build: ./../../docker/7_1_cli + container_name: cli_7_1_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + +cli_7_2_php: + build: ./../../docker/7_2_cli + container_name: cli_7_2_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_7_3_php: build: ./../../docker/7_3_cli container_name: cli_7_3_php_limoncello diff --git a/components/Application/readme.md b/components/Application/readme.md index dbabfff7..9df06922 100644 --- a/components/Application/readme.md +++ b/components/Application/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/application/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/application/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/application/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/application/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/application.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/application) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-application/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-application/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-application/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-application/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-application.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-application) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is application utility component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is application utility component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Auth/NOTICE b/components/Auth/NOTICE index b01323f5..c89ccd6d 100644 --- a/components/Auth/NOTICE +++ b/components/Auth/NOTICE @@ -1,3 +1,5 @@ Authorization implementation Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Auth/composer.json b/components/Auth/composer.json index 71c2131a..70daf682 100644 --- a/components/Auth/composer.json +++ b/components/Auth/composer.json @@ -1,22 +1,26 @@ { - "name": "limoncello-php/auth", + "name": "lolltec/limoncello-php-component-auth", "description": "Limoncello framework authorization support.", "keywords": ["limoncello", "framework", "auth", "authorization"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Auth", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Auth", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.1.0", "psr/log": "^1.0", - "limoncello-php/container": "^0.10.0" + "lolltec/limoncello-php-component-container": "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -42,14 +46,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.7.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Commands/NOTICE b/components/Commands/NOTICE index e75bc587..0a0d4553 100644 --- a/components/Commands/NOTICE +++ b/components/Commands/NOTICE @@ -1,3 +1,5 @@ Commands support Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Commands/composer.json b/components/Commands/composer.json index 5a717921..c77b97e5 100644 --- a/components/Commands/composer.json +++ b/components/Commands/composer.json @@ -1,24 +1,28 @@ { - "name": "limoncello-php/commands", + "name": "lolltec/limoncello-php-component-commands", "type": "composer-plugin", "description": "Limoncello application commands support.", "keywords": ["limoncello", "framework", "composer", "commands"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Commands", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Commands", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.1.0", "composer-plugin-api": "^1.1", - "limoncello-php/common": "^0.10.0", - "limoncello-php/contracts": "^0.10.0" + "lolltec/limoncello-php-component-common": "dev-master", + "lolltec/limoncello-php-component-contracts": "dev-master" }, "require-dev": { "composer/composer": "^1.5.0", @@ -44,18 +48,20 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, "config": { "optimize-autoloader": true }, "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - }, "class": "Limoncello\\Commands\\ComposerPlugin" }, "minimum-stability": "dev", diff --git a/components/Commands/readme.md b/components/Commands/readme.md index c4c9cac4..5cc4d971 100644 --- a/components/Commands/readme.md +++ b/components/Commands/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/commands/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/commands/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/commands/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/commands/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/commands.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/commands) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-commands/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-commands/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-commands/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-commands/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-commands.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-commands) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is Commands support component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is Commands support component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Common/NOTICE b/components/Common/NOTICE index 252d6df2..9735b636 100644 --- a/components/Common/NOTICE +++ b/components/Common/NOTICE @@ -1,3 +1,5 @@ Limoncello framework common components Copyright 2015-2020 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Common/composer.json b/components/Common/composer.json index 3f02bb44..3f1de59f 100644 --- a/components/Common/composer.json +++ b/components/Common/composer.json @@ -1,21 +1,25 @@ { - "name": "limoncello-php/common", + "name": "lolltec/limoncello-php-component-common", "description": "PHP framework common (PSR-7).", "keywords": ["limoncello", "framework", "PSR-7", "PSR7"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Common", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Common", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.3.0", - "limoncello-php/contracts": "^0.10.0" + "lolltec/limoncello-php-component-contracts": "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -41,12 +45,16 @@ "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", + "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", + "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Common/docker-compose.yml b/components/Common/docker-compose.yml index 5572137e..bc930864 100644 --- a/components/Common/docker-compose.yml +++ b/components/Common/docker-compose.yml @@ -4,6 +4,22 @@ # https://docs.docker.com/compose/overview/ # https://docs.docker.com/compose/compose-file/ +cli_7_1_php: + build: ./../../docker/7_1_cli + container_name: cli_7_1_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + +cli_7_2_php: + build: ./../../docker/7_2_cli + container_name: cli_7_2_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_7_3_php: build: ./../../docker/7_3_cli container_name: cli_7_3_php_limoncello diff --git a/components/Common/readme.md b/components/Common/readme.md index ad46b103..a832ffd3 100644 --- a/components/Common/readme.md +++ b/components/Common/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/common/badges/quality-scommon.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/common/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/common/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/common/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/common.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/common) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-common/badges/quality-scommon.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-common/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-common/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-common/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-common.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-common) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is common components for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is common components for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Container/NOTICE b/components/Container/NOTICE index 9571eedb..1d570e8c 100644 --- a/components/Container/NOTICE +++ b/components/Container/NOTICE @@ -1,3 +1,5 @@ Container implementation Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Container/composer.json b/components/Container/composer.json index e940eb6b..77c00c2e 100644 --- a/components/Container/composer.json +++ b/components/Container/composer.json @@ -1,22 +1,26 @@ { - "name": "limoncello-php/container", + "name": "lolltec/limoncello-php-component-container", "description": "Lightweight container (container interoperability).", "keywords": ["limoncello", "framework", "container", "interoperability", "container interoperability", "PSR"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Container", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Container", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.1.0", "pimple/pimple": "^3.0", - "limoncello-php/contracts": "^0.10.0" + "lolltec/limoncello-php-component-contracts": "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -40,14 +44,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Container/docker-compose.yml b/components/Container/docker-compose.yml index 203db34d..ffa107e8 100644 --- a/components/Container/docker-compose.yml +++ b/components/Container/docker-compose.yml @@ -28,6 +28,14 @@ cli_7_3_php: working_dir: /app tty: true +cli_7_4_php: + build: ./../../docker/7_4_cli + container_name: cli_7_4_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_hhvm: image: hhvm/hhvm container_name: cli_hhvm_limoncello diff --git a/components/Container/readme.md b/components/Container/readme.md index a7a5ee41..78ae0a4b 100644 --- a/components/Container/readme.md +++ b/components/Container/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/container/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/container/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/container/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/container/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/container.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/container) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-container/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-container/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-container/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-container/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-container.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-container) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is Container component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is Container component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Contracts/composer.json b/components/Contracts/composer.json index 79f47dca..47fa587c 100644 --- a/components/Contracts/composer.json +++ b/components/Contracts/composer.json @@ -1,16 +1,20 @@ { - "name": "limoncello-php/contracts", + "name": "lolltec/limoncello-php-component-contracts", "description": "Limoncello PHP Framework Contracts (interfaces) required for components integration.", "keywords": ["limoncello", "framework", "contracts", "interfaces"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Contracts", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Contracts", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { @@ -32,9 +36,7 @@ "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Contracts/readme.md b/components/Contracts/readme.md index f2ac4791..68ae10d9 100644 --- a/components/Contracts/readme.md +++ b/components/Contracts/readme.md @@ -1,10 +1,10 @@ -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is contracts/interfaces component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is contracts/interfaces component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Contracts/src/Data/TimestampFields.php b/components/Contracts/src/Data/TimestampFields.php index 7f827aec..51341e36 100644 --- a/components/Contracts/src/Data/TimestampFields.php +++ b/components/Contracts/src/Data/TimestampFields.php @@ -1,6 +1,6 @@ =7.1.0", - "limoncello-php/contracts": "^0.10.0" + "lolltec/limoncello-php-component-contracts": "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -40,14 +44,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Crypt/docker-compose.yml b/components/Crypt/docker-compose.yml index 203db34d..ffa107e8 100644 --- a/components/Crypt/docker-compose.yml +++ b/components/Crypt/docker-compose.yml @@ -28,6 +28,14 @@ cli_7_3_php: working_dir: /app tty: true +cli_7_4_php: + build: ./../../docker/7_4_cli + container_name: cli_7_4_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_hhvm: image: hhvm/hhvm container_name: cli_hhvm_limoncello diff --git a/components/Crypt/readme.md b/components/Crypt/readme.md index f5a920a3..91183988 100644 --- a/components/Crypt/readme.md +++ b/components/Crypt/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/crypt/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/crypt/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/crypt/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/crypt/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/crypt.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/crypt) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-crypt/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-crypt/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-crypt/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-crypt/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-crypt.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-crypt) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is cryptography component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is cryptography component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Data/NOTICE b/components/Data/NOTICE index 436f82af..dc4ec018 100644 --- a/components/Data/NOTICE +++ b/components/Data/NOTICE @@ -1,3 +1,5 @@ Data implementation Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Data/composer.json b/components/Data/composer.json index d9386d08..a901032f 100644 --- a/components/Data/composer.json +++ b/components/Data/composer.json @@ -1,22 +1,26 @@ { - "name": "limoncello-php/data", + "name": "lolltec/limoncello-php-component-data", "description": "Data library for Limoncello PHP framework.", "keywords": ["limoncello", "framework", "data", "migration", "seed"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Data", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Data", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.1.0", - "doctrine/dbal": "^2.6.3", - "limoncello-php/contracts": "^0.10.0" + "doctrine/dbal": "~2.7.0", + "lolltec/limoncello-php-component-contracts": "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -41,14 +45,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Data/docker-compose.yml b/components/Data/docker-compose.yml index 203db34d..ffa107e8 100644 --- a/components/Data/docker-compose.yml +++ b/components/Data/docker-compose.yml @@ -28,6 +28,14 @@ cli_7_3_php: working_dir: /app tty: true +cli_7_4_php: + build: ./../../docker/7_4_cli + container_name: cli_7_4_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_hhvm: image: hhvm/hhvm container_name: cli_hhvm_limoncello diff --git a/components/Data/readme.md b/components/Data/readme.md index 5123c767..469f8735 100644 --- a/components/Data/readme.md +++ b/components/Data/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/data/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/data/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/data/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/data/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/data.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/data) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-data/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-data/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-data/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-data/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-data.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-data) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is data component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is data component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Data/src/Migrations/MigrationTrait.php b/components/Data/src/Migrations/MigrationTrait.php index dcc94347..1ff696f7 100644 --- a/components/Data/src/Migrations/MigrationTrait.php +++ b/components/Data/src/Migrations/MigrationTrait.php @@ -28,7 +28,16 @@ use Limoncello\Contracts\Data\ModelSchemaInfoInterface; use Limoncello\Contracts\Data\RelationshipTypes; use Limoncello\Contracts\Data\TimestampFields; +use Limoncello\Contracts\Data\UuidFields; use Limoncello\Data\Contracts\MigrationContextInterface; +use Limoncello\Flute\Types\GeometryCollectionType; +use Limoncello\Flute\Types\LineStringType; +use Limoncello\Flute\Types\MultiLineStringType; +use Limoncello\Flute\Types\MultiPointType; +use Limoncello\Flute\Types\MultiPolygonType; +use Limoncello\Flute\Types\PointType; +use Limoncello\Flute\Types\PolygonType; +use Limoncello\Flute\Types\UuidType; use Psr\Container\ContainerInterface; use function array_key_exists; use function assert; @@ -326,15 +335,53 @@ protected function float(string $name): Closure } /** - * @param string $name + * @param string $name + * @param int|null $default * * @return Closure */ - protected function string(string $name): Closure + protected function nullableFloat(string $name, int $default = null): Closure { - return function (Table $table, MigrationContextInterface $context) use ($name) { + return function (Table $table) use ($name, $default) { + $table->addColumn($name, Type::FLOAT)->setUnsigned(false)->setNotnull(false)->setDefault($default); + }; + } + + /** + * @param string $name + * @param int|null $default + * + * @return Closure + */ + protected function unsignedFloat(string $name, int $default = null): Closure + { + return $this->unsignedFloatImpl($name, true, $default); + } + + /** + * @param string $name + * @param int|null $default + * + * @return Closure + */ + protected function nullableUnsignedFloat(string $name, int $default = null): Closure + { + return $this->unsignedFloatImpl($name, false, $default); + } + + /** + * @param string $name + * + * @param string|null $default + * + * @return Closure + */ + protected function string(string $name, string $default = null): Closure + { + return function (Table $table, MigrationContextInterface $context) use ($name, $default) { $length = $context->getModelSchemas()->getAttributeLength($context->getModelClass(), $name); - $table->addColumn($name, Type::STRING)->setLength($length)->setNotnull(true); + $column = $table->addColumn($name, Type::STRING)->setLength($length)->setNotnull(true); + $default === null ?: $column->setDefault($default); }; } @@ -391,6 +438,18 @@ protected function bool(string $name, bool $default = null): Closure }; } + /** + * @param string $name + * + * @return Closure + */ + protected function nullableBool(string $name): Closure + { + return function (Table $table) use ($name) { + $column = $table->addColumn($name, Type::BOOLEAN)->setNotnull(false); + }; + } + /** * @param string $name * @@ -511,6 +570,271 @@ protected function nullableDate(string $name): Closure }; } + /** + * @param string $name + * + * @return Closure + */ + protected function time(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, Type::TIME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullableTime(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, Type::TIME)->setNotnull(false); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function json(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, Type::JSON)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullableJson(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, Type::JSON)->setNotnull(false); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function primaryUuid(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, UuidType::NAME)->setNotnull(true); + $table->setPrimaryKey([$name]); + }; + } + + /** + * @return Closure + */ + protected function defaultUuid(): Closure + { + return function (Table $table) { + $uuid = UuidFields::FIELD_UUID; + + $table->addColumn($uuid, UuidType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function uuid(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, UuidType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullableUuid(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, UuidType::NAME)->setNotnull(false); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function point(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, PointType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullablePoint(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, PointType::NAME)->setNotnull(false); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function multiPoint(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, MultiPointType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullableMultiPoint(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, MultiPointType::NAME)->setNotnull(false); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function lineString(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, LineStringType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullableLineString(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, LineStringType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function multiLineString(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, MultiLineStringType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullableMultiLineString(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, MultiLineStringType::NAME)->setNotnull(false); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function polygon(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, PolygonType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullablePolygon(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, PolygonType::NAME)->setNotnull(false); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function multiPolygon(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, MultiPolygonType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullableMultiPolygon(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, MultiPolygonType::NAME)->setNotnull(false); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function geometryCollection(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, GeometryCollectionType::NAME)->setNotnull(true); + }; + } + + /** + * @param string $name + * + * @return Closure + */ + protected function nullableGeometryCollection(string $name): Closure + { + return function (Table $table) use ($name) { + $table->addColumn($name, GeometryCollectionType::NAME)->setNotnull(false); + }; + } + /** * @param string[] $names * @@ -775,6 +1099,21 @@ private function unsignedIntImpl(string $name, bool $notNullable, $default = nul }; } + /** + * @param string $name + * @param bool $notNullable + * @param null $default + * + * @return Closure + */ + private function unsignedFloatImpl(string $name, bool $notNullable, $default = null): Closure + { + return function (Table $table) use ($name, $notNullable, $default) { + $column = $table->addColumn($name, Type::FLOAT)->setUnsigned(true)->setNotnull($notNullable); + $default === null ?: $column->setDefault($default); + }; + } + /** @noinspection PhpTooManyParametersInspection * @param string $localKey * @param string $foreignTable diff --git a/components/Events/NOTICE b/components/Events/NOTICE index bc43c20e..0f87c323 100644 --- a/components/Events/NOTICE +++ b/components/Events/NOTICE @@ -1,3 +1,5 @@ Events implementation Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Events/composer.json b/components/Events/composer.json index 477f1328..3d2d6e95 100644 --- a/components/Events/composer.json +++ b/components/Events/composer.json @@ -1,22 +1,26 @@ { - "name": "limoncello-php/events", + "name": "lolltec/limoncello-php-component-events", "description": "Events library for Limoncello PHP framework.", "keywords": ["limoncello", "framework", "events"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Events", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Events", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.1.0", - "limoncello-php/contracts": "^0.10.0", - "limoncello-php/core": "^0.10.0" + "lolltec/limoncello-php-component-contracts": "dev-master", + "lolltec/limoncello-php-component-core": "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -41,14 +45,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Events/docker-compose.yml b/components/Events/docker-compose.yml index 203db34d..ffa107e8 100644 --- a/components/Events/docker-compose.yml +++ b/components/Events/docker-compose.yml @@ -28,6 +28,14 @@ cli_7_3_php: working_dir: /app tty: true +cli_7_4_php: + build: ./../../docker/7_4_cli + container_name: cli_7_4_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_hhvm: image: hhvm/hhvm container_name: cli_hhvm_limoncello diff --git a/components/Events/readme.md b/components/Events/readme.md index 0001d8a5..8ca8ce52 100644 --- a/components/Events/readme.md +++ b/components/Events/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/events/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/events/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/events/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/events/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/events.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/events) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-events/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-events/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-events/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-events/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-events.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-events) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is events component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is events component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Flute/NOTICE b/components/Flute/NOTICE index f9e31d14..9a7a3084 100644 --- a/components/Flute/NOTICE +++ b/components/Flute/NOTICE @@ -1,3 +1,5 @@ JSON API implementation Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Flute/composer.json b/components/Flute/composer.json index f3562e8e..9abd7d6b 100644 --- a/components/Flute/composer.json +++ b/components/Flute/composer.json @@ -1,16 +1,20 @@ { - "name": "limoncello-php/flute", + "name": "lolltec/limoncello-php-component-flute", "description": "Limoncello framework json-api support.", "keywords": ["limoncello", "framework", "json-api", "flute"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Flute", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Flute", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { @@ -18,12 +22,14 @@ "ext-intl" : "*", "psr/log": "1.1.0", "zendframework/zend-diactoros": "^2.0", - "doctrine/dbal": "^2.6.3", + "doctrine/dbal": "~2.7.0", "neomerx/json-api": "^3.0.0", - "limoncello-php/common": "^0.10.0", - "limoncello-php/contracts": "^0.10.0", - "limoncello-php/l10n": "^0.10.0", - "limoncello-php/validation": "^0.10.0" + "lolltec/limoncello-php-component-common": "dev-master", + "lolltec/limoncello-php-component-contracts": "dev-master", + "lolltec/limoncello-php-component-l10n": "dev-master", + "lolltec/limoncello-php-component-validation": "dev-master", + "brick/geo": "^0.2.0", + "ramsey/uuid-doctrine": "^1.6.0" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -31,7 +37,7 @@ "scrutinizer/ocular": "^1.4", "phpunit/phpunit": "^7.0", "mockery/mockery": "^1.0", - "limoncello-php/container": "^0.10.0", + "lolltec/limoncello-php-component-container": "dev-master", "fzaninotto/faker": "^1.7" }, "autoload": { @@ -51,14 +57,17 @@ "test-unit-with-coverage": "./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Flute/docker-compose.yml b/components/Flute/docker-compose.yml index 203db34d..ffa107e8 100644 --- a/components/Flute/docker-compose.yml +++ b/components/Flute/docker-compose.yml @@ -28,6 +28,14 @@ cli_7_3_php: working_dir: /app tty: true +cli_7_4_php: + build: ./../../docker/7_4_cli + container_name: cli_7_4_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_hhvm: image: hhvm/hhvm container_name: cli_hhvm_limoncello diff --git a/components/Flute/readme.md b/components/Flute/readme.md index f7735621..a5e508f2 100644 --- a/components/Flute/readme.md +++ b/components/Flute/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/flute/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/flute/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/flute/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/flute/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/flute.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/flute) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-flute/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-flute/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-flute/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-flute/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-flute.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-flute) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is JSON API implementation component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is JSON API implementation component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Flute/src/Api/Crud.php b/components/Flute/src/Api/Crud.php index b9abd8bb..11893262 100644 --- a/components/Flute/src/Api/Crud.php +++ b/components/Flute/src/Api/Crud.php @@ -933,6 +933,36 @@ protected function createIndexModelBuilder(iterable $columns = null): ModelQuery return $result; } + /** + * @param iterable|null $columns + * + * @return ModelQueryBuilder + * + * @throws DBALException + */ + protected function createIndexModelBuilderWithoutPaging(iterable $columns = null): ModelQueryBuilder + { + $builder = $this->createBuilder($this->getModelClass()); + + $this + ->applyColumnMapper($builder); + + $builder + ->selectModelColumns($columns) + ->fromModelTable(); + + $this + ->applyAliasFilters($builder) + ->applySorts($builder) + ->applyRelationshipFiltersAndSorts($builder); + + $result = $this->builderOnIndex($builder); + + $this->clearBuilderParameters(); + + return $result; + } + /** * @return ModelQueryBuilder * @@ -966,6 +996,19 @@ public function index(): PaginatedDataInterface return $data; } + /** + * @inheritdoc + * + * @throws DBALException + */ + public function indexWithoutPaging(): PaginatedDataInterface + { + $builder = $this->createIndexModelBuilderWithoutPaging(); + $data = $this->fetchResources($builder, $builder->getModelClass()); + + return $data; + } + /** * @inheritdoc * @@ -1011,6 +1054,20 @@ public function count(): ?int return $result === false ? null : (int)$result; } + /** + * @inheritdoc + * + * @throws DBALException + */ + public function countWithoutPaging(): ?int + { + $result = $this->builderOnCount( + $this->createCountBuilderFromBuilder($this->createIndexModelBuilderWithoutPaging()) + )->execute()->fetchColumn(); + + return $result === false ? null : (int)$result; + } + /** * @param string $relationshipName * @param iterable|null $relationshipFilters diff --git a/components/Flute/src/Contracts/Api/CrudInterface.php b/components/Flute/src/Contracts/Api/CrudInterface.php index 17a7e895..e25e3ec8 100644 --- a/components/Flute/src/Contracts/Api/CrudInterface.php +++ b/components/Flute/src/Contracts/Api/CrudInterface.php @@ -151,6 +151,11 @@ public function fetchColumn(QueryBuilder $builder, string $modelClass, string $c */ public function index(): PaginatedDataInterface; + /** + * @return PaginatedDataInterface + */ + public function indexWithoutPaging(): PaginatedDataInterface; + /** * @return array */ @@ -168,6 +173,11 @@ public function read(string $index); */ public function count(): ?int; + /** + * @return int|null + */ + public function countWithoutPaging(): ?int; + /** * @return int */ diff --git a/components/Flute/src/Contracts/Validation/ErrorCodes.php b/components/Flute/src/Contracts/Validation/ErrorCodes.php index d9604c1f..6d86baa3 100644 --- a/components/Flute/src/Contracts/Validation/ErrorCodes.php +++ b/components/Flute/src/Contracts/Validation/ErrorCodes.php @@ -55,8 +55,11 @@ interface ErrorCodes extends BaseErrorCodes /** Message code */ const INVALID_OPERATION_ARGUMENTS = self::UNIQUE_IN_DATABASE_SINGLE + 1; + /** Message code */ + const INVALID_UUID = self::INVALID_OPERATION_ARGUMENTS + 1; + // Special code for those who extend this enum /** Message code */ - const FLUTE_LAST = self::INVALID_OPERATION_ARGUMENTS; + const FLUTE_LAST = self::INVALID_UUID; } diff --git a/components/Flute/src/Encoder/Encoder.php b/components/Flute/src/Encoder/Encoder.php index a6c8e339..884acfc3 100644 --- a/components/Flute/src/Encoder/Encoder.php +++ b/components/Flute/src/Encoder/Encoder.php @@ -103,7 +103,7 @@ private function handleRelationshipStorageAndPagingData($data) */ private function addPagingLinksIfNeeded(PaginatedDataInterface $data): void { - if ($data->isCollection() === true && + if ($data->isCollection() === true && count($data->getData()) > 0 && (0 < $data->getOffset() || $data->hasMoreItems() === true) && $this->getOriginalUri() !== null ) { diff --git a/components/Flute/src/Http/Traits/DefaultControllerMethodsTrait.php b/components/Flute/src/Http/Traits/DefaultControllerMethodsTrait.php index aceb016e..a775cfa8 100644 --- a/components/Flute/src/Http/Traits/DefaultControllerMethodsTrait.php +++ b/components/Flute/src/Http/Traits/DefaultControllerMethodsTrait.php @@ -85,8 +85,10 @@ protected static function defaultIndexHandler( $queryParser->parse(null, $queryParams); $models = $mapper->applyQueryParameters($queryParser, $crud)->index(); + $modelsCount = $mapper->applyQueryParameters($queryParser, $crud)->countWithoutPaging(); static::defaultApplyIncludesAndFieldSetsToEncoder($queryParser, $encoder); + static::defaultApplyMetaToEncoder($queryParser, $encoder, $models, $modelsCount); $responses = static::defaultCreateResponses($requestUri, $encoder); $response = ($models->getData()) === null ? $responses->getCodeResponse(404) : $responses->getContentResponse($models); @@ -275,7 +277,7 @@ protected static function defaultCreate( $captures = $parser->assert($jsonData)->getCaptures(); - list ($index, $attributes, $toMany) = static::mapSchemaDataToModelData($captures, $schemaClass, $schemaInfo); + [$index, $attributes, $toMany] = static::mapSchemaDataToModelData($captures, $schemaClass, $schemaInfo); try { $index = $crud->create($index, $attributes, $toMany); @@ -411,7 +413,7 @@ protected static function defaultUpdate( // validate the data $captures = $parser->assert($jsonData)->getCaptures(); - list ($index, $attributes, $toMany) = static::mapSchemaDataToModelData($captures, $schemaClass, $schemaInfo); + [$index, $attributes, $toMany] = static::mapSchemaDataToModelData($captures, $schemaClass, $schemaInfo); try { $updated = $crud->update((string)$index, $attributes, $toMany); @@ -639,7 +641,7 @@ protected static function defaultReplaceInRelationship( // If we are here then we have something in 'data' section. $validatedIndex = (string)$queryParser->parse($index)->getIdentity(); - list (, $attributes, $toMany) = static::mapSchemaDataToModelData($captures, $schemaClass, $schemaInfo); + [, $attributes, $toMany] = static::mapSchemaDataToModelData($captures, $schemaClass, $schemaInfo); $updated = $crud->update($validatedIndex, $attributes, $toMany); @@ -756,6 +758,32 @@ protected static function defaultApplyIncludesAndFieldSetsToEncoder( } } + /** + * @param JsonApiQueryParserInterface $queryParser + * @param EncoderInterface $encoder + * @param PaginatedDataInterface $models + * @param int $modelsCount + * + * @return void + */ + protected static function defaultApplyMetaToEncoder( + JsonApiQueryParserInterface $queryParser, + EncoderInterface $encoder, + PaginatedDataInterface $models, + int $modelsCount + ): void { + if ($modelsCount > 0 && + ($queryParser->hasPaging() === true && + $models->hasMoreItems() === true) + ) { + $encoder->withMeta([ + 'items' => [ + 'total' => $modelsCount, + ], + ]); + } + } + /** * @param ContainerInterface $container * @param string|null $class diff --git a/components/Flute/src/L10n/Messages.php b/components/Flute/src/L10n/Messages.php index e1c61750..cc129cc1 100644 --- a/components/Flute/src/L10n/Messages.php +++ b/components/Flute/src/L10n/Messages.php @@ -68,4 +68,7 @@ interface Messages extends \Limoncello\Validation\I18n\Messages /** @var string Validation Message Template */ const INVALID_OPERATION_ARGUMENTS = 'Invalid Operation Arguments.'; + + /** @var string Validation Message Template */ + const INVALID_UUID = 'The value should be a valid UUID.'; } diff --git a/components/Flute/src/Package/FluteContainerConfigurator.php b/components/Flute/src/Package/FluteContainerConfigurator.php index c05f79cc..c78a11fb 100644 --- a/components/Flute/src/Package/FluteContainerConfigurator.php +++ b/components/Flute/src/Package/FluteContainerConfigurator.php @@ -24,10 +24,22 @@ use Limoncello\Flute\Http\ThrowableHandlers\FluteThrowableHandler; use Limoncello\Flute\Types\DateTimeType; use Limoncello\Flute\Types\DateType; +use Limoncello\Flute\Types\GeometryCollectionType; +use Limoncello\Flute\Types\LineStringType; +use Limoncello\Flute\Types\MultiLineStringType; +use Limoncello\Flute\Types\MultiPointType; +use Limoncello\Flute\Types\MultiPolygonType; +use Limoncello\Flute\Types\PointType; +use Limoncello\Flute\Types\PolygonType; +use Limoncello\Flute\Types\UuidType; use Limoncello\Flute\Validation\Form\Execution\FormValidatorFactory; use Limoncello\Flute\Validation\JsonApi\Execution\JsonApiParserFactory; use Psr\Container\ContainerInterface as PsrContainerInterface; use Psr\Log\LoggerInterface; +use Ramsey\Uuid\Uuid; +use Ramsey\Uuid\UuidFactoryInterface; +use Ramsey\Uuid\Validator\GenericValidator as UuidValidator; +use Ramsey\Uuid\Validator\ValidatorInterface as UuidValidatorInterface; /** * @package Limoncello\Flute @@ -104,9 +116,29 @@ public static function configureContainer(LimoncelloContainerInterface $containe return $factory; }; + $container[UuidFactoryInterface::class] = function (): UuidFactoryInterface { + return Uuid::getFactory(); + }; + + $container[UuidValidatorInterface::class] = function (): UuidValidatorInterface { + return new UuidValidator(); + }; + // register date/date time types Type::hasType(DateTimeType::NAME) === true ?: Type::addType(DateTimeType::NAME, DateTimeType::class); Type::hasType(DateType::NAME) === true ?: Type::addType(DateType::NAME, DateType::class); + + // register spatial types + Type::hasType(PointType::NAME) === true ?: Type::addType(PointType::NAME, PointType::class); + Type::hasType(MultiPointType::NAME) === true ?: Type::addType(MultiPointType::NAME, MultiPointType::class); + Type::hasType(LineStringType::NAME) === true ?: Type::addType(LineStringType::NAME, LineStringType::class); + Type::hasType(MultiLineStringType::NAME) === true ?: Type::addType(MultiLineStringType::NAME, MultiLineStringType::class); + Type::hasType(PolygonType::NAME) === true ?: Type::addType(PolygonType::NAME, PolygonType::class); + Type::hasType(MultiPolygonType::NAME) === true ?: Type::addType(MultiPolygonType::NAME, MultiPolygonType::class); + Type::hasType(GeometryCollectionType::NAME) === true ?: Type::addType(GeometryCollectionType::NAME, GeometryCollectionType::class); + + // register UUID types + Type::hasType(UuidType::NAME) === true ?: Type::addType(UuidType::NAME, UuidType::class); } /** diff --git a/components/Flute/src/Types/GeometryCollectionType.php b/components/Flute/src/Types/GeometryCollectionType.php new file mode 100644 index 00000000..d0ac9e1f --- /dev/null +++ b/components/Flute/src/Types/GeometryCollectionType.php @@ -0,0 +1,12 @@ + $value) { if (($index = $this->getAttributeIndex($name)) !== null) { - $this->executeBlock($value, $index); + if (array_key_exists(DI::KEYWORD_ID, $data = $jsonData[DI::KEYWORD_DATA]) === true) { + $this->executeBlock($value, $index, (int)$data[DI::KEYWORD_ID]); + } else { + $this->executeBlock($value, $index); + } } elseif ($this->isIgnoreUnknowns() === false) { $title = $this->formatMessage(Messages::INVALID_VALUE); $details = $this->formatMessage(Messages::UNKNOWN_ATTRIBUTE); @@ -633,14 +637,15 @@ private function parseSingleRelationship($data) } /** - * @param mixed $input - * @param int $index + * @param mixed $input + * @param int $index + * @param int|null $primaryKeyValue * * @return void * * @SuppressWarnings(PHPMD.StaticAccess) */ - private function executeBlock($input, int $index): void + private function executeBlock($input, int $index, ?int $primaryKeyValue = null): void { BlockInterpreter::executeBlock( $input, @@ -648,7 +653,8 @@ private function executeBlock($input, int $index): void $this->getBlocks(), $this->getContext(), $this->getCaptureAggregator(), - $this->getErrorAggregator() + $this->getErrorAggregator(), + $primaryKeyValue ); } diff --git a/components/Flute/src/Validation/JsonApi/Rules/AreReadableViaApiRule.php b/components/Flute/src/Validation/JsonApi/Rules/AreReadableViaApiRule.php index 67957c5d..cf01db71 100644 --- a/components/Flute/src/Validation/JsonApi/Rules/AreReadableViaApiRule.php +++ b/components/Flute/src/Validation/JsonApi/Rules/AreReadableViaApiRule.php @@ -58,15 +58,16 @@ public function __construct(string $apiClass) /** * @param mixed $values * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * - * @SuppressWarnings(PHPMD.StaticAccess) - * * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface + * @SuppressWarnings(PHPMD.StaticAccess) + * */ - public static function execute($values, ContextInterface $context): array + public static function execute($values, ContextInterface $context, $primaryKeyValue = null): array { assert(is_array($values)); diff --git a/components/Flute/src/Validation/JsonApi/Rules/ExistInDbTableMultipleWithDoctrineRule.php b/components/Flute/src/Validation/JsonApi/Rules/ExistInDbTableMultipleWithDoctrineRule.php index 9f4b95f4..f75994ab 100644 --- a/components/Flute/src/Validation/JsonApi/Rules/ExistInDbTableMultipleWithDoctrineRule.php +++ b/components/Flute/src/Validation/JsonApi/Rules/ExistInDbTableMultipleWithDoctrineRule.php @@ -58,15 +58,16 @@ public function __construct(string $tableName, string $primaryName) /** * @param mixed $values * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * - * @SuppressWarnings(PHPMD.StaticAccess) - * * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface + * @SuppressWarnings(PHPMD.StaticAccess) + * */ - public static function execute($values, ContextInterface $context): array + public static function execute($values, ContextInterface $context, $primaryKeyValue = null): array { // let's consider an empty index list as `exists` $result = is_array($values); diff --git a/components/Flute/src/Validation/JsonApi/Rules/ExistInDbTableSingleWithDoctrineRule.php b/components/Flute/src/Validation/JsonApi/Rules/ExistInDbTableSingleWithDoctrineRule.php index eacac280..63c82486 100644 --- a/components/Flute/src/Validation/JsonApi/Rules/ExistInDbTableSingleWithDoctrineRule.php +++ b/components/Flute/src/Validation/JsonApi/Rules/ExistInDbTableSingleWithDoctrineRule.php @@ -56,15 +56,16 @@ public function __construct(string $tableName, string $primaryName) /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * - * @SuppressWarnings(PHPMD.StaticAccess) - * * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface + * @SuppressWarnings(PHPMD.StaticAccess) + * */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $count = 0; diff --git a/components/Flute/src/Validation/JsonApi/Rules/IsReadableViaApiRule.php b/components/Flute/src/Validation/JsonApi/Rules/IsReadableViaApiRule.php index 8f323698..68c4672d 100644 --- a/components/Flute/src/Validation/JsonApi/Rules/IsReadableViaApiRule.php +++ b/components/Flute/src/Validation/JsonApi/Rules/IsReadableViaApiRule.php @@ -58,15 +58,16 @@ public function __construct(string $apiClass) /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * - * @SuppressWarnings(PHPMD.StaticAccess) - * * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface + * @SuppressWarnings(PHPMD.StaticAccess) + * */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { assert(is_int($value) || is_string($value)); diff --git a/components/Flute/src/Validation/JsonApi/Rules/IsValidUuidRule.php b/components/Flute/src/Validation/JsonApi/Rules/IsValidUuidRule.php new file mode 100644 index 00000000..7dccc42f --- /dev/null +++ b/components/Flute/src/Validation/JsonApi/Rules/IsValidUuidRule.php @@ -0,0 +1,50 @@ +getContainer()->get(UuidValidatorInterface::class); + + return $uuidValidator->validate($value) === true ? + static::createSuccessReply($value) : + static::createErrorReply( + $context, + $value, + ErrorCodes::INVALID_UUID, + Messages::INVALID_UUID, + [] + ); + } +} diff --git a/components/Flute/src/Validation/JsonApi/Rules/ToManyRelationshipTypeCheckerRule.php b/components/Flute/src/Validation/JsonApi/Rules/ToManyRelationshipTypeCheckerRule.php index 3160fbb5..fa49cc83 100644 --- a/components/Flute/src/Validation/JsonApi/Rules/ToManyRelationshipTypeCheckerRule.php +++ b/components/Flute/src/Validation/JsonApi/Rules/ToManyRelationshipTypeCheckerRule.php @@ -49,13 +49,14 @@ public function __construct(string $type) /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) * @SuppressWarnings(PHPMD.ElseExpression) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { // parser guarantees that input will be an array of [$type => $id] where type and id are scalars diff --git a/components/Flute/src/Validation/JsonApi/Rules/ToOneRelationshipTypeCheckerRule.php b/components/Flute/src/Validation/JsonApi/Rules/ToOneRelationshipTypeCheckerRule.php index bb42850b..445994d7 100644 --- a/components/Flute/src/Validation/JsonApi/Rules/ToOneRelationshipTypeCheckerRule.php +++ b/components/Flute/src/Validation/JsonApi/Rules/ToOneRelationshipTypeCheckerRule.php @@ -52,12 +52,13 @@ public function __construct(string $type) /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { // parser guarantees that input will be either null or an [$type => $id] where type and id are scalars diff --git a/components/Flute/src/Validation/JsonApi/Rules/UniqueInDbTableSingleWithDoctrineRule.php b/components/Flute/src/Validation/JsonApi/Rules/UniqueInDbTableSingleWithDoctrineRule.php index 99ba5c9b..3ed05df1 100644 --- a/components/Flute/src/Validation/JsonApi/Rules/UniqueInDbTableSingleWithDoctrineRule.php +++ b/components/Flute/src/Validation/JsonApi/Rules/UniqueInDbTableSingleWithDoctrineRule.php @@ -43,31 +43,39 @@ final class UniqueInDbTableSingleWithDoctrineRule extends ExecuteRule const PROPERTY_PRIMARY_NAME = self::PROPERTY_TABLE_NAME + 1; /** - * @param string $tableName - * @param string $primaryName + * Property key. */ - public function __construct(string $tableName, string $primaryName) + const PROPERTY_PRIMARY_KEY_NAME = self::PROPERTY_PRIMARY_NAME + 1; + + /** + * @param string $tableName + * @param string $primaryName + * @param string|null $primaryKeyName + */ + public function __construct(string $tableName, string $primaryName, ?string $primaryKeyName = null) { parent::__construct([ - static::PROPERTY_TABLE_NAME => $tableName, - static::PROPERTY_PRIMARY_NAME => $primaryName, + static::PROPERTY_TABLE_NAME => $tableName, + static::PROPERTY_PRIMARY_NAME => $primaryName, + static::PROPERTY_PRIMARY_KEY_NAME => $primaryKeyName, ]); } /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * - * @SuppressWarnings(PHPMD.StaticAccess) - * * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface + * @SuppressWarnings(PHPMD.StaticAccess) + * */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { - $count = 0; + $found = false; if (is_scalar($value) === true) { /** @var Connection $connection */ @@ -75,16 +83,22 @@ public static function execute($value, ContextInterface $context): array $builder = $connection->createQueryBuilder(); $tableName = $context->getProperties()->getProperty(static::PROPERTY_TABLE_NAME); $primaryName = $context->getProperties()->getProperty(static::PROPERTY_PRIMARY_NAME); + $primaryKeyName = $context->getProperties()->getProperty(static::PROPERTY_PRIMARY_KEY_NAME); + $columnsName = $primaryKeyName !== null ? "`{$primaryKeyName}`, `{$primaryName}`" : "`{$primaryName}`"; $statement = $builder - ->select('count(*)') + ->select($columnsName) ->from($tableName) ->where($builder->expr()->eq($primaryName, $builder->createPositionalParameter($value))) - ->execute(); + ->setMaxResults(1); + + $fetched = $statement->execute()->fetch(); - $count = $statement->fetchColumn(); + $found = isset($primaryKeyName) ? + $fetched !== false && (int)$fetched[$primaryKeyName] !== $primaryKeyValue : + $fetched !== false; } - $reply = $count <= 0 ? + $reply = $found === false ? static::createSuccessReply($value) : static::createErrorReply( $context, diff --git a/components/Flute/src/Validation/Rules/DatabaseRulesTrait.php b/components/Flute/src/Validation/Rules/DatabaseRulesTrait.php index 21de1124..abdb5c80 100644 --- a/components/Flute/src/Validation/Rules/DatabaseRulesTrait.php +++ b/components/Flute/src/Validation/Rules/DatabaseRulesTrait.php @@ -60,13 +60,14 @@ public static function existAll(string $tableName, string $primaryName, RuleInte /** * @param string $tableName * @param string $primaryName + * @param string|null $primaryKeyName * @param RuleInterface|null $next * * @return RuleInterface */ - public static function unique(string $tableName, string $primaryName, RuleInterface $next = null): RuleInterface + public static function unique(string $tableName, string $primaryName, ?string $primaryKeyName = null, RuleInterface $next = null): RuleInterface { - $primary = new UniqueInDbTableSingleWithDoctrineRule($tableName, $primaryName); + $primary = new UniqueInDbTableSingleWithDoctrineRule($tableName, $primaryName, $primaryKeyName); return $next === null ? $primary : new AndOperator($primary, $next); } diff --git a/components/Flute/src/Validation/Rules/UuidRulesTrait.php b/components/Flute/src/Validation/Rules/UuidRulesTrait.php new file mode 100644 index 00000000..fffaca74 --- /dev/null +++ b/components/Flute/src/Validation/Rules/UuidRulesTrait.php @@ -0,0 +1,41 @@ + [ + 'limit' => 2, + ], + ]; + $container = $this->createContainer(); + $uri = new Uri('http://localhost.local/boards?' . http_build_query($queryParams)); + /** @var Mock $request */ + $request = Mockery::mock(ServerRequestInterface::class); + $request->shouldReceive('getQueryParams')->once()->withNoArgs()->andReturn($queryParams); + $request->shouldReceive('getUri')->once()->withNoArgs()->andReturn($uri); + + $exception = null; + try { + /** @var ServerRequestInterface $request */ + $response = ApiBoardsController::index($routeParams, $container, $request); + $this->assertNotNull($response); + $this->assertEquals(200, $response->getStatusCode()); + + $body = (string)($response->getBody()); + $resource = json_decode($body, true); + + $this->assertArrayHasKey(DocumentInterface::KEYWORD_META, $resource); + $this->assertArrayHasKey('items', $meta = $resource[DocumentInterface::KEYWORD_META]); + $this->assertArrayHasKey('total', $items = $meta['items']); + $this->assertEquals(5, $items['total']); + + $this->assertArrayHasKey(DocumentInterface::KEYWORD_LINKS, $resource); + $this->assertArrayHasKey(DocumentInterface::KEYWORD_DATA, $resource); + + } catch (JsonApiException $exception) { + } + + $this->assertNull($exception); + } + /** * Controller test. * @@ -749,6 +794,7 @@ public function testUpdate(): void { "data" : { "type" : "comments", + "id" : "$index", "attributes" : { "text-attribute" : "$text" }, diff --git a/components/Flute/tests/Types/UuidTypesTest.php b/components/Flute/tests/Types/UuidTypesTest.php new file mode 100644 index 00000000..cc65fc88 --- /dev/null +++ b/components/Flute/tests/Types/UuidTypesTest.php @@ -0,0 +1,76 @@ +createConnection()->getDatabasePlatform(); + + $uuid = Uuid::getFactory()->uuid4()->toString(); + + /** @var Uuid $phpValue */ + $phpValue = $type->convertToPHPValue($uuid, $platform); + + $this->assertEquals($uuid, $phpValue); + $this->assertEquals($uuid, $phpValue->jsonSerialize()); + } + + /** + * @throws \Doctrine\DBAL\DBALException + */ + public function testUuidTypeToDatabaseConversions(): void + { + $type = Type::getType(UuidType::NAME); + + $platform = $this->createConnection()->getDatabasePlatform(); + + $uuid = Uuid::getFactory()->uuid4()->toString(); + + /** @var string $databaseValue */ + $databaseValue = $type->convertToDatabaseValue($uuid, $platform); + $this->assertEquals($uuid, $databaseValue); + } +} diff --git a/components/L10n/NOTICE b/components/L10n/NOTICE index 789ba134..afbf9734 100644 --- a/components/L10n/NOTICE +++ b/components/L10n/NOTICE @@ -1,3 +1,5 @@ Limoncello localization implementation Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/L10n/composer.json b/components/L10n/composer.json index 261828cb..67c25e9e 100644 --- a/components/L10n/composer.json +++ b/components/L10n/composer.json @@ -1,22 +1,26 @@ { - "name": "limoncello-php/l10n", + "name": "lolltec/limoncello-php-component-l10n", "description": "Limoncello framework localization support.", "keywords": ["limoncello", "framework", "l10n", "localization"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/L10n", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/L10n", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.1.0", "ext-intl": "*", - "limoncello-php/contracts": "^0.10.0" + "lolltec/limoncello-php-component-contracts": "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -41,14 +45,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/L10n/docker-compose.yml b/components/L10n/docker-compose.yml index 203db34d..ffa107e8 100644 --- a/components/L10n/docker-compose.yml +++ b/components/L10n/docker-compose.yml @@ -28,6 +28,14 @@ cli_7_3_php: working_dir: /app tty: true +cli_7_4_php: + build: ./../../docker/7_4_cli + container_name: cli_7_4_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_hhvm: image: hhvm/hhvm container_name: cli_hhvm_limoncello diff --git a/components/L10n/readme.md b/components/L10n/readme.md index b4b13507..b7d4a040 100644 --- a/components/L10n/readme.md +++ b/components/L10n/readme.md @@ -1,11 +1,11 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/l10n/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/l10n/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/l10n/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/l10n/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/l10n.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/l10n) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-l10n/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-l10n/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-l10n/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-l10n/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-l10n.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-l10n) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is localization component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is localization component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). The component helps to translate an application into different languages. In particular, it provides an ability to manage localized files easily and extract localized strings for a given locale with a fallback to default one. @@ -113,7 +113,7 @@ There is another wrapper for `Translator` called `Formatter` which hides locale ``` -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Recommended Usage diff --git a/components/OAuthServer/NOTICE b/components/OAuthServer/NOTICE index e35620d6..b81ca4e5 100644 --- a/components/OAuthServer/NOTICE +++ b/components/OAuthServer/NOTICE @@ -1,3 +1,5 @@ Framework agnostic OAuth 2.0 Server library (PSR-7) Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/OAuthServer/composer.json b/components/OAuthServer/composer.json index 6fc085b5..b3ace612 100644 --- a/components/OAuthServer/composer.json +++ b/components/OAuthServer/composer.json @@ -1,16 +1,20 @@ { - "name": "limoncello-php/oauth-server", + "name": "lolltec/limoncello-php-component-oauth-server", "description": "Framework agnostic OAuth 2.0 Server library (PSR-7).", "keywords": ["PSR-7", "PSR7", "OAuth", "OAuth 2", "OAuth 2.0", "server"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/OAuthServer", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/OAuthServer", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { @@ -41,14 +45,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/OAuthServer/docker-compose.yml b/components/OAuthServer/docker-compose.yml index 203db34d..ffa107e8 100644 --- a/components/OAuthServer/docker-compose.yml +++ b/components/OAuthServer/docker-compose.yml @@ -28,6 +28,14 @@ cli_7_3_php: working_dir: /app tty: true +cli_7_4_php: + build: ./../../docker/7_4_cli + container_name: cli_7_4_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_hhvm: image: hhvm/hhvm container_name: cli_hhvm_limoncello diff --git a/components/OAuthServer/readme.md b/components/OAuthServer/readme.md index 5881187a..4938ab24 100644 --- a/components/OAuthServer/readme.md +++ b/components/OAuthServer/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/oauth-server/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/oauth-server/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/oauth-server/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/oauth-server/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/oauth-server.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/oauth-server) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-oauth-server/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-oauth-server/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-oauth-server/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-oauth-server/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-oauth-server.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-oauth-server) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is OAuth 2.0 Server component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is OAuth 2.0 Server component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Passport/NOTICE b/components/Passport/NOTICE index b4133c2f..7d33c147 100644 --- a/components/Passport/NOTICE +++ b/components/Passport/NOTICE @@ -1,3 +1,5 @@ OAuth 2.0 Server implementation Copyright 2015-2017 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Passport/composer.json b/components/Passport/composer.json index ff27ea0f..b02c084f 100644 --- a/components/Passport/composer.json +++ b/components/Passport/composer.json @@ -1,16 +1,20 @@ { - "name": "limoncello-php/passport", + "name": "lolltec/limoncello-php-component-passport", "description": "Limoncello framework OAuth 2.0 Server implementation.", "keywords": ["limoncello", "framework", "PSR-7", "PSR7", "OAuth", "OAuth 2", "OAuth 2.0"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Passport", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Passport", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { @@ -18,8 +22,8 @@ "psr/log": "^1.0", "doctrine/dbal": "^2.6.3", "zendframework/zend-diactoros": "^2.0", - "limoncello-php/contracts": "^0.10.0", - "limoncello-php/oauth-server": "^0.10.0" + "lolltec/limoncello-php-component-contracts": "dev-master", + "lolltec/limoncello-php-component-oauth-server": "dev-master" }, "require-dev": { "phpunit/phpunit": "^7.0", @@ -29,7 +33,7 @@ "mockery/mockery": "^1.0", "vlucas/phpdotenv": "^2.4", "monolog/monolog": "^1.22", - "limoncello-php/core": "^0.10.0" + "lolltec/limoncello-php-component-core": "dev-master" }, "autoload": { "psr-4": { @@ -47,14 +51,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Passport/docker-compose.yml b/components/Passport/docker-compose.yml index 2a7d0aeb..6257754e 100644 --- a/components/Passport/docker-compose.yml +++ b/components/Passport/docker-compose.yml @@ -68,6 +68,14 @@ services: # working_dir: /app # tty: true # +#cli_7_4_php: +# build: ./../../docker/7_4_cli +# container_name: cli_7_4_php_limoncello +# volumes: +# - .:/app +# working_dir: /app +# tty: true +# #cli_hhvm: # image: hhvm/hhvm # container_name: cli_hhvm_limoncello diff --git a/components/Passport/readme.md b/components/Passport/readme.md index a802edcb..0005655c 100644 --- a/components/Passport/readme.md +++ b/components/Passport/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/passport/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/passport/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/passport/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/passport/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/passport.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/passport) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-passport/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-passport/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-passport/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-passport/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-passport.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-passport) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is OAuth 2.0 Server integration component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is OAuth 2.0 Server integration component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/RedisTaggedCache/NOTICE b/components/RedisTaggedCache/NOTICE index f04dd7bd..1877de2e 100644 --- a/components/RedisTaggedCache/NOTICE +++ b/components/RedisTaggedCache/NOTICE @@ -1,3 +1,5 @@ Redis-based Cache with Tags implementation Copyright 2015-2019 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/RedisTaggedCache/composer.json b/components/RedisTaggedCache/composer.json index 99765e09..952156a8 100644 --- a/components/RedisTaggedCache/composer.json +++ b/components/RedisTaggedCache/composer.json @@ -1,22 +1,26 @@ { - "name": "limoncello-php/redis-tagged-cache", + "name": "lolltec/limoncello-php-component-redis-tagged-cache", "description": "Redis-based Cache with Tags implementation.", "keywords": ["redis", "tagged cache", "cache"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/RedisTaggedCache", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/RedisTaggedCache", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.1.0", "ext-redis": "*", - "limoncello-php/contracts" : "^0.10.0" + "lolltec/limoncello-php-component-contracts" : "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -41,14 +45,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/RedisTaggedCache/docker-compose.yml b/components/RedisTaggedCache/docker-compose.yml index 6f81ec04..29a339e6 100644 --- a/components/RedisTaggedCache/docker-compose.yml +++ b/components/RedisTaggedCache/docker-compose.yml @@ -31,6 +31,14 @@ services: working_dir: /app tty: true +cli_7_4_php: + build: ./../../docker/7_4_cli + container_name: cli_7_4_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_hhvm: image: hhvm/hhvm container_name: cli_hhvm_limoncello diff --git a/components/RedisTaggedCache/readme.md b/components/RedisTaggedCache/readme.md index c34d7e8d..742f4de4 100644 --- a/components/RedisTaggedCache/readme.md +++ b/components/RedisTaggedCache/readme.md @@ -1,11 +1,11 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/redis-tagged-cache/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/redis-tagged-cache/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/redis-tagged-cache/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/redis-tagged-cache/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/redis-tagged-cache.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/redis-tagged-cache) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-redis-tagged-cache/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-redis-tagged-cache/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-redis-tagged-cache/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-redis-tagged-cache/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-redis-tagged-cache.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-redis-tagged-cache) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is component for [Limoncello Framework](https://github.com/limoncello-php/framework) that adds storing extra information (tags) in [Redis](https://redis.io/) cache. +This is component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework) that adds storing extra information (tags) in [Redis](https://redis.io/) cache. Each method works in transactional way. The methods implement @@ -45,7 +45,7 @@ $cache->removeTaggedValue('key1'); $cache->invalidateTag('author:1'); ``` -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Templates/NOTICE b/components/Templates/NOTICE index d7816bc3..d17c9f76 100644 --- a/components/Templates/NOTICE +++ b/components/Templates/NOTICE @@ -1,3 +1,5 @@ Templates implementation. Copyright 2015-2019 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Templates/composer.json b/components/Templates/composer.json index 72418aea..dfea0ad7 100644 --- a/components/Templates/composer.json +++ b/components/Templates/composer.json @@ -1,22 +1,26 @@ { - "name": "limoncello-php/templates", + "name": "lolltec/limoncello-php-component-templates", "description": "Limoncello application templates.", "keywords": ["limoncello", "framework", "templates"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Templates", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Templates", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.1.0", "twig/twig": "^2.3", - "limoncello-php/contracts": "^0.10.0" + "lolltec/limoncello-php-component-contracts": "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -41,14 +45,17 @@ "test-unit-with-coverage": "phpdbg -qrr ./vendor/bin/phpunit --coverage-text", "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests --ignore=./tests/Data/Cache/*", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", + "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Templates/docker-compose.yml b/components/Templates/docker-compose.yml index 203db34d..ffa107e8 100644 --- a/components/Templates/docker-compose.yml +++ b/components/Templates/docker-compose.yml @@ -28,6 +28,14 @@ cli_7_3_php: working_dir: /app tty: true +cli_7_4_php: + build: ./../../docker/7_4_cli + container_name: cli_7_4_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_hhvm: image: hhvm/hhvm container_name: cli_hhvm_limoncello diff --git a/components/Templates/readme.md b/components/Templates/readme.md index 27559014..d9a1f765 100644 --- a/components/Templates/readme.md +++ b/components/Templates/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/templates/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/templates/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/templates/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/templates/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/templates.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/templates) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-templates/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-templates/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-templates/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-templates/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-templates.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-templates) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is HTML templates component for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is HTML templates component for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Testing/NOTICE b/components/Testing/NOTICE index 1443d7d2..003ffb89 100644 --- a/components/Testing/NOTICE +++ b/components/Testing/NOTICE @@ -1,3 +1,5 @@ Testing support. Copyright 2015-2020 info@neomerx.com + +Copyright 2020 info@lolltec.com diff --git a/components/Testing/composer.json b/components/Testing/composer.json index cb82abc2..ad4d52fe 100644 --- a/components/Testing/composer.json +++ b/components/Testing/composer.json @@ -1,22 +1,26 @@ { - "name": "limoncello-php/testing", + "name": "lolltec/limoncello-php-component-testing", "description": "Limoncello framework testing support", "keywords": ["limoncello", "framework", "tests", "testing"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Testing", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Testing", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" - } + }, + { + "name": "lolltec", + "email": "info@lolltec.com" + } ], "require": { "php": ">=7.3.0", - "limoncello-php/contracts": "^0.10.0", - "limoncello-php/core": "^0.10.0" + "lolltec/limoncello-php-component-contracts": "dev-master", + "lolltec/limoncello-php-component-core": "dev-master" }, "require-dev": { "phpunit/phpunit": "^9.0", @@ -42,12 +46,16 @@ "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", + "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", + "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Testing/docker-compose.yml b/components/Testing/docker-compose.yml index 39df802d..14956808 100644 --- a/components/Testing/docker-compose.yml +++ b/components/Testing/docker-compose.yml @@ -4,6 +4,22 @@ # https://docs.docker.com/compose/overview/ # https://docs.docker.com/compose/compose-file/ +cli_7_1_php: + build: ./../../docker/7_1_cli + container_name: cli_7_1_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + +cli_7_2_php: + build: ./../../docker/7_2_cli + container_name: cli_7_2_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_7_3_php: build: ./../../docker/7_3_cli container_name: cli_7_3_php_limoncello diff --git a/components/Testing/readme.md b/components/Testing/readme.md index 3be16eee..598498c0 100644 --- a/components/Testing/readme.md +++ b/components/Testing/readme.md @@ -1,13 +1,13 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/testing/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/testing/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/testing/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/testing/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/testing.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/testing) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-testing/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-testing/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-testing/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-testing/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-testing.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-testing) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Summary -This is a testing support library for [Limoncello Framework](https://github.com/limoncello-php/framework). +This is a testing support library for [Limoncello Framework](https://github.com/lolltec/limoncello-php-framework). -[More info](https://github.com/limoncello-php/framework). +[More info](https://github.com/lolltec/limoncello-php-framework). ## Testing diff --git a/components/Validation/NOTICE b/components/Validation/NOTICE index 3a9d918a..0036db65 100644 --- a/components/Validation/NOTICE +++ b/components/Validation/NOTICE @@ -1,3 +1,5 @@ Validation implementation Copyright 2015-2020 info@neomerx.com + +Copyright 2020 info@neomerx.com diff --git a/components/Validation/composer.json b/components/Validation/composer.json index 03362863..5ac72a5a 100644 --- a/components/Validation/composer.json +++ b/components/Validation/composer.json @@ -1,22 +1,26 @@ { - "name": "limoncello-php/validation", + "name": "lolltec/limoncello-php-component-validation", "description": "Validation framework.", "keywords": ["validation"], - "homepage": "https://github.com/limoncello-php/framework/tree/master/components/Validation", + "homepage": "https://github.com/lolltec/limoncello-php-framework/tree/master/components/Validation", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.3.0", - "limoncello-php/common" : "^0.10.0", - "limoncello-php/contracts" : "^0.10.0" + "lolltec/limoncello-php-component-common" : "dev-master", + "lolltec/limoncello-php-component-contracts" : "dev-master" }, "require-dev": { "squizlabs/php_codesniffer": "^2.9", @@ -43,12 +47,16 @@ "test-cs": "./vendor/bin/phpcs -p -s --standard=PSR2 ./src ./tests", "test-md": "./vendor/bin/phpmd ./src text codesize,controversial,cleancode,design,unusedcode,naming", "test-unit-php-7-4": "docker-compose run --rm cli_7_4_php php ./vendor/bin/phpunit", + "test-unit-php-7-4-win": "docker-compose run --rm cli_7_4_php ./vendor/bin/phpunit", "test-unit-php-7-3": "docker-compose run --rm cli_7_3_php php ./vendor/bin/phpunit", + "test-unit-php-7-3-win": "docker-compose run --rm cli_7_3_php ./vendor/bin/phpunit", + "test-unit-php-7-2": "docker-compose run --rm cli_7_2_php php ./vendor/bin/phpunit", + "test-unit-php-7-2-win": "docker-compose run --rm cli_7_2_php ./vendor/bin/phpunit", + "test-unit-php-7-1": "docker-compose run --rm cli_7_1_php php ./vendor/bin/phpunit", + "test-unit-php-7-1-win": "docker-compose run --rm cli_7_1_php ./vendor/bin/phpunit", "test-unit-hhvm": "docker-compose run --rm cli_hhvm php -d hhvm.php7.all=1 ./vendor/bin/phpunit" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/components/Validation/docker-compose.yml b/components/Validation/docker-compose.yml index 5572137e..bc930864 100644 --- a/components/Validation/docker-compose.yml +++ b/components/Validation/docker-compose.yml @@ -4,6 +4,22 @@ # https://docs.docker.com/compose/overview/ # https://docs.docker.com/compose/compose-file/ +cli_7_1_php: + build: ./../../docker/7_1_cli + container_name: cli_7_1_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + +cli_7_2_php: + build: ./../../docker/7_2_cli + container_name: cli_7_2_php_limoncello + volumes: + - .:/app + working_dir: /app + tty: true + cli_7_3_php: build: ./../../docker/7_3_cli container_name: cli_7_3_php_limoncello diff --git a/components/Validation/readme.md b/components/Validation/readme.md index 5a827ff3..a1360588 100644 --- a/components/Validation/readme.md +++ b/components/Validation/readme.md @@ -1,7 +1,7 @@ -[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/limoncello-php-dist/validation/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/validation/?branch=master) -[![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/validation/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/validation/?branch=master) -[![Build Status](https://travis-ci.org/limoncello-php-dist/validation.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/validation) -[![License](https://img.shields.io/packagist/l/limoncello-php/validation.svg)](https://packagist.org/packages/limoncello-php/validation) +[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-validation/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-validation/?branch=master) +[![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-validation/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-validation/?branch=master) +[![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-validation.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-validation) +[![License](https://img.shields.io/packagist/l/lolltec/limoncello-php-validation.svg)](https://packagist.org/packages/lolltec/limoncello-php-validation) This validation library fast, easy to use yet very powerful and flexible solution. Unlike many other libraries it does not try to give you 'validation rules' for all possible cases because those implementations might not fit your requirements and using such libraries is a pain. Instead it provides an extremely simple way of adding custom validation rules. @@ -109,14 +109,14 @@ When validator is created a developer can pass [PSR Container](http://www.php-fi #### Installation ```bash -$ composer require limoncello-php/validation +$ composer require lolltec/limoncello-php-validation ``` > Note: for message translation PHP-intl is needed. #### Issues -Any related issues please send to [limoncello](https://github.com/limoncello-php/framework). +Any related issues please send to [limoncello](https://github.com/lolltec/limoncello-php-framework). #### Testing diff --git a/components/Validation/sample/Validation/IsDeliveryDateRule.php b/components/Validation/sample/Validation/IsDeliveryDateRule.php index a4212b70..0ebc6c46 100644 --- a/components/Validation/sample/Validation/IsDeliveryDateRule.php +++ b/components/Validation/sample/Validation/IsDeliveryDateRule.php @@ -34,10 +34,11 @@ class IsDeliveryDateRule extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $from = new DateTime('tomorrow'); $to = new DateTime('+5 days'); diff --git a/components/Validation/sample/Validation/IsSkuRule.php b/components/Validation/sample/Validation/IsSkuRule.php index dd7248bb..347e1319 100644 --- a/components/Validation/sample/Validation/IsSkuRule.php +++ b/components/Validation/sample/Validation/IsSkuRule.php @@ -33,10 +33,11 @@ class IsSkuRule extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $idExists = is_int($value) === true && $value < 3; diff --git a/components/Validation/src/Blocks/ProcedureBlock.php b/components/Validation/src/Blocks/ProcedureBlock.php index 1bcd666a..5eb341cb 100644 --- a/components/Validation/src/Blocks/ProcedureBlock.php +++ b/components/Validation/src/Blocks/ProcedureBlock.php @@ -167,7 +167,7 @@ private function setExecuteCallable(callable $executeCallable): self private function checkProcedureExecuteCallableSignature(callable $procedureCallable): bool { /** @noinspection PhpUnhandledExceptionInspection */ - return static::checkPublicStaticCallable($procedureCallable, [null, ContextInterface::class], 'array'); + return static::checkPublicStaticCallable($procedureCallable, [null, ContextInterface::class, null], 'array'); } /** @noinspection PhpDocMissingThrowsInspection diff --git a/components/Validation/src/Contracts/Rules/ExecuteRuleInterface.php b/components/Validation/src/Contracts/Rules/ExecuteRuleInterface.php index 8f2e455a..6cc235d0 100644 --- a/components/Validation/src/Contracts/Rules/ExecuteRuleInterface.php +++ b/components/Validation/src/Contracts/Rules/ExecuteRuleInterface.php @@ -28,8 +28,9 @@ interface ExecuteRuleInterface extends RuleInterface /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array */ - public static function execute($value, ContextInterface $context): array; + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array; } diff --git a/components/Validation/src/Execution/BlockInterpreter.php b/components/Validation/src/Execution/BlockInterpreter.php index 59f72a34..cd10eabd 100644 --- a/components/Validation/src/Execution/BlockInterpreter.php +++ b/components/Validation/src/Execution/BlockInterpreter.php @@ -137,6 +137,7 @@ public static function executeEnds( * @param ContextStorageInterface $context * @param CaptureAggregatorInterface $captures * @param ErrorAggregatorInterface $errors + * @param int|null $primaryKeyValue * * @return bool * @@ -148,14 +149,11 @@ public static function executeBlock( array $blocks, ContextStorageInterface $context, CaptureAggregatorInterface $captures, - ErrorAggregatorInterface $errors + ErrorAggregatorInterface $errors, + ?int $primaryKeyValue = null ): bool { $result = static::executeBlockImpl( - $input, - $blockIndex, - $blocks, - $context, - $captures + $input, $blockIndex, $blocks, $context, $captures, $primaryKeyValue ); if (BlockReplies::isResultSuccessful($result) === false) { $errorsInfo = BlockReplies::extractResultErrorsInfo($result); @@ -173,6 +171,7 @@ public static function executeBlock( * @param array $blocks * @param ContextStorageInterface $context * @param CaptureAggregatorInterface $captures + * @param int|null $primaryKeyValue * * @return array * @@ -183,7 +182,8 @@ private static function executeBlockImpl( int $blockIndex, array $blocks, ContextStorageInterface $context, - CaptureAggregatorInterface $captures + CaptureAggregatorInterface $captures, + ?int $primaryKeyValue = null ): array { assert(array_key_exists($blockIndex, $blocks)); @@ -191,18 +191,18 @@ private static function executeBlockImpl( $context->setCurrentBlockId($blockIndex); switch ($blockType) { case BlockSerializer::TYPE__PROCEDURE: - $result = static::executeProcedureBlock($input, $blockIndex, $blocks, $context, $captures); + $result = static::executeProcedureBlock($input, $blockIndex, $blocks, $context, $captures, $primaryKeyValue); break; case BlockSerializer::TYPE__IF_EXPRESSION: - $result = static::executeIfBlock($input, $blockIndex, $blocks, $context, $captures); + $result = static::executeIfBlock($input, $blockIndex, $blocks, $context, $captures, $primaryKeyValue); break; case BlockSerializer::TYPE__AND_EXPRESSION: - $result = static::executeAndBlock($input, $blockIndex, $blocks, $context, $captures); + $result = static::executeAndBlock($input, $blockIndex, $blocks, $context, $captures, $primaryKeyValue); break; case BlockSerializer::TYPE__OR_EXPRESSION: default: assert($blockType === BlockSerializer::TYPE__OR_EXPRESSION); - $result = static::executeOrBlock($input, $blockIndex, $blocks, $context, $captures); + $result = static::executeOrBlock($input, $blockIndex, $blocks, $context, $captures, $primaryKeyValue); break; } @@ -215,6 +215,7 @@ private static function executeBlockImpl( * @param array $blocks * @param ContextStorageInterface $context * @param CaptureAggregatorInterface $captures + * @param int|null $primaryKeyValue * * @return array * @@ -225,14 +226,15 @@ private static function executeProcedureBlock( int $blockIndex, array $blocks, ContextStorageInterface $context, - CaptureAggregatorInterface $captures + CaptureAggregatorInterface $captures, + ?int $primaryKeyValue = null ): array { $block = $blocks[$blockIndex]; assert(static::getBlockType($block) === BlockSerializer::TYPE__PROCEDURE); $procedure = $block[BlockSerializer::PROCEDURE_EXECUTE_CALLABLE]; assert(is_callable($procedure)); - $result = call_user_func($procedure, $input, $context); + $result = call_user_func($procedure, $input, $context, $primaryKeyValue); static::captureSuccessfulBlockResultIfEnabled($result, $block, $captures); @@ -245,6 +247,7 @@ private static function executeProcedureBlock( * @param array $blocks * @param ContextStorageInterface $context * @param CaptureAggregatorInterface $captures + * @param int|null $primaryKeyValue * * @return array * @@ -255,20 +258,21 @@ private static function executeIfBlock( int $blockIndex, array $blocks, ContextStorageInterface $context, - CaptureAggregatorInterface $captures + CaptureAggregatorInterface $captures, + ?int $primaryKeyValue = null ): array { $block = $blocks[$blockIndex]; assert(static::getBlockType($block) === BlockSerializer::TYPE__IF_EXPRESSION); $conditionCallable = $block[BlockSerializer::IF_EXPRESSION_CONDITION_CALLABLE]; assert(is_callable($conditionCallable)); - $conditionResult = call_user_func($conditionCallable, $input, $context); + $conditionResult = call_user_func($conditionCallable, $input, $context, $primaryKeyValue); assert(is_bool($conditionResult)); $index = $block[$conditionResult === true ? BlockSerializer::IF_EXPRESSION_ON_TRUE_BLOCK : BlockSerializer::IF_EXPRESSION_ON_FALSE_BLOCK]; - $result = static::executeBlockImpl($input, $index, $blocks, $context, $captures); + $result = static::executeBlockImpl($input, $index, $blocks, $context, $captures, $primaryKeyValue); static::captureSuccessfulBlockResultIfEnabled($result, $block, $captures); @@ -281,6 +285,7 @@ private static function executeIfBlock( * @param array $blocks * @param ContextStorageInterface $context * @param CaptureAggregatorInterface $captures + * @param int|null $primaryKeyValue * * @return array * @@ -291,17 +296,18 @@ private static function executeAndBlock( int $blockIndex, array $blocks, ContextStorageInterface $context, - CaptureAggregatorInterface $captures + CaptureAggregatorInterface $captures, + ?int $primaryKeyValue = null ): array { $block = $blocks[$blockIndex]; assert(static::getBlockType($block) === BlockSerializer::TYPE__AND_EXPRESSION); $primaryIndex = $block[BlockSerializer::AND_EXPRESSION_PRIMARY]; - $result = static::executeBlockImpl($input, $primaryIndex, $blocks, $context, $captures); + $result = static::executeBlockImpl($input, $primaryIndex, $blocks, $context, $captures, $primaryKeyValue); if (BlockReplies::isResultSuccessful($result) === true) { $nextInput = BlockReplies::extractResultOutput($result); $secondaryIndex = $block[BlockSerializer::AND_EXPRESSION_SECONDARY]; - $result = static::executeBlockImpl($nextInput, $secondaryIndex, $blocks, $context, $captures); + $result = static::executeBlockImpl($nextInput, $secondaryIndex, $blocks, $context, $captures, $primaryKeyValue); } static::captureSuccessfulBlockResultIfEnabled($result, $block, $captures); @@ -315,6 +321,7 @@ private static function executeAndBlock( * @param array $blocks * @param ContextStorageInterface $context * @param CaptureAggregatorInterface $captures + * @param int|null $primaryKeyValue * * @return array * @@ -326,18 +333,19 @@ private static function executeOrBlock( int $blockIndex, array $blocks, ContextStorageInterface $context, - CaptureAggregatorInterface $captures + CaptureAggregatorInterface $captures, + ?int $primaryKeyValue = null ): array { $block = $blocks[$blockIndex]; assert(static::getBlockType($block) === BlockSerializer::TYPE__OR_EXPRESSION); $primaryIndex = $block[BlockSerializer::OR_EXPRESSION_PRIMARY]; - $resultFromPrimary = static::executeBlockImpl($input, $primaryIndex, $blocks, $context, $captures); + $resultFromPrimary = static::executeBlockImpl($input, $primaryIndex, $blocks, $context, $captures, $primaryKeyValue); if (BlockReplies::isResultSuccessful($resultFromPrimary) === true) { $result = $resultFromPrimary; } else { $secondaryIndex = $block[BlockSerializer::OR_EXPRESSION_SECONDARY]; - $result = static::executeBlockImpl($input, $secondaryIndex, $blocks, $context, $captures); + $result = static::executeBlockImpl($input, $secondaryIndex, $blocks, $context, $captures, $primaryKeyValue); } static::captureSuccessfulBlockResultIfEnabled($result, $block, $captures); diff --git a/components/Validation/src/Rules/Converters/StringArrayToIntArray.php b/components/Validation/src/Rules/Converters/StringArrayToIntArray.php index 0504692b..7be64eac 100644 --- a/components/Validation/src/Rules/Converters/StringArrayToIntArray.php +++ b/components/Validation/src/Rules/Converters/StringArrayToIntArray.php @@ -34,13 +34,14 @@ final class StringArrayToIntArray extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) * @SuppressWarnings(PHPMD.ElseExpression) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $reply = null; diff --git a/components/Validation/src/Rules/Converters/StringToArray.php b/components/Validation/src/Rules/Converters/StringToArray.php index 6235d341..8a59cb75 100644 --- a/components/Validation/src/Rules/Converters/StringToArray.php +++ b/components/Validation/src/Rules/Converters/StringToArray.php @@ -60,13 +60,14 @@ public function __construct(string $delimiter, int $limit = PHP_INT_MAX) /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) * @SuppressWarnings(PHPMD.ElseExpression) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $reply = null; diff --git a/components/Validation/src/Rules/Converters/StringToBool.php b/components/Validation/src/Rules/Converters/StringToBool.php index fdffb481..326a4b29 100644 --- a/components/Validation/src/Rules/Converters/StringToBool.php +++ b/components/Validation/src/Rules/Converters/StringToBool.php @@ -34,6 +34,7 @@ final class StringToBool extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * @@ -41,7 +42,7 @@ final class StringToBool extends ExecuteRule * @SuppressWarnings(PHPMD.ElseExpression) * @SuppressWarnings(PHPMD.CyclomaticComplexity) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { if (is_string($value) === true) { $lcValue = strtolower($value); diff --git a/components/Validation/src/Rules/Converters/StringToDateTime.php b/components/Validation/src/Rules/Converters/StringToDateTime.php index 56c989f0..f6a3c296 100644 --- a/components/Validation/src/Rules/Converters/StringToDateTime.php +++ b/components/Validation/src/Rules/Converters/StringToDateTime.php @@ -52,12 +52,13 @@ public function __construct(string $format) /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $format = $context->getProperties()->getProperty(self::PROPERTY_FORMAT); if (is_string($value) === true && ($parsed = static::parseFromFormat($value, $format)) !== null) { diff --git a/components/Validation/src/Rules/Converters/StringToFloat.php b/components/Validation/src/Rules/Converters/StringToFloat.php index cd7fed37..05f71417 100644 --- a/components/Validation/src/Rules/Converters/StringToFloat.php +++ b/components/Validation/src/Rules/Converters/StringToFloat.php @@ -33,12 +33,13 @@ final class StringToFloat extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { if (is_string($value) === true || is_numeric($value) === true) { return static::createSuccessReply((float)$value); diff --git a/components/Validation/src/Rules/Converters/StringToInt.php b/components/Validation/src/Rules/Converters/StringToInt.php index 0cd089ea..7e5e2dda 100644 --- a/components/Validation/src/Rules/Converters/StringToInt.php +++ b/components/Validation/src/Rules/Converters/StringToInt.php @@ -33,12 +33,13 @@ final class StringToInt extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { if (is_string($value) === true || is_numeric($value) === true) { return static::createSuccessReply((int)$value); diff --git a/components/Validation/src/Rules/Generic/Enum.php b/components/Validation/src/Rules/Generic/Enum.php index 2a919a8e..ced46b16 100644 --- a/components/Validation/src/Rules/Generic/Enum.php +++ b/components/Validation/src/Rules/Generic/Enum.php @@ -50,12 +50,13 @@ public function __construct(array $values) /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $values = $context->getProperties()->getProperty(static::PROPERTY_VALUES); $isOk = in_array($value, $values); diff --git a/components/Validation/src/Rules/Generic/Fail.php b/components/Validation/src/Rules/Generic/Fail.php index 0e60673f..b4060b62 100644 --- a/components/Validation/src/Rules/Generic/Fail.php +++ b/components/Validation/src/Rules/Generic/Fail.php @@ -66,12 +66,13 @@ public function __construct( /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $properties = $context->getProperties(); diff --git a/components/Validation/src/Rules/Generic/Filter.php b/components/Validation/src/Rules/Generic/Filter.php index 32a4c76b..996f259d 100644 --- a/components/Validation/src/Rules/Generic/Filter.php +++ b/components/Validation/src/Rules/Generic/Filter.php @@ -74,12 +74,13 @@ public function __construct( /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $properties = $context->getProperties(); $filterId = $properties->getProperty(static::PROPERTY_FILTER_ID); diff --git a/components/Validation/src/Rules/Generic/Success.php b/components/Validation/src/Rules/Generic/Success.php index 59319a79..5da140e0 100644 --- a/components/Validation/src/Rules/Generic/Success.php +++ b/components/Validation/src/Rules/Generic/Success.php @@ -30,12 +30,13 @@ final class Success extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { assert($context); diff --git a/components/Validation/src/Rules/Generic/Value.php b/components/Validation/src/Rules/Generic/Value.php index c61247c5..51b91cf0 100644 --- a/components/Validation/src/Rules/Generic/Value.php +++ b/components/Validation/src/Rules/Generic/Value.php @@ -44,12 +44,13 @@ public function __construct($value) /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { $value = $context->getProperties()->getProperty(static::PROPERTY_VALUE); diff --git a/components/Validation/src/Rules/Types/IsArray.php b/components/Validation/src/Rules/Types/IsArray.php index 929b56da..18846ae9 100644 --- a/components/Validation/src/Rules/Types/IsArray.php +++ b/components/Validation/src/Rules/Types/IsArray.php @@ -32,12 +32,13 @@ final class IsArray extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { return is_array($value) === true ? static::createSuccessReply($value) : diff --git a/components/Validation/src/Rules/Types/IsBool.php b/components/Validation/src/Rules/Types/IsBool.php index 486b4b75..d65edb1c 100644 --- a/components/Validation/src/Rules/Types/IsBool.php +++ b/components/Validation/src/Rules/Types/IsBool.php @@ -32,12 +32,13 @@ final class IsBool extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { return is_bool($value) === true ? static::createSuccessReply($value) : diff --git a/components/Validation/src/Rules/Types/IsDateTime.php b/components/Validation/src/Rules/Types/IsDateTime.php index d70968df..5acf3977 100644 --- a/components/Validation/src/Rules/Types/IsDateTime.php +++ b/components/Validation/src/Rules/Types/IsDateTime.php @@ -32,12 +32,13 @@ final class IsDateTime extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { return $value instanceof DateTimeInterface ? static::createSuccessReply($value) : diff --git a/components/Validation/src/Rules/Types/IsFloat.php b/components/Validation/src/Rules/Types/IsFloat.php index 0e3db7a1..bb3d457b 100644 --- a/components/Validation/src/Rules/Types/IsFloat.php +++ b/components/Validation/src/Rules/Types/IsFloat.php @@ -32,12 +32,13 @@ final class IsFloat extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { return is_float($value) === true ? static::createSuccessReply($value) : diff --git a/components/Validation/src/Rules/Types/IsInt.php b/components/Validation/src/Rules/Types/IsInt.php index 090a2ba0..5c271fcc 100644 --- a/components/Validation/src/Rules/Types/IsInt.php +++ b/components/Validation/src/Rules/Types/IsInt.php @@ -32,12 +32,13 @@ final class IsInt extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { return is_int($value) === true ? static::createSuccessReply($value) : diff --git a/components/Validation/src/Rules/Types/IsNumeric.php b/components/Validation/src/Rules/Types/IsNumeric.php index d594a29e..7e2bfaf6 100644 --- a/components/Validation/src/Rules/Types/IsNumeric.php +++ b/components/Validation/src/Rules/Types/IsNumeric.php @@ -32,12 +32,13 @@ final class IsNumeric extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { return is_numeric($value) === true ? static::createSuccessReply($value) : diff --git a/components/Validation/src/Rules/Types/IsString.php b/components/Validation/src/Rules/Types/IsString.php index 149ba9c2..dc03af7d 100644 --- a/components/Validation/src/Rules/Types/IsString.php +++ b/components/Validation/src/Rules/Types/IsString.php @@ -32,12 +32,13 @@ final class IsString extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * * @SuppressWarnings(PHPMD.StaticAccess) */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { return is_string($value) === true ? static::createSuccessReply($value) : diff --git a/components/Validation/tests/Rules/DbRule.php b/components/Validation/tests/Rules/DbRule.php index 87df9621..ff73f452 100644 --- a/components/Validation/tests/Rules/DbRule.php +++ b/components/Validation/tests/Rules/DbRule.php @@ -33,12 +33,13 @@ class DbRule extends ExecuteRule /** * @param mixed $value * @param ContextInterface $context + * @param null $primaryKeyValue * * @return array * @throws ContainerExceptionInterface * @throws NotFoundExceptionInterface */ - public static function execute($value, ContextInterface $context): array + public static function execute($value, ContextInterface $context, $primaryKeyValue = null): array { // it emulates it takes connection from context's container and work with database. $pdo = $context->getContainer()->get(PDO::class); diff --git a/composer.json b/composer.json index a5e09cbb..3cf88b04 100644 --- a/composer.json +++ b/composer.json @@ -1,37 +1,41 @@ { - "name": "limoncello-php/framework", + "name": "lolltec/limoncello-php-framework", "description": "PHP framework framework (PSR-7)", "keywords": ["framework", "PSR-7", "PSR7", "limoncello"], - "homepage": "https://github.com/limoncello-php/framework", + "homepage": "https://github.com/lolltec/limoncello-php-framework", "support": { - "issues": "https://github.com/limoncello-php/framework/issues" + "issues": "https://github.com/lolltec/limoncello-php-framework/issues" }, "license": "Apache-2.0", "authors": [ { "name": "neomerx", "email": "info@neomerx.com" + }, + { + "name": "lolltec", + "email": "info@lolltec.com" } ], "require": { "php": ">=7.1.0", - "limoncello-php/application": "self.version", - "limoncello-php/auth": "self.version", - "limoncello-php/commands": "self.version", - "limoncello-php/common": "self.version", - "limoncello-php/container": "self.version", - "limoncello-php/contracts": "self.version", - "limoncello-php/core": "self.version", - "limoncello-php/crypt": "self.version", - "limoncello-php/data": "self.version", - "limoncello-php/events": "self.version", - "limoncello-php/flute": "self.version", - "limoncello-php/l10n": "self.version", - "limoncello-php/oauth-server": "self.version", - "limoncello-php/passport": "self.version", + "lolltec/limoncello-php-component-application": "self.version", + "lolltec/limoncello-php-component-auth": "self.version", + "lolltec/limoncello-php-component-commands": "self.version", + "lolltec/limoncello-php-component-common": "self.version", + "lolltec/limoncello-php-component-container": "self.version", + "lolltec/limoncello-php-component-contracts": "self.version", + "lolltec/limoncello-php-component-core": "self.version", + "lolltec/limoncello-php-component-crypt": "self.version", + "lolltec/limoncello-php-component-data": "self.version", + "lolltec/limoncello-php-component-events": "self.version", + "lolltec/limoncello-php-component-flute": "self.version", + "lolltec/limoncello-php-component-l10n": "self.version", + "lolltec/limoncello-php-component-oauth-server": "self.version", + "lolltec/limoncello-php-component-passport": "self.version", - "limoncello-php/templates": "self.version", - "limoncello-php/validation": "self.version" + "lolltec/limoncello-php-component-templates": "self.version", + "lolltec/limoncello-php-component-validation": "self.version" }, "scripts": { "test": ["@clean-vendor-folders", "@test-unit-with-coverage", "@test-cs", "@test-md"], @@ -226,9 +230,7 @@ "test-md-component-Testing": "@composer test-md --working-dir=./components/Testing/", "test-md-component-Validation": "@composer test-md --working-dir=./components/Validation/" }, - "extra": { - "branch-alias": { - "dev-develop": "0.10.x-dev" - } - } + "extra": {}, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/readme.md b/readme.md index e336b385..9ee64034 100644 --- a/readme.md +++ b/readme.md @@ -1,5 +1,5 @@ -[![Project Management](https://img.shields.io/badge/project-management-blue.svg)](https://waffle.io/limoncello-php/framework) -[![License](https://img.shields.io/github/license/limoncello-php/framework.svg)](https://packagist.org/packages/limoncello-php/framework) +[![Project Management](https://img.shields.io/badge/project-management-blue.svg)](https://waffle.io/lolltec/limoncello-php-framework) +[![License](https://img.shields.io/github/license/lolltec/limoncello-php-framework.svg)](https://packagist.org/packages/lolltec/limoncello-php-framework) ## Testing @@ -22,19 +22,19 @@ Requirements | Component | Build Status | Test Coverage | | -------------------|:-------------:| :-------------:| -| Application | [![Build Status](https://travis-ci.org/limoncello-php-dist/application.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/application) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/application/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/application/?branch=master) | -| Auth | [![Build Status](https://travis-ci.org/limoncello-php-dist/auth.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/auth) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/auth/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/auth/?branch=master) | -| Commands | [![Build Status](https://travis-ci.org/limoncello-php-dist/commands.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/commands) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/commands/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/commands/?branch=master) | -| Container | [![Build Status](https://travis-ci.org/limoncello-php-dist/container.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/container) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/container/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/container/?branch=master) | -| Core | [![Build Status](https://travis-ci.org/limoncello-php-dist/core.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/core) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/core/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/core/?branch=master) | -| Crypt | [![Build Status](https://travis-ci.org/limoncello-php-dist/crypt.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/crypt) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/crypt/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/crypt/?branch=master) | -| Data | [![Build Status](https://travis-ci.org/limoncello-php-dist/data.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/data) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/data/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/data/?branch=master) | -| Events | [![Build Status](https://travis-ci.org/limoncello-php-dist/events.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/events) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/events/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/events/?branch=master) | -| Flute | [![Build Status](https://travis-ci.org/limoncello-php-dist/flute.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/flute) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/flute/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/flute/?branch=master) | -| L10n | [![Build Status](https://travis-ci.org/limoncello-php-dist/l10n.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/l10n) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/l10n/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/l10n/?branch=master) | -| OAuthServer | [![Build Status](https://travis-ci.org/limoncello-php-dist/oauth-server.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/oauth-server) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/oauth-server/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/oauth-server/?branch=master) | -| Passport | [![Build Status](https://travis-ci.org/limoncello-php-dist/passport.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/passport) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/passport/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/passport/?branch=master) | -| Redis Tagged Cache | [![Build Status](https://travis-ci.org/limoncello-php-dist/redis-tagged-cache.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/redis-tagged-cache) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/redis-tagged-cache/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/redis-tagged-cache/?branch=master) | -| Templates | [![Build Status](https://travis-ci.org/limoncello-php-dist/templates.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/templates) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/templates/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/templates/?branch=master) | -| Testing | [![Build Status](https://travis-ci.org/limoncello-php-dist/testing.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/testing) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/testing/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/testing/?branch=master) | -| Validation | [![Build Status](https://travis-ci.org/limoncello-php-dist/validation.svg?branch=master)](https://travis-ci.org/limoncello-php-dist/validation) | [![Code Coverage](https://scrutinizer-ci.com/g/limoncello-php-dist/validation/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/limoncello-php-dist/validation/?branch=master) | +| Application | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-application.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-application) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-application/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-application/?branch=master) | +| Auth | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-auth.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-auth) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-auth/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-auth/?branch=master) | +| Commands | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-commands.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-commands) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-commands/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-commands/?branch=master) | +| Container | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-container.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-container) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-container/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-container/?branch=master) | +| Core | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-core.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-core) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-core/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-core/?branch=master) | +| Crypt | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-crypt.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-crypt) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-crypt/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-crypt/?branch=master) | +| Data | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-data.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-data) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-data/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-data/?branch=master) | +| Events | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-events.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-events) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-events/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-events/?branch=master) | +| Flute | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-flute.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-flute) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-flute/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-flute/?branch=master) | +| L10n | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-l10n.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-l10n) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-l10n/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-l10n/?branch=master) | +| OAuthServer | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-oauth-server.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-oauth-server) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-oauth-server/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-oauth-server/?branch=master) | +| Passport | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-passport.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-passport) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-passport/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-passport/?branch=master) | +| Redis Tagged Cache | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-redis-tagged-cache.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-redis-tagged-cache) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-redis-tagged-cache/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-redis-tagged-cache/?branch=master) | +| Templates | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-templates.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-templates) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-templates/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-templates/?branch=master) | +| Testing | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-testing.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-testing) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-testing/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-testing/?branch=master) | +| Validation | [![Build Status](https://travis-ci.org/lolltec/limoncello-php-component-validation.svg?branch=master)](https://travis-ci.org/lolltec/limoncello-php-component-validation) | [![Code Coverage](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-validation/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/lolltec/limoncello-php-component-validation/?branch=master) | diff --git a/split/components.sh b/split/components.sh index e42ad703..5389311a 100644 --- a/split/components.sh +++ b/split/components.sh @@ -1,24 +1,24 @@ #!/usr/bin/env bash -BRANCHES='master develop' +BRANCHES='master upstream develop' COMPONENTS=( - 'components/Application/:git@github.com:limoncello-php-dist/application.git' - 'components/Auth/:git@github.com:limoncello-php-dist/auth.git' - 'components/Commands/:git@github.com:limoncello-php-dist/commands.git' - 'components/Common/:git@github.com:limoncello-php-dist/common.git' - 'components/Container/:git@github.com:limoncello-php-dist/container.git' - 'components/Contracts/:git@github.com:limoncello-php-dist/contracts.git' - 'components/Core/:git@github.com:limoncello-php-dist/core.git' - 'components/Crypt/:git@github.com:limoncello-php-dist/crypt.git' - 'components/Data/:git@github.com:limoncello-php-dist/data.git' - 'components/Events/:git@github.com:limoncello-php-dist/events.git' - 'components/Flute/:git@github.com:limoncello-php-dist/flute.git' - 'components/L10n/:git@github.com:limoncello-php-dist/l10n.git' - 'components/OAuthServer/:git@github.com:limoncello-php-dist/oauth-server.git' - 'components/Passport/:git@github.com:limoncello-php-dist/passport.git' - 'components/RedisTaggedCache/:git@github.com:limoncello-php-dist/redis-tagged-cache.git' - 'components/Templates/:git@github.com:limoncello-php-dist/templates.git' - 'components/Testing/:git@github.com:limoncello-php-dist/testing.git' - 'components/Validation/:git@github.com:limoncello-php-dist/validation.git' + 'components/Application/:git@github.com:lolltec/limoncello-php-component-application.git' + 'components/Auth/:git@github.com:lolltec/limoncello-php-component-auth.git' + 'components/Commands/:git@github.com:lolltec/limoncello-php-component-commands.git' + 'components/Common/:git@github.com:lolltec/limoncello-php-component-common.git' + 'components/Container/:git@github.com:lolltec/limoncello-php-component-container.git' + 'components/Contracts/:git@github.com:lolltec/limoncello-php-component-contracts.git' + 'components/Core/:git@github.com:lolltec/limoncello-php-component-core.git' + 'components/Crypt/:git@github.com:lolltec/limoncello-php-component-crypt.git' + 'components/Data/:git@github.com:lolltec/limoncello-php-component-data.git' + 'components/Events/:git@github.com:lolltec/limoncello-php-component-events.git' + 'components/Flute/:git@github.com:lolltec/limoncello-php-component-flute.git' + 'components/L10n/:git@github.com:lolltec/limoncello-php-component-l10n.git' + 'components/OAuthServer/:git@github.com:lolltec/limoncello-php-component-oauth-server.git' + 'components/Passport/:git@github.com:lolltec/limoncello-php-component-passport.git' + 'components/RedisTaggedCache/:git@github.com:lolltec/limoncello-php-component-redis-tagged-cache.git' + 'components/Templates/:git@github.com:lolltec/limoncello-php-component-templates.git' + 'components/Testing/:git@github.com:lolltec/limoncello-php-component-testing.git' + 'components/Validation/:git@github.com:lolltec/limoncello-php-component-validation.git' ) diff --git a/split/split-no-tags.sh b/split/split-no-tags.sh index 0c3c87b6..2613c345 100755 --- a/split/split-no-tags.sh +++ b/split/split-no-tags.sh @@ -6,7 +6,7 @@ THREAD_ID=0 source "${CURRENT_DIR}/components.sh" -rm -rf .subsplit/ && git subsplit init git@github.com:limoncello-php/framework.git +rm -rf .subsplit/ && git subsplit init git@github.com:lolltec/limoncello-php-framework.git for component in "${COMPONENTS[@]}" do diff --git a/split/split-with-tags.sh b/split/split-with-tags.sh index fabc15dd..5f16cfe3 100755 --- a/split/split-with-tags.sh +++ b/split/split-with-tags.sh @@ -6,7 +6,7 @@ THREAD_ID=0 source "${CURRENT_DIR}/components.sh" -rm -rf .subsplit/ && git subsplit init git@github.com:limoncello-php/framework.git +rm -rf .subsplit/ && git subsplit init git@github.com:lolltec/limoncello-php-framework.git for component in "${COMPONENTS[@]}" do