Most editors that I've seen have the ability to stick in a template, and there are a zillion others. But *just for you*, here's a perl script that'll generate a template for you:
#!/usr/bin/perl my $new_file_name = shift; open my $OFH, '>', $new_file_name; print $OFH <<EOHDR; #!/usr/bin/env python # join_proteins.py --- # # Filename: $new_file_name # Description: # Author: Andy Bork # Maintainer: # Copyright (C) 2010 Andy Bork, all rights reserved. # Created: Sat May 21 16:32:14 2011 (+0530) # Version: # Last-Updated: Sat May 21 17:54:05 2011 (+0530) # By: Ray jennings # Update #: 117 # URL: # Keywords: # Compatibility: # # # Commentary: # # # # # Change log: # # # # Code: print "hello, world!\n"; print "Replace this section with the code you want.\n"; # # $new_file_name ends here EOHDR close $OFH;
With just a few simple modifications, you can have it automatically put in current copyright dates and such.
...roboticus
When your only tool is a hammer, all problems look like your thumb.
In reply to Re: How to do the follwing in Perl OR any other software
by roboticus
in thread How to do the follwing in Perl OR any other software
by chakreey
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |