Skip to content

Conversation

@artengin
Copy link
Contributor

@artengin artengin commented Nov 5, 2025

Refs: #77

@coveralls
Copy link

coveralls commented Nov 5, 2025

Pull Request Test Coverage Report for Build 19103775997

Details

  • 6 of 6 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.3%) to 98.746%

Totals Coverage Status
Change from base Build 19103726582: 0.3%
Covered Lines: 315
Relevant Lines: 319

💛 - Coveralls

@artengin
Copy link
Contributor Author

artengin commented Nov 5, 2025

The changes have been tested on the laravel-empty-project, everything works as expected.

@DenTray DenTray requested a review from Copilot November 10, 2025 04:31
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR refactors the .env file handling logic in the InitCommand to ensure .env.example is always updated first, then .env is either copied from .env.example (if it doesn't exist) or updated separately (if it exists). This change improves consistency in how environment files are managed during project initialization.

  • Simplified the conditional logic for .env file creation/update
  • Ensured .env.example is always the source of truth that gets updated first
  • Updated Clerk credentials handling to explicitly update all three environment files in the correct order

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/Commands/InitCommand.php Refactored env file handling to always update .env.example first, then conditionally copy or update .env, and explicitly update all env files when Clerk authentication is enabled
tests/InitCommandTest.php Updated test mocks to reflect the new env file handling logic, including additional callCopy and changeEnvFileCall expectations for .env creation and updates

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@DenTray DenTray merged commit d287e9b into main Nov 10, 2025
9 checks passed
@DenTray DenTray deleted the generate-env-if-missing branch November 10, 2025 04:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants