GitHub user koeninger opened a pull request:

    https://github.com/apache/spark/pull/23148

    [SPARK-26177] Automated formatting for Scala code

    ## What changes were proposed in this pull request?
    
    Add a maven plugin and wrapper script at ./dev/scalafmt to use scalafmt to 
format files that differ from git master.
    
    Intention is for contributors to be able to use this to automate fixing 
code style, not to include it in build pipeline yet.
    
    If this PR is accepted, I'd make a different PR to update the code style 
section of https://spark.apache.org/contributing.html to mention the script
    
    ## How was this patch tested?
    
    Manually tested by modifying a few files and running the script, then 
checking that scalastyle still passed.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/koeninger/spark-1 scalafmt

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/23148.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #23148
    
----
commit 5df854a340f5e9e2fe7ba60194b4891235420369
Author: cody koeninger <cody@...>
Date:   2018-11-21T20:32:57Z

    WIP on scalafmt config

commit 57684272b60ff1213c957541f1db3f9d7aba1543
Author: cody koeninger <cody@...>
Date:   2018-11-21T21:22:15Z

    mvn plugin, e.g. ./build/mvn mvn-scalafmt_2.12:format

commit bd7baeca577bf9b519fe028d1e831fb7193e7af9
Author: cody koeninger <cody@...>
Date:   2018-11-22T17:07:06Z

    shell wrapper for mvn scalafmt plugin

----


---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to