-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
Locale Files are Generated with Windows Line-endings #2172
Comments
As a workaround, I can run |
Aha, it all starts to make sense now. There is a locale generator test which runs as part of the test suite, and that's what's causing the files to appear changed. I think I now know the fix, and will start working on it. |
See issue PHPOffice#2172. The locale files are regenerated whenever the test suite is run. The use of PHP_EOL in LocaleGenerator.php is awkward on Windows systems, since it causes git to think the file has changed. Change to use `"\n"` instead.
I'm glad you figured it out.... I test locally against different PHP versions on Windows while I'm working, but I always run the tests on a Linux VM before my commit |
Solved by #2174. |
This is:
What is the expected behavior?
Files should have Unix line endings.
What is the current behavior?
They have Windows line endings. This causes git to think they have all been changed; at least that's what it thinks on my Windows machine (which I have configured to use Unix line endings). It would be easy enough to change them all, but, since they appear to be generated, I'm not sure any such change would stick.
What are the steps to reproduce?
Please provide a Minimal, Complete, and Verifiable example of code that exhibits the issue without relying on an external Excel file or a web server:
Which versions of PhpSpreadsheet and PHP are affected?
This seems to have been caused by #2111.
The text was updated successfully, but these errors were encountered: