---
title: "Comment by Tarun Sharma on \"How lint-staged@17.6.0 (kind of) broke Git commits\" | Hashnode"
description: "Another way in is on the Prettier side: endOfLine: \"auto\" in the config makes it keep whatever line ending the file already has, so it stops rewriting CRLF to L"
url: "https://hashnode.com/posts/how-lint-staged-17-6-0-kind-of-broke-git-commits/6ada8171e08533a0d7ee3e74/comment/6adaf2c4e1c4ced497a18ef5"
---

[Discussion](https://hashnode.com/posts/how-lint-staged-17-6-0-kind-of-broke-git-commits/6ada8171e08533a0d7ee3e74)

Comment [How lint-staged@17.6.0 (kind of) broke Git commits](https://hashnode.com/posts/how-lint-staged-17-6-0-kind-of-broke-git-commits/6ada8171e08533a0d7ee3e74)

[Tarun Sharma](https://hashnode.com/@101beardo)

[Oct 23](https://hashnode.com/posts/how-lint-staged-17-6-0-kind-of-broke-git-commits/6ada8171e08533a0d7ee3e74/comment/6adaf2c4e1c4ced497a18ef5)

Another way in is on the Prettier side: endOfLine: "auto" in the config makes it keep whatever line ending the file already has, so it stops rewriting CRLF to LF and lint-staged has nothing odd to react to. The eol=lf in .gitattributes is still the cleaner team fix, since it makes every checkout the same instead of relying on each tool respecting the existing endings.

[Paul Aldrich](https://hashnode.com/@aldrichdev)

[Oct 24](https://hashnode.com/posts/how-lint-staged-17-6-0-kind-of-broke-git-commits/6ada8171e08533a0d7ee3e74/comment/6adaf2c4e1c4ced497a18ef5#reply-6add1a2c5954ca336898aa4b)

Great input!
