aboutsummaryrefslogtreecommitdiff
path: root/examples/scalariform-example/README.md
diff options
context:
space:
mode:
authorNikolay Tatarinov <5min4eq.unity@gmail.com>2016-06-24 02:48:45 +0300
committerJan Christopher Vogt <oss.nsp@cvogt.org>2016-06-23 19:48:45 -0400
commit2cbc42fd0809b60b1ee2116657d18b3f44f8aef1 (patch)
treee894a040137e591c4a7664b7353d709298a44f65 /examples/scalariform-example/README.md
parent75c32537cd8f29f9d12db37bf06ad942806f0239 (diff)
downloadcbt-2cbc42fd0809b60b1ee2116657d18b3f44f8aef1.tar.gz
cbt-2cbc42fd0809b60b1ee2116657d18b3f44f8aef1.tar.bz2
cbt-2cbc42fd0809b60b1ee2116657d18b3f44f8aef1.zip
Scalafmt plugin implementation (#156)
* scalariform: improve logging, declare tasks final * scalafmt plugin implementation * add scalafmt and scalariform plugins and examples to tests * fix logging guarded logging behaviour * add notes about formatting check to README * fix compilation error in examples
Diffstat (limited to 'examples/scalariform-example/README.md')
-rw-r--r--examples/scalariform-example/README.md15
1 files changed, 13 insertions, 2 deletions
diff --git a/examples/scalariform-example/README.md b/examples/scalariform-example/README.md
index e599b5b..28ad226 100644
--- a/examples/scalariform-example/README.md
+++ b/examples/scalariform-example/README.md
@@ -1,5 +1,16 @@
This example shows integration with scalariform plugin.
+
Reformat executed on every `cbt compile` call, and affects only *.scala source files.
+
You can provide your custom scalariform preferences in build via `scalariformPreferences`.
-To test formatting in action you can execute: `cbt breakFormatting` to break formatting
-and `cbt scalariformReformat` to get formatting back.
+
+To see formatting in action: execute `cbt breakFormatting` to break formatting and then execute `cbt scalariformFormat` to get formatting back.
+
+To check if your code is properly formatted(for example as part of CI validation), you can execute:
+
+```
+cbt scalariformFormat
+git diff --exit-code
+```
+
+Last command will return non-zero code, if your code isn't properly formatted.