Closed okonet closed 6 years ago
That would be hard to fix I’m afraid. Any ideas what to do? Should we read .editorconfig
and respect it? That would be super cool ;-)
I think we can extend mrm-core modules to respect .editorconfig
on save. We can use editorconfig-core-js for that I think. And then apply indentation and new line at the end settings.
I was thinking of not modifying the whole file unless needed. But your solution might work as well.
This would be way to complex and would require a whole rewrite ;-)
I think it’s OK (and even good) if Mrm will reformat the whole file according to EditorConfig rules.
Yeah, probably you're right.
One related issue I had was that mrm has completely reformatted my .gitignore
file as well. I wouldn't expect that TBH.
Could you show me the diff?
Yeah, that wasn’t a good idea to remove empty lines ;-? Could you open a separate issue for that? I’m not sure what would be the best approach here.
Nope, it has absolutely crazy API and no docs how to use it:
PR is here: https://github.com/sapegin/mrm-core/pull/9 ;-)
Done in mrm-core 2.4.0.
When running tasks I noticed that often they also remove the new line
/n
at the end which is required by my.editorconfig
.