Skip to content
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

fix line-endings conflict between prettier and git #1015

Merged
merged 1 commit into from
Nov 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
* text=auto eol=lf

# make sure that script files are always in the correct format, no matter the OS.
# i.e. Windows needs batch files to have CRLF, but shell scripts always need to be LF, which is especially important for WSL contexts.
*.sh text eol=lf
*.bat text eol=crlf
Copy link
Contributor Author

@Vankog Vankog Nov 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These two lines are technically not necessary in this project.
However, I'd like to always add them nonetheless, as it prevents issues on WIndows machines with any possible future scripts. (e.g. with maven/gradle wrapper etc.)

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems reasonable

1 change: 1 addition & 0 deletions .prettierrc.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
tabWidth: 4
printWidth: 100
trailingComma: "none"
endOfLine: "lf"