ngxs / schematics

:wrench: Schematics for @ngxs/store
MIT License
83 stars 16 forks source link

Generated files should follow OS line endings #69

Open spremi opened 5 years ago

spremi commented 5 years ago

I'm submitting a...

[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report  <!-- Please search GitHub for a similar issue or PR before submitting -->
[ ] Performance issue
[x] Feature request
[ ] Documentation issue or request
[ ] Support request => https://github.com/ngxs/store/blob/master/CONTRIBUTING.md
[ ] Other... Please describe:

Current behavior

While running checking in the files generated by schematics on my linux machine, noticed that all line-ending were DOS style. See attached image. ngxs-ctrl-m

Expected behavior

The generated files should follow the default line-endings of the OS.

Minimal reproduction of the problem with instructions

Add schematics to an existing Angular project on a Linux machine.

ng g @ngxs/schematics:store --name=app --path=app/store

Check the line endings on generated files.

What is the motivation / use case for changing the behavior?

While making changes to generated files, too many EOL related changes show up - depending upon the editor & git configuration.

For now, I am running dos2unix on generated files.

Environment

Libs:
- @angular/core version: 8.2.0
- @ngxs/store version: 3.5.0

For Tooling issues:
- Node version: v10.16.0
- Platform:  Linux

Others:
Fedora release 29 (5.1.18-200.fc29.x86_64)
stefanlemmen commented 5 years ago

+1