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

PSR12.Files.FileHeader conflicts with Generic.Files.LineEndings #2878

Closed
on2 opened this issue Feb 24, 2020 · 1 comment
Closed

PSR12.Files.FileHeader conflicts with Generic.Files.LineEndings #2878

on2 opened this issue Feb 24, 2020 · 1 comment
Milestone

Comments

@on2
Copy link

on2 commented Feb 24, 2020

If I run phpcbf --sniffs="PSR12.Files.FileHeader,Generic.Files.LineEndings" myfile.php where myfile.php is as follows (with \r\n line endings):

<?php $name = 'Foo';

Then I receive an error:

PHPCBF FAILED TO FIX 1 FILE

The file now contains 25 empty lines betwen the opening <?php tag and $name = 'Foo';. With \r or\n line endings the file is fixed as expected:

<?php 

$name = 'Foo';

Tested with dev-master and v3.5.4.

@gsherwood gsherwood added this to the 3.5.5 milestone Mar 8, 2020
@gsherwood gsherwood changed the title PSR12.Files.FileHeader with Generic.Files.LineEndings PSR12.Files.FileHeader conflicts with Generic.Files.LineEndings Mar 8, 2020
gsherwood added a commit that referenced this issue Mar 8, 2020
@gsherwood
Copy link
Member

Thanks for the report. This will be fixed in 3.5.5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants