Codebase list libmawk / 7ab313a7-f14c-465a-bfe5-5a4585f9ed23/main tools / rename.sh
7ab313a7-f14c-465a-bfe5-5a4585f9ed23/main

Tree @7ab313a7-f14c-465a-bfe5-5a4585f9ed23/main (Download .tar.gz)

rename.sh @7ab313a7-f14c-465a-bfe5-5a4585f9ed23/mainraw · history · blame

#!/bin/sh

for n in *.h *.c *.y
do
	case $n in 
		parse.c) ;;
		mawk.h);;
		*)
			mv $n $n.old
			sed "s/\([^A-Za-z_>]\)$1/\1mawk_$1/g;s/^$1/mawk_$1/" < $n.old > $n
			rm -f $n.old
			;;
	esac
done