Whitespace Cleanup #743

jawwad opened this Issue May 14, 2012 · 0 comments


None yet
2 participants

jawwad commented May 14, 2012

It would be great to do a whitespace cleanup on the repository just before shipping this release. This will make the Style Cleaup task in #614 much easier.

Command to clean trailing whitespace:
git ls-files -z *.m *.h *.json | grep -vz ^Vendor/ | grep -vz ^Tests/Vendor/ | xargs -0 /usr/bin/sed -i '' -E 's/[[:space:]]*$//'

Command to replace tabs with spaces:
Note: OSX sed won't recognize a '\t' so delete it and type Ctrl+v, tab to insert a tab character in its place
See: http://stackoverflow.com/questions/5398395/how-can-i-insert-a-tab-character-with-sed-on-os-x/5398430#5398430
git ls-files -z *.m *.h *.json | grep -vz ^Vendor/ | grep -vz ^Tests/Vendor/ | xargs -0 /usr/bin/sed -i '' 's/\t/ /g'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment