File: removespace.sh

package info (click to toggle)
biobambam2 2.0.179%2Bds-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 3,856 kB
  • sloc: cpp: 42,867; sh: 834; makefile: 634
file content (11 lines) | stat: -rwxr-xr-x 252 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
#! /bin/bash
for i in `find src -regex .*\\\.[ch]pp` `find src -regex .*\\\.[ch]` ; do
	ORIG=`cat $i`
	PATCHED=`perl -p -e "s/(\s*)($)/\n/" < ${i}`
	
	if [ "$ORIG" != "$PATCHED" ] ; then
		echo "${PATCHED}" > ${i}
		# git add ${i}
		echo ${i}
	fi
done