#!/usr/bin/perl use strict; use warnings; $^I = ".old"; while (<>) { if (/^#!/) { $_ .= " ## Copyright (C) 2008 me\n"; print; } }