Call-sites where there is a newline after opening ( and newline before closing ). If true, preserves the newlines and keeps one line per argument.
NB: failure unless newlines.source=classic If true, then the user can opt out of line breaks inside select chains.
// original foo .map(_ + 1).map(_ + 1) .filter(_ > 2) // if true foo .map(_ + 1).map(_ + 1) .filter(_ > 2) // if false foo .map(_ + 1) .map(_ + 1) .filter(_ > 2)
NB: ignored unless newlines.source=classic If true, keeps the line break before a dot if it already exists.
// original foo .map(_ + 1) .filter( > 2) // if true foo .map(_ + 1) .filter( > 2) // if false foo.map(_ + 1).filter( > 2)
See https://github.com/scalameta/scalafmt/issues/938 If true, will force a line break before a self annotation if there was a line break there before.
If true, always insert a blank line before docstrings, If false, preserves blank line only if one exists before. Example:
// before object Foo { /** Docstring */ def foo = 2 } // after, if forceBlankLineBeforeDocstring=false object Foo { /** Docstring */ def foo = 2 } // after, if forceBlankLineBeforeDocstring=true object Foo { /** Docstring */ def foo = 2 }
NB: ignored unless newlines.source=classic If true, keeps the line break before a dot if it already exists.
NB: ignored unless newlines.source=classic If true, keeps the line break before a dot if it already exists.
// original foo .map(_ + 1) .filter( > 2) // if true foo .map(_ + 1) .filter( > 2) // if false foo.map(_ + 1).filter( > 2)
NB: failure unless newlines.source=classic If true, then the user can opt out of line breaks inside select chains.
NB: failure unless newlines.source=classic If true, then the user can opt out of line breaks inside select chains.
// original foo .map(_ + 1).map(_ + 1) .filter(_ > 2) // if true foo .map(_ + 1).map(_ + 1) .filter(_ > 2) // if false foo .map(_ + 1) .map(_ + 1) .filter(_ > 2)
Call-sites where there is a newline after opening ( and newline before closing ).
Call-sites where there is a newline after opening ( and newline before closing ). If true, preserves the newlines and keeps one line per argument.
If true, always insert a blank line before docstrings, If false, preserves blank line only if one exists before.
If true, always insert a blank line before docstrings, If false, preserves blank line only if one exists before. Example:
// before object Foo { /** Docstring */ def foo = 2 } // after, if forceBlankLineBeforeDocstring=false object Foo { /** Docstring */ def foo = 2 } // after, if forceBlankLineBeforeDocstring=true object Foo { /** Docstring */ def foo = 2 }
See https://github.com/scalameta/scalafmt/issues/1712
See https://github.com/scalameta/scalafmt/issues/1712
Setting behavior and name were mirrored. After deprecation and right naming
we need to:
if forceBlankLineBeforeDocstring
(new name) has default value (true)
fallback to blankLineBeforeDocstring
(old config) which may be
configured in .scalafmt.conf
if forceBlankLineBeforeDocstring
configured to non-default value
don't look at the old name
See https://github.com/scalameta/scalafmt/issues/938 If true, will force a line break before a self annotation if there was a line break there before.
Call-sites where there is a newline after opening ( and newline before closing ). If true, preserves the newlines and keeps one line per argument.
NB: failure unless newlines.source=classic If true, then the user can opt out of line breaks inside select chains.
NB: ignored unless newlines.source=classic If true, keeps the line break before a dot if it already exists.
See https://github.com/scalameta/scalafmt/issues/938 If true, will force a line break before a self annotation if there was a line break there before.
If true, always insert a blank line before docstrings, If false, preserves blank line only if one exists before. Example: