astyle: Add `--pad-header` option

Insert space padding between a header (e.g. 'if', 'for', 'while'...) and the
following paren. ex:

if(isFoo((a+2), b))
    bar(a, b);

becomes:

if (isFoo((a+2), b))
    bar(a, b);

Link: http://astyle.sourceforge.net/astyle.html#_pad-paren
Signed-off-by: Sohaib Mohamed <sohaib.amhmd@gmail.com>
This commit is contained in:
Sohaib Mohamed 2021-09-30 00:44:52 +02:00 committed by BenBE
parent d23627fda9
commit 8932efece9
1 changed files with 1 additions and 1 deletions

View File

@ -196,7 +196,7 @@ They can be a great asset to structure the flow of a method.
If you want to automate formatting your code, the following command gives you a good baseline of how it should look:
```bash
astyle -r -xb -s3 -p -xg -c -k1 -W1 \*.c \*.h
astyle -r -xb -s3 -p -xg -c -k1 -W1 -H \*.c \*.h
```
Working with System APIs