-
Notifications
You must be signed in to change notification settings - Fork 360
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
update scalastyle; add scapegoat and scalafmt #3356
update scalastyle; add scapegoat and scalafmt #3356
Conversation
Signed-off-by: philvarner <philvarner@gmail.com>
build.sbt
Outdated
@@ -1,8 +1,9 @@ | |||
import sbt.Keys._ | |||
|
|||
ThisBuild / scalaVersion := "2.12.13" | |||
ThisBuild / scalaVersion := Version.scala211 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd like to see Version.scala212
as the default here. :D
2.11 is not a priority atm, more like a legacy crossompilation that I'd really like to drop.
We use GT mostly with 2.12.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry, that must have been a typo when I originally made this change -- I've been cross-compiling most of the time and didn't notice.
.scalafmt.conf
Outdated
version = 2.7.5 | ||
align = more // For pretty alignment. | ||
maxColumn = 120 | ||
newlines.alwaysBeforeTopLevelStatements = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does scalafmtAll
breaks everything? :/ I'd expect it to reformat 90% of our files.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It does -- I mostly just wanted to get it in here, but have it be unused. But, I think it would be better to spend a bit of time aligning the rules with the existing code before merging. Putting PR in draft.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is this tool that hopefully can generate the scalafmt file that would fit our needs: https://github.com/tanishiking/scalaunfmt
(I haven't tried it and I would not be that positive about it), scalafmt is definitely going to break our type params with lots of imports formatting ):
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great, I'll take a look at that tool. I think it's more important to be consistent within the codebase than adhere to some arbitrary external standard, so I'll try to write the rules that way.
Signed-off-by: philvarner <philvarner@gmail.com>
Signed-off-by: philvarner <philvarner@gmail.com>
Signed-off-by: philvarner <philvarner@gmail.com>
0843f2b
to
ecfef2d
Compare
Signed-off-by: philvarner <philvarner@gmail.com>
Signed-off-by: philvarner philvarner@gmail.com
Overview
.scalafmt.conf
was copied from stac4sChecklist
docs
guides update, if necessaryDemo
none
Notes
none