Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor/ trim whitespaces #2342

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

dimateos
Copy link

@dimateos dimateos commented Feb 4, 2025

Addresses #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")
  • preview: you can use --preview to 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...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant