Skip to content

Conversation

AmadulHaque
Copy link

Summary

This PR adds two new Composer scripts to improve the developer workflow:

  • composer lint → runs Pint to check code style
  • composer fix → runs Pint in dirty mode to automatically fix issues

Why

Having dedicated lint and fix scripts:

  • Provides a faster way to run Pint
  • Encourages consistent coding standards
  • Improves DX (developer experience)

Changes

  • Updated composer.json scripts section:
    • Added lint: "vendor/bin/pint"
    • Added fix: "vendor/bin/pint --dirty"

Testing

  • Run composer lint → code style issues will be reported
  • Run composer fix → issues will be auto-fixed

@AhmedAlaa4611
Copy link
Contributor

I’m a bit hesitant about adding these scripts though. Since Pint already has simple commands (pint / pint --dirty), keeping things as is avoids an extra layer of indirection and ensures contributors learn the actual tool commands.

This could add some redundancy and potentially confuse new contributors who may not realize they’re just calling Pint directly.

@AmadulHaque
Copy link
Author

I’m a bit hesitant about adding these scripts though. Since Pint already has simple commands (pint / pint --dirty), keeping things as is avoids an extra layer of indirection and ensures contributors learn the actual tool commands.

This could add some redundancy and potentially confuse new contributors who may not realize they’re just calling Pint directly.

Thanks for the feedback! 🙌 I see your point about redundancy and agree that Pint is already simple to run directly.

My intention with adding these scripts was mainly to:

Provide a consistent, easy-to-remember entry point (composer lint / composer fix)

Align with how many projects already expose common tooling (like composer test)

Lower the barrier for contributors who may not be familiar with Pint at first

That said, I totally understand the concern about introducing indirection. If the team prefers sticking to the raw Pint commands to keep things straightforward, I’m happy to adjust or close this PR. ✅

@taylorotwell
Copy link
Member

Thanks for your pull request to Laravel!

Unfortunately, I'm going to delay merging this code for now. To preserve our ability to adequately maintain the framework, we need to be very careful regarding the amount of code we include.

If applicable, please consider releasing your code as a package so that the community can still take advantage of your contributions!

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.

3 participants