diff --git a/README.md b/README.md index 6965aa7..72cd171 100644 --- a/README.md +++ b/README.md @@ -22,9 +22,9 @@ different address or port when needed: php infbyte serve --host=0.0.0.0 --port=8080 ``` -The built-in server is intended for local development only. Composer creates -`.env` from `.env.example` and generates a unique authentication secret without -overwriting an existing environment file. +The built-in server is intended for local development only. Composer invokes +Foundation's `app:install` command to create `.env` from `.env.example` and +generate a unique authentication secret without replacing an existing one. The starter application exposes: @@ -42,7 +42,7 @@ include: | Local development | `serve`, `create:*` | | Optional capabilities | `module:list`, `module:install`, `module:remove` | | Database work | `db:show`, `db:table`, `db:seed`, `migrate*` | -| Runtime maintenance | `cache:clear`, `storage:link`, `secret:generate` | +| Runtime maintenance | `app:install`, `cache:clear`, `storage:link`, `secret:generate` | | Background work | `schedule:*`, `worker:*`, `queue:consume` | | Deployment | `optimize`, `optimize:clear`, `app:ready` | diff --git a/bootstrap/install.php b/bootstrap/install.php deleted file mode 100644 index 6c6fbee..0000000 --- a/bootstrap/install.php +++ /dev/null @@ -1,77 +0,0 @@ -=8.4", - "infocyph/foundation": "^1.2" + "infocyph/foundation": "^1.2.1" }, "require-dev": { "infocyph/phpforge": "dev-main@dev" @@ -30,6 +30,6 @@ "sort-packages": true }, "scripts": { - "post-create-project-cmd": "@php bootstrap/install.php" + "post-create-project-cmd": "@php infbyte app:install" } } diff --git a/tests/Feature/SkeletonDistributionTest.php b/tests/Feature/SkeletonDistributionTest.php index b75bb46..754c7d7 100644 --- a/tests/Feature/SkeletonDistributionTest.php +++ b/tests/Feature/SkeletonDistributionTest.php @@ -78,7 +78,7 @@ } expect($project . '/composer.json')->toBeFile() - ->and($project . '/bootstrap/install.php')->toBeFile() + ->and($project . '/bootstrap/install.php')->not->toBeFile() ->and($project . '/bootstrap/cache/config/.gitignore')->toBeFile() ->and($project . '/bootstrap/cache/console/.gitignore')->toBeFile() ->and($project . '/bootstrap/cache/routes/.gitignore')->toBeFile() @@ -108,7 +108,13 @@ ->and($exportedComposer['require']['infocyph/foundation'] ?? null) ->toBe($sourceComposer['require']['infocyph/foundation'] ?? null) ->and($exportedComposer['scripts']['post-create-project-cmd'] ?? null) - ->toBe('@php bootstrap/install.php'); + ->toBe('@php infbyte app:install'); + + mkdir($project . '/vendor', 0775, true); + file_put_contents( + $project . '/vendor/autoload.php', + '