Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using Twig CS fixer #472

Open
alexmerlin opened this issue Aug 30, 2024 · 1 comment
Open

Using Twig CS fixer #472

alexmerlin opened this issue Aug 30, 2024 · 1 comment

Comments

@alexmerlin
Copy link
Member

This feature is mostly forgotten since it was implemented.
We should promote this internally so that our developers start using it on a daily basis.

Before each commit, we should validate Twig files (inside the src directory - @bidi47 correct me if I'm wrong on this one) using this command:

composer twig-cs-check

which will output any coding style error that needs to be fixed.

Then we can fix them manually or using this command

composer twig-cs-fix

Both Composer commands are defined in composer.json.


We should also investigate if this feature can be turned into a CI tool that runs on each push - that way even if we forget to run it locally, invalid code will not get through to the default branch.

@bidi47
Copy link
Collaborator

bidi47 commented Sep 1, 2024

Before each commit, we should validate Twig files (inside the src directory - @bidi47 correct me if I'm wrong on this one)

the composer commands don't include a location, so the check is run in the whole project, not just in src

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

No branches or pull requests

2 participants