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

scalafmt config more close to scala style guide #88

Merged
merged 2 commits into from
Oct 20, 2023
Merged
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
7 changes: 3 additions & 4 deletions .scalafmt.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ runner.dialect = scala212

maxColumn = 120

align.preset = some
align.preset = none
Copy link
Collaborator

Choose a reason for hiding this comment

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

I quite liked some here, but I'd like to hear your opinion on this one (i.e. why none ? )

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It definitely may look nice in some instances, but it creates unnecessary changes in diff. It also may create lines longer than the limit, where it would not happen without it.

Those are not huge issues, so I am ok using 'some' if you think it's worth it.

Copy link
Collaborator

Choose a reason for hiding this comment

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

let's go with none then and we'll see if we need to change it back 👍

align.multiline = false

indent.main = 2
Expand All @@ -16,6 +16,5 @@ docstrings.style = AsteriskSpace
docstrings.wrap = no
docstrings.removeEmpty = true

align.openParenDefnSite = true
align.openParenCallSite = true

align.openParenDefnSite = false
align.openParenCallSite = false
Copy link
Collaborator

Choose a reason for hiding this comment

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

Nice, it works, I just tested it & I like it

Loading