Perl can take its input from a file and send its output to a file using standard I/O redirection.
$ perl -ne 'print;' < yourTextFile $ perl -ne 'print' emp.first > yourTextFile