@@ -511,8 +511,10 @@ public function __invoke(): void
511511
512512 // Step - Copy .env.example to .env & set BASE_URI
513513 $ this ->console ->info ('➡️ Starting customizing .env... ' );
514- $ envexamplePath = root_path () . '/.env.example ' ;
514+ $ envexamplePath = root_path () . '/vendor/happytodev/cyclone/.env.example ' ;
515+
515516 $ envPath = root_path () . '/.env ' ;
517+
516518 if (file_exists ($ envexamplePath )) {
517519 if (!copy ($ envexamplePath , $ envPath )) {
518520 $ this ->console ->error ("❌ Error copying .env.example to .env " );
@@ -527,7 +529,7 @@ public function __invoke(): void
527529 // Find BASE_URI=localhost and replace 'localhost' with the current URL
528530 $ currentUrl = $ this ->console ->ask ('What will be the current URL of your site? (e.g., https://cyclone.test) ' , default: 'https://cyclone.test ' );
529531 $ currentUrl = rtrim ($ currentUrl , '/ ' ); // Remove trailing slash
530- $ envContent = file_get_contents ($ envPath );
532+ $ envContent = file_get_contents ($ envexamplePath );
531533 if ($ envContent === false ) {
532534 $ this ->console ->error ("❌ Error reading .env file " );
533535 exit (1 );
@@ -541,7 +543,6 @@ public function __invoke(): void
541543 $ this ->console ->info ('✅ .env updated! ' );
542544 $ this ->console ->info ('----------------------------------------- ' );
543545
544-
545546 // Step - Launch discovery process
546547 $ this ->console ->info ('➡️ Launch discovery process... ' );
547548 $ this ->runCommand ('php tempest discovery:generate ' , '❌ Error during discovery process. ' );
0 commit comments