Cinder
Cinder copied to clipboard
Refactor/ trim whitespaces
Addresses https://github.com/cinder/Cinder/issues/2341
I created the following script to ONLY trim trailing white spaces:
- src: https://github.com/dimateos/Open-Cinder/blob/refactor/trim-whitespaces/tools/ci/trim_whitespaces.sh
-
usage: displayed with
--help -
config: has default target FOLDERS and EXTENSIONS, but can be set by args too
- DEFAULT_FOLDERS=
("src/cinder" "include/cinder" "test" "samples") - DEFAULT_EXTENSIONS=
("*.cpp" "*.h" "*.mm" "*.java" "*.txt" "*.rc" "*.glsl" "*.frag" "*.vert" "*.comp")
- DEFAULT_FOLDERS=
-
preview: you can use
--previewto see what would be targeted beforehand -
example:
./trim_whitespaces.sh --path ../../ --folders test
Then I applied the trimming in separate commits per parent folders:
- Feel free to squash the commits
- Or use a CI bot so the line changes are not assigned to me whatever
I think this is very worth considering!
at least this PR can be used as a diff for what would be trimming the whole sources...