| #!/bin/bash |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| if [ ! $# = 4 ];then |
| cli_printMessage "`gettext "Syntax: ./update-filenames.sh <PATH> <FILTER> <PATTERN> <VALUE>"`" |
| exit; |
| fi |
| |
| ROOTDIR="$1" |
| FILTER="$2" |
| PATTERN="$3" |
| VALUE="$4" |
| |
| for FILE in `find $ROOTDIR -regex $FILTER`;do |
| DIR=`dirname $FILE` |
| FILE=`basename $FILE` |
| svn mv $DIR/$FILE $DIR/`echo $FILE | sed -r "s!$PATTERN!$VALUE!"` |
| done |