-
Notifications
You must be signed in to change notification settings - Fork 1
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
Nggw 94 tabs eol #10
base: master
Are you sure you want to change the base?
Nggw 94 tabs eol #10
Conversation
This only includes php files - I think we should make sure to handle at least scss and js files as well? Personally, I would also like to see a hook which requires empty last line as well. |
And Twig files too. But in general, every file committed should be checked, except |
src/Action/CheckForSpacesInEOL.php
Outdated
use function array_diff; | ||
use function implode; | ||
|
||
final class CheckForSpacesInEOL extends Action |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be named e.g. CheckForWhiteSpaceAtEOL
, since it doesn't only remove spaces but all whitespace.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The class is renamed now
src/Action/CheckForSpacesInEOL.php
Outdated
} | ||
} | ||
|
||
private function getChangedFiles(Config\Action $action, Repository $repository): array |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we move this duplicated method to a base Action
class?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This method is moved to the Action class
GIT hook for checking tabs vs spaces and EOL