Last change
on this file since 2321 was 2321, checked in by cmv, 23 years ago |
repl str dans rep sophya rz+cmv 11/2/03
|
-
Property svn:executable
set to
*
|
File size:
471 bytes
|
Rev | Line | |
---|
[2321] | 1 | #!/bin/csh
|
---|
| 2 | # Pour remplacer une chaine de char par une autre dans les repertoires Sophya
|
---|
| 3 | # find . -name \*.h -exec grep stream {} \;
|
---|
| 4 | set ftemp = /tmp/replace_string.tmp
|
---|
| 5 |
|
---|
| 6 |
|
---|
| 7 | foreach f ( */*.h */*.cc )
|
---|
| 8 | grep "fstream.h" $f > /dev/null
|
---|
| 9 | if( $status == 0 ) then
|
---|
| 10 | echo $f
|
---|
| 11 | rm -f ${ftemp}; cp $f ${ftemp}
|
---|
| 12 | # Attention on ne peut pas changer de chaine de char avec des "?" dedans
|
---|
| 13 | cat ${ftemp} | sed "s?fstream.h?fstream?g" >! $f
|
---|
| 14 | endif
|
---|
| 15 | end
|
---|
| 16 |
|
---|
| 17 | rm -f ${ftemp}
|
---|
| 18 |
|
---|
| 19 | exit 0
|
---|
Note:
See
TracBrowser
for help on using the repository browser.