-
Notifications
You must be signed in to change notification settings - Fork 0
Use scala-cli if scalafmt not present #4
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
Conversation
scala-cli can download the correct scala native binary of scalafmt on demand, which has an even faster startup time. Just think of all the seconds we'll save!
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.
Noice 👍
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 would consider making 2 separate hooks: one for scalafmt and another for scala-cli.
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 guess that instead of listing with scalafmt
, you could also list all the staged files with git diff --cached --name-only
. After all, git add
does not complain if you add a file that's already staged.
That should make it even faster :)
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.
Only QoL stuff.
Co-authored-by: Razvan <[email protected]>
scala-cli can download the correct scala native binary of scalafmt on demand, which has an even faster startup time. Just think of all the seconds we'll save!