jrossi / issue-migration-test

GNU General Public License v2.0
1 stars 0 forks source link

trailing whitespaces #25

Closed jrossi closed 10 years ago

jrossi commented 10 years ago

Hi, can you remove all trailing whitespaces in the source, eg in linux with "find ./src -type f -exec sed -i 's/ *$//' '{}' ';'", because when editing the source with an editor, which automaticly removes them (like eclipse or kate), the diff overflows with unimportant lines and you can not concentrate on the real code change.

Note: This issue has been automatically migrated from Bitbucket Created by cgzones on 2012-09-21 13:00:33+00:00, last updated: 2012-09-25 23:15:44+00:00

jrossi commented 10 years ago

The command below does remove all trailing whitespaces {{{ find ./src -type f -exec sed -i 's/ *$//' '{}' ';' }}} However, compilation failed at os_crypto/shared/. Be careful when doing something like this.

If I do not modify Makefiles, then it compiled OK.

Note: This comment has been automatically migrated from Bitbucket Created by jbcheng on 2012-09-21 23:48:08+00:00, last updated: 2012-09-22 00:20:34+00:00

jrossi commented 10 years ago

Hi, sorry, my fault. I tested it sometime (mybe on a just cloned repo, so no .a files exist). My new suggestion: {{{

!bash

find . -name .c -exec sed -i 's/[[:space:]]$//' {} \; find . -name .h -exec sed -i 's/[[:space:]]$//' {} \; find . -name .sh -exec sed -i 's/[[:space:]]$//' {} \; find . -name .init -exec sed -i 's/[[:space:]]$//' {} \; }}}

Note: This comment has been automatically migrated from Bitbucket Created by cgzones on 2012-09-22 12:37:04+00:00

jrossi commented 10 years ago

removed trailing spaces for .c and .h files

Note: This comment has been automatically migrated from Bitbucket Created by jbcheng on 2012-09-25 23:16:30+00:00

jrossi commented 10 years ago

The following command only modifies .sh files in current directory, not those in subdirectories. {{{ find . -name *.sh -exec sed -i 's/[[:space:]]$//' {} \; }}}

Note: This comment has been automatically migrated from Bitbucket Created by jbcheng on 2012-09-25 23:17:57+00:00