How to update copyright header on a folder

Hi,
I have multiple shell scripts in diffrent folders on server.

Most of them contain copyright information like on the third line

  • Copyright � 2004, 2005, My Inc. All rights reserved.

I need to change these headers to

  • Copyright � 2003, 2009, My Inc. All rights reserved.

Most importantly any combination of year 2000 needs to be coverted to 2003, 2009. Is it possible to do this with awk?

Thanks !

With sed you can do something like:

sed '/Copyright � 2004, 2005,/Copyright � 2003, 2009,/g' file > newfile

With awk:

awk '/Copyright � 2004, 2005,/{sub("2004, 2005","2003, 2009")}1' file > newfile
awk 'NR==3{$4="2003,";$5="2009,";} {print}' input_file > output_file

use a loop to do the same for all files.