I would like to use --dry-run and have astyle report all the changes it would like to make. This way the tool can be used as a style checker rather than a formatter. (And I really would like a style checker :-))
To clarify, I don't want to change the behaviour of the flag --dry-run as such, but rather add a new verbose flag to report all changes made so that when used together with --dry-run it would verify and report violations to the style rules rather than modifying the source.
Last edit: Jesper Wilhelmsson 2019-02-19
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
To clarify, I don't want to change the behaviour of the flag --dry-run as such, but rather add a new verbose flag to report all changes made so that when used together with --dry-run it would verify and report violations to the style rules rather than modifying the source.
Last edit: Jesper Wilhelmsson 2019-02-19
On Linux, you could easily write a script that uses stdin/stdout redirection to run astyle and send the output to /bin/diff.
I'm not only on linux and if possible I'd like to avoid additional logic around the style checker.