Skip to content

Enforce Line Endings #270

@krowvin

Description

@krowvin

Problem

line endings are left up to each person’s editor and local Git config causing CRLF or LF to be placed in files depending on who is committing and from what system.

Background

If you are not paying attention to the commit you might miss that line endings were added.

It is a particular issue in the VSCode editor where a diff in the UI does not visually show the line endings.

Personally the UI works well enough and I have no need to be in the terminal enough to check each diff to see if I accidentally committed line endings that I have enabled in my git config on one system vs another

But I did confirm i'm not the only one embarrassing myself with altering line endings often!

microsoft/vscode#19254

Solution

Add a .gitattributes to enforce line endings

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions