Skip to content

Commit

Permalink
reefactor: change monorepo rule
Browse files Browse the repository at this point in the history
  • Loading branch information
SonyPradana committed Jul 5, 2024
1 parent de42504 commit 6987dbf
Show file tree
Hide file tree
Showing 18 changed files with 79 additions and 76 deletions.
52 changes: 28 additions & 24 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
{
"name": "sonypradana/php-library",
"description": "library to build php mvc",
"keywords": ["framework", "php-mvc", "php-library"],
"keywords": [
"framework",
"php-mvc",
"php-library"
],
"license": "MIT",
"authors": [
{
Expand Down Expand Up @@ -29,11 +33,11 @@
"System\\Support\\": "src/System/Macroable"
},
"files": [
"src/System/Collection/helper.php",
"src/System/Integrate/helper.php",
"src/System/Console/helper.php",
"src/System/Text/helper.php",
"src/System/Time/helper.php"
"src/System/Collection/helper.php",
"src/System/Integrate/helper.php",
"src/System/Console/helper.php",
"src/System/Text/helper.php",
"src/System/Time/helper.php"
]
},
"autoload-dev": {
Expand All @@ -45,29 +49,27 @@
]
},
"replace": {
"savanna-php/collection": "self.version",
"savanna-php/console": "self.version",
"savanna-php/container": "self.version",
"savanna-php/cron": "self.version",
"savanna-php/database": "self.version",
"savanna-php/file": "self.version",
"savanna-php/http": "self.version",
"savanna-php/integrate": "self.version",
"savanna-php/router": "self.version",
"savanna-php/security": "self.version",
"savanna-php/support": "self.version",
"savanna-php/template": "self.version",
"savanna-php/text": "self.version",
"savanna-php/time": "self.version",
"savanna-php/view": "self.version"
"sonypradana/collection": "0.35.0",
"sonypradana/console": "0.35.0",
"sonypradana/container": "0.35.0",
"sonypradana/cron": "0.35.0",
"sonypradana/database": "0.35.0",
"sonypradana/file": "0.35.0",
"sonypradana/http": "0.35.0",
"sonypradana/integrate": "0.35.0",
"sonypradana/router": "0.35.0",
"sonypradana/security": "0.35.0",
"sonypradana/support": "0.35.0",
"sonypradana/template": "0.35.0",
"sonypradana/text": "0.35.0",
"sonypradana/time": "0.35.0",
"sonypradana/view": "0.35.0"
},
"extra": {
"branch-alias": {
"dev-master": "0.x-dev"
}
},
"minimum-stability": "dev",
"prefer-stable": true,
"scripts": {
"refacto": "rector",
"lint": "php-cs-fixer fix -v",
Expand All @@ -87,5 +89,7 @@
"phpstan analyse --ansi --memory-limit=-1",
"phpunit --exclude-group database"
]
}
},
"minimum-stability": "dev",
"prefer-stable": true
}
13 changes: 5 additions & 8 deletions monorepo-builder.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,23 @@
declare(strict_types=1);

use Symplify\MonorepoBuilder\Config\MBConfig;
use Symplify\MonorepoBuilder\Release\ReleaseWorker\AddTagToChangelogReleaseWorker;
use Symplify\MonorepoBuilder\Release\ReleaseWorker\PushNextDevReleaseWorker;
use Symplify\MonorepoBuilder\Release\ReleaseWorker\PushTagReleaseWorker;
use Symplify\MonorepoBuilder\Release\ReleaseWorker\SetCurrentMutualDependenciesReleaseWorker;
use Symplify\MonorepoBuilder\Release\ReleaseWorker\SetNextMutualDependenciesReleaseWorker;
use Symplify\MonorepoBuilder\Release\ReleaseWorker\TagVersionReleaseWorker;
use Symplify\MonorepoBuilder\Release\ReleaseWorker\UpdateBranchAliasReleaseWorker;
use Symplify\MonorepoBuilder\Release\ReleaseWorker\UpdateReplaceReleaseWorker;

