scripting: Format java code by using astyle tool

Change-Id: Ifcd90612f22282c16efdbf4d300b8164bf68f760
Reviewed-on: https://gerrit.libreoffice.org/11304
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
This commit is contained in:
rbuj 2014-09-06 12:19:07 +02:00 committed by Caolán McNamara
parent 1da153b617
commit feea4b250b
2 changed files with 21 additions and 0 deletions

2
scripting/Format_java_code.sh Executable file
View file

@ -0,0 +1,2 @@
#!/bin/bash
astyle --options=astyle-java.conf --verbose --recursive ./*.java

19
scripting/astyle-java.conf Executable file
View file

@ -0,0 +1,19 @@
--style=java
--mode=java
--indent-switches
--indent-cases
--min-conditional-indent=0
--max-instatement-indent=40
--break-blocks
--unpad-paren
--align-reference=name
--pad-oper
--unpad-paren
--add-brackets
-s4
--indent-col1-comments
--lineend=linux
--ignore-exclude-errors
--suffix=none
--preserve-date
--formatted