return static function (MBConfig $config): void {
$config->packageDirectories([__DIR__ . '/src/System']);
$config->disableDefaultWorkers();

$config->workers([
// update root composer json
UpdateReplaceReleaseWorker::class,
// update child composer json
SetCurrentMutualDependenciesReleaseWorker::class,
AddTagToChangelogReleaseWorker::class,
// local tag
TagVersionReleaseWorker::class,
// push tag
PushTagReleaseWorker::class,
// SetNextMutualDependenciesReleaseWorker::class,
// UpdateBranchAliasReleaseWorker::class,
// PushNextDevReleaseWorker::class,
]);
};
2 changes: 1 addition & 1 deletion src/System/Collection/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/collection",
"name": "sonypradana/collection",
"description": "part of php-library, manage array using collection",
"authors": [
{
Expand Down
4 changes: 2 additions & 2 deletions src/System/Console/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/console",
"name": "sonypradana/console",
"description": "part of php-library, console",
"authors": [
{
Expand All @@ -10,7 +10,7 @@
"require": {
"php": "^8.0",
"sonypradana/validator": "^0.8",
"savanna-php/text": "^0.31"
"sonypradana/text": "^0.35"
},
"autoload": {
"psr-4": {
Expand Down
2 changes: 1 addition & 1 deletion src/System/Container/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/container",
"name": "sonypradana/container",
"description": "part of php-library, dependency injection container",
"authors": [
{
Expand Down
2 changes: 1 addition & 1 deletion src/System/Cron/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/cron",
"name": "sonypradana/cron",
"description": "part of php-library, dependency injection container",
"authors": [
{
Expand Down
4 changes: 2 additions & 2 deletions src/System/Database/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/database",
"name": "sonypradana/database",
"description": "part of php-library, dependency injection container",
"authors": [
{
Expand All @@ -9,7 +9,7 @@
],
"require": {
"php": "^8.0",
"savanna-php/collection": "^0.31"
"sonypradana/collection": "^0.35"
},
"autoload": {
"psr-4": {
Expand Down
2 changes: 1 addition & 1 deletion src/System/File/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/file",
"name": "sonypradana/file",
"description": "part of php-library, file",
"authors": [
{
Expand Down
8 changes: 4 additions & 4 deletions src/System/Http/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/http",
"name": "sonypradana/http",
"description": "part of php-library, http",
"authors": [
{
Expand All @@ -10,9 +10,9 @@
"require": {
"php": "^8.0",
"sonypradana/validator": "^0.8",
"savanna-php/collection": "^0.31",
"savanna-php/macroable": "^0.31",
"savanna-php/text": "^0.31"
"sonypradana/collection": "^0.35",
"sonypradana/macroable": "^0.35",
"sonypradana/text": "^0.35"
},
"autoload": {
"psr-4": {
Expand Down
30 changes: 16 additions & 14 deletions src/System/Integrate/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/integrate",
"name": "sonypradana/integrate",
"description": "part of php-library, http",
"authors": [
{
Expand All @@ -9,20 +9,22 @@
],
"require": {
"php": "^8.0",
"php-di/php-di": "^6.4 || ^7.0",
"php-di/php-di": "^7.0",
"sonypradana/validator": "^0.8",
"savanna-php/collection": "^0.31",
"savanna-php/console": "^0.31",
"savanna-php/container": "^0.31",
"savanna-php/cron": "^0.31",
"savanna-php/database": "^0.31",
"savanna-php/file": "^0.31",
"savanna-php/http": "^0.31",
"savanna-php/router": "^0.31",
"savanna-php/support": "^0.31",
"savanna-php/template": "^0.31",
"savanna-php/text": "^0.31",
"savanna-php/time": "^0.31"
"sonypradana/collection": "^0.35",
"sonypradana/console": "^0.35",
"sonypradana/container": "^0.35",
"sonypradana/cron": "^0.35",
"sonypradana/database": "^0.35",
"sonypradana/file": "^0.35",
"sonypradana/http": "^0.35",
"sonypradana/router": "^0.35",
"sonypradana/security": "^0.35",
"sonypradana/support": "^0.35",
"sonypradana/template": "^0.35",
"sonypradana/text": "^0.35",
"sonypradana/time": "^0.35",
"sonypradana/view": "^0.35"
},
"autoload": {
"psr-4": {
Expand Down
2 changes: 1 addition & 1 deletion src/System/Macroable/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/macroable",
"name": "sonypradana/macroable",
"description": "part of php-library, macroable",
"authors": [
{
Expand Down
8 changes: 4 additions & 4 deletions src/System/Router/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/router",
"name": "sonypradana/router",
"description": "part of php-library, route",
"authors": [
{
Expand All @@ -9,9 +9,9 @@
],
"require": {
"php": "^8.0",
"savanna-php/collection": "^0.31",
"savanna-php/http": "^0.31",
"savanna-php/text": "^0.31"
"sonypradana/collection": "^0.35",
"sonypradana/http": "^0.35",
"sonypradana/text": "^0.35"
},
"autoload": {
"psr-4": {
Expand Down
2 changes: 1 addition & 1 deletion src/System/Security/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/security",
"name": "sonypradana/security",
"description": "part of php-library, security",
"authors": [
{
Expand Down
6 changes: 3 additions & 3 deletions src/System/Support/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/support",
"name": "sonypradana/support",
"description": "part of php-library, support",
"authors": [
{
Expand All @@ -9,8 +9,8 @@
],
"require": {
"php": "^8.0",
"savanna-php/integrate": "^0.31",
"savanna-php/macroable": "^0.31"
"sonypradana/integrate": "^0.35",
"sonypradana/macroable": "^0.35"
},
"autoload": {
"psr-4": {
Expand Down
2 changes: 1 addition & 1 deletion src/System/Template/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/template",
"name": "sonypradana/template",
"description": "part of php-library, template",
"authors": [
{
Expand Down
4 changes: 2 additions & 2 deletions src/System/Text/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/text",
"name": "sonypradana/text",
"description": "part of php-library, text",
"authors": [
{
Expand All @@ -10,7 +10,7 @@
"require": {
"php": "^8.0",
"ext-mbstring": "*",
"savanna-php/macroable": "^0.31"
"sonypradana/macroable": "^0.35"
},
"autoload": {
"psr-4": {
Expand Down
8 changes: 4 additions & 4 deletions src/System/Time/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/time",
"name": "sonypradana/time",
"description": "part of php-library, time",
"authors": [
{
Expand All @@ -9,9 +9,9 @@
],
"require": {
"php": "^8.0",
"savanna-php/collection": "^0.31",
"savanna-php/support": "^0.31",
"savanna-php/text": "^0.31"
"sonypradana/collection": "^0.35",
"sonypradana/support": "^0.35",
"sonypradana/text": "^0.35"
},
"autoload": {
"psr-4": {
Expand Down
4 changes: 2 additions & 2 deletions src/System/View/composer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "savanna-php/view",
"name": "sonypradana/view",
"description": "part of php-library, view",
"authors": [
{
Expand All @@ -9,7 +9,7 @@
],
"require": {
"php": "^8.0",
"savanna-php/http": "^0.31"
"sonypradana/http": "^0.35"
},
"autoload": {
"psr-4": {
Expand Down

0 comments on commit 6987dbf

Please sign in to comment